1. These forums are still being retired! Please use GitHub discussions or Discord. You cannot create new threads or new accounts now. If you need to contact some user of the forums, you should do it sooner, rather than later. This notice was last updated on May 30th, 2021.

Bug? Error when starting with script

Discussion in 'Help and Support' started by VengeanceVenger, Jul 19, 2017.

  1. VengeanceVenger

    VengeanceVenger Level 0

    Joined:
    Apr 20, 2017
    Messages:
    2
    I am trying to start my server with a script to automate it and i wont work i just spits out this one error every time i try.
    Code:
    Unhandled exception
    System.UnhandledExceptionEventArgs
    [Server API] Error ===================================================================================
    [Server API] Error An unhandled exception has occured in TSAPI, and a crash report will be generated
    [Server API] Error Generating a crash report, please wait...
    [Server API] Error Crash report saved at crash_131449730602273970.zip
    [Server API] Error Please upload the crash file and report it at https://tshock.co/
    [Server API] Error The process will terminate.
    [Server API] Error ===================================================================================
    Saving world. Momentary lag might result from this.
    [ERROR] FATAL UNHANDLED EXCEPTION: System.IO.FileNotFoundException: Could not find file "/tshock/Cringe_Fest.wld".
    File name: '/tshock/Cringe_Fest.wld'
      at System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean anonymous, System.IO.FileOptions options) [0x0021a] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share) [0x00000] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at (wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor (string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare)
      at System.IO.File.OpenRead (System.String path) [0x00000] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.IO.File.ReadAllBytes (System.String path) [0x00000] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at Terraria.Utilities.FileUtilities.ReadAllBytes (System.String path, System.Boolean cloud) [0x00016] in <06adbab0e92243bbb7ab2312d0c212fb>:0
      at Terraria.IO.WorldFile.loadWorldDirect (System.Boolean loadFromCloud) [0x00113] in <06adbab0e92243bbb7ab2312d0c212fb>:0
      at Terraria.IO.WorldFile.loadWorld (System.Boolean loadFromCloud) [0x0000c] in <06adbab0e92243bbb7ab2312d0c212fb>:0
      at Terraria.WorldGen.serverLoadWorldCallBack (System.Object threadContext) [0x00022] in <06adbab0e92243bbb7ab2312d0c212fb>:0
      at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context (System.Object state) [0x0000e] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.Threading.ExecutionContext.RunInternal (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x0008d] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00000] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem () [0x0002a] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.Threading.ThreadPoolWorkQueue.Dispatch () [0x00096] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
      at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback () [0x00000] in <dbb16e0bacdc4a0f87478e401bc29b6c>:0
    
    any help would be amazing! =]
     
  2. Zaicon

    Zaicon Spam Cleaner 9000
    TShock Mod Plugin Developer

    Joined:
    Feb 15, 2014
    Messages:
    811
    It says that the world file cannot be found in the tshock folder. Either move your world there or add a -worldpath parameter to your startup script with the correct path to your world file.