Quick questions thread: Ask your "How do I?" and "Where is?" questions here.

Discussion in 'Help and Support' started by nicatronTg, Jan 18, 2012.

  1. seppus

    seppus Level 0

    Joined:
    May 1, 2018
    Messages:
    3
    I did this and placed/removed blocks are still being saved.

    The config file seems to load correctly though, flags like DisableBuild work just fine.

    One work-around would be killing the server process in the task manager, but I hoped it wouldn't have to come to that ;)
     
  2. xExekut3x

    xExekut3x Level 0

    Joined:
    Sep 25, 2018
    Messages:
    2
    On Linux: 4.18.9-arch1-1-ARCH

    Trying to figure out what arguments to pass to a systemd service I'm writing to automatically start TShock - automatically select world, basically.

    ExecStart=/usr/bin/tmux new-session -d -s tshock-session "mono --server --gc=sgen -O=all TerrariaServer.exe ARGUMENTS"

    I'm guessing either pass it a configuration file or specify world options? Problem, though, I went ahead and created a world, but there is no world file with the name I specified in the directory. Is that information kept in sqlite?
     
  3. nicatronTg

    nicatronTg Shank / hakusaro
    TShock Founder TShock Admin

    Joined:
    Jul 21, 2011
    Messages:
    716
    https://tshock.readme.io/docs/command-line-parameters

    You need IP, port, player count, and world, I think, as the minimum for an autostart. Just specify as much as you know beforehand and see what works.
     
  4. xExekut3x

    xExekut3x Level 0

    Joined:
    Sep 25, 2018
    Messages:
    2
    Thanks! That did it.

    Code:
    ExecStart=/usr/bin/tmux new-session -d -s tshock-session "mono --server --gc=sgen -O=all TerrariaServer.exe -worldpath ~/.local/share/Terraria/Worlds/ -world ~/.local/share/Terraria/Worlds/CorruptionSmall1.wld"
     
    • Friendly Friendly x 1
  5. ThatLittleArtist

    Joined:
    Feb 3, 2018
    Messages:
    3
    How can I un-ban all players from my server with a simple command?
     
    #1305 ThatLittleArtist, Oct 1, 2018
    Last edited: Oct 1, 2018
  6. ThatLittleArtist

    Joined:
    Feb 3, 2018
    Messages:
    3
    How do I get a list of all the registered users in my server?
     
  7. Zaicon

    Zaicon Spam Cleaner 9000
    TShock Mod Plugin Developer

    Joined:
    Feb 15, 2014
    Messages:
    811
    Both of those aren't built-in to tShock. If you have a database editor, you can use an SQL command for both of those requests.
     
  8. Cobalt

    Cobalt Level 0

    Joined:
    Feb 6, 2019
    Messages:
    2
    How to user TSPlayer.SendData?
    I am trying to send a ProjectileUpdate packet which has 10 parameters,but this function only has 7 parameters?
    THANKS
     
  9. quake1337

    quake1337 Level 1

    Joined:
    Aug 19, 2017
    Messages:
    8
    SendData works just like vanilla SendData. Study the game code (namely, NetMessage.SendData) to see how these packets are serialized and what inputs they take. Alternatively there was a .SendRaw method that allowed you to send a raw byte array down the wire.
     
    • Like Like x 1
  10. Cobalt

    Cobalt Level 0

    Joined:
    Feb 6, 2019
    Messages:
    2
    Got it,thanks alot.
     
  11. halfgamerz

    halfgamerz Level 4

    Joined:
    May 23, 2016
    Messages:
    62
    Why is my server keep shutting down every once in a while? I have checked the crash report and the following seems to be the issue,

    "exception": {
    "message": "The socket is not connected",
    "type": "SocketException",
    "trace": " at System.Net.Sockets.Socket.get_RemoteEndPoint () [0x00035] in <102ddc49e9884872921866bb2bd1bab6>:0 \n at HttpServer.HttpListener.OnSocketAccepted (System.IAsyncResult ar) [0x000db] in <0bb72d76034a4517b7a1f3b62e0cc3e7>:0 \n at System.Net.Sockets.SocketAsyncResult+<>c.<Complete>b__27_0 (System.Object state) [0x0000b] in <102ddc49e9884872921866bb2bd1bab6>:0 \n at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem () [0x00008] in <7c6726ddba2042189622013443252667>:0 \n at System.Threading.ThreadPoolWorkQueue.Dispatch () [0x00074] in <7c6726ddba2042189622013443252667>:0 \n at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback () [0x00000] in <7c6726ddba2042189622013443252667>:0 ",
    "inner": null

    I have a 32gb dedicated private game server it runs Centos 7, and I use Mono to run the tShock server.
    When I restart the server it never uploads the latest map I have to upload the latest map myself. I anyone can provide a solution to both how to keep my server from shutting down and how to automatically upload the latest map I would really, really appreciate it!


    "os": {
    "x64": "yes",
    "x64Process": "yes",
    "Platform": "Unix",
    "Version": "Unix 4.9.144.6"
    },
    "hardware": {
    "CPUs": 8,
    "CPUID": null
    },
    "server": {
    "Players": 0,
    "MaxPlayers": 255,
    "WorldName": "Terraria",
    "WorldFile": "/root/.local/share/Terraria/Worlds/Terraria.wld",
    "Time": 14008.0
    },
    "process": {
    "curRelease": 194,
    "TSAPIVersion": "1.3.5.3",
    "Uptime": "3.10:18:56.1144870",
     
  12. halfgamerz

    halfgamerz Level 4

    Joined:
    May 23, 2016
    Messages:
    62
    • Winner Winner x 1
  13. Sekke

    Sekke Level 0

    Joined:
    Mar 9, 2019
    Messages:
    1
    How do i run mono TerrariaServer.exe?
     
  14. is0

    is0 Level 0

    Joined:
    Mar 29, 2019
    Messages:
    1
    how do i use worlds i created before i had tshock
     
  15. Kojiro_S

    Kojiro_S Level 11

    Joined:
    Feb 16, 2014
    Messages:
    645
    Unless you modify its default settings, TShock reads worlds from the same folder Terraria does, which means your old worlds should be accesible without any fiddling.
    Just a friendly reminder: tModLoader has nothing to do nor is supported by TShock. If you are trying to load modded worlds, they are not going to be detected since they go on a different folder.
     
  16. RESi

    RESi Level 1

    Joined:
    Sep 30, 2012
    Messages:
    6
    It's possible to restore inventory if SSC accidentaly deleted all items of my teammate when i gave them superadmin?
     
  17. quake1337

    quake1337 Level 1

    Joined:
    Aug 19, 2017
    Messages:
    8
    take away superadmin and they should get SSC items back
     
  18. RESi

    RESi Level 1

    Joined:
    Sep 30, 2012
    Messages:
    6
    not worked, same reset inventory :(
     
  19. Zeus

    Zeus Level 0

    Joined:
    May 18, 2019
    Messages:
    4
    Where can I find my world file on Ubuntu? (I want to backup / download it)
     
  20. nicatronTg

    nicatronTg Shank / hakusaro
    TShock Founder TShock Admin

    Joined:
    Jul 21, 2011
    Messages:
    716
    It really depends on where you started your server and what the parameters you gave it when you started it were. It's probably slowest and easiest to just use the find command. You can then search for anything ending in .wld, which is the Terraria world file extension.

    Code:
    find / -name "*.wld"
    
    It varies per OS and you're usually going to be looking for a "Terraria" folder containing a "Worlds" folder with your world name.wld.
     
    • Useful Useful x 1