Version 1.0.2 This plugin lets you run custom-made macros to help with things such as countdowns. Just make them in the easy-to-understand programming language in Notepad and save them in the TShock/tshock directory. Commands (you can use /tl instead of /timeline): /timeline start <file> [arguments] - Starts a macro with the given filename. If any arguments are defined, type those too. /timeline stop <file> - Stops the macro with the given filename. /timeline show - Shows all running macros. Permissions: timeline.admin.useall - Lets the group start or stop any timeline. timeline.use-[file] - Allows a group to use a specific command. For example, you can give a group the permission timeline.use-example.txt, and that group will only be able to use that timeline. You can also specify a folder such as with the permission timeline.use-registeredusers. If you create a folder within the TShock folder called that, any timeline in it will be usable for those with the permission. Examples: Let's say you want a game to start in 30 seconds. You type /timeline start wait30secs.txt. Before doing this, you must create the macro. Go into TShock/tshock and create the new file, wait30secs.txt. In it should be something like this: Code: //This is a comment. #wait 1000 //The timeline will wait for 1000 milliseconds. bc The game is starting in 30 seconds. #wait 15000 bc 15 seconds... #wait 5000 bc 10 seconds #wait 1000 bc 9 #wait 1000 bc 8 #wait 1000 bc 7 #wait 1000 bc 6 #wait 1000 bc 5 #wait 1000 bc 4 #wait 1000 bc 3 #wait 1000 bc 2 #wait 1000 bc 1 #wait 1000 bc The game has started! antibuild off As you can see, executing a command is just as easy as doing so in the server console. You also have the command #wait <milliseconds>. But what if you want something more complicated? This example shows how to pass arguments into a macro. Code: #req name, adjective, adjective2 #wait 500 bc {0} is {1}. #wait 2000 bc {0} really is {2}. The #req command should be passed at the start of the code, and it sends an error message to the player if he doesn't have the proper arguments, which are separated with commas. You can replace any bit of code with these arguments. You're not just limited to text; you could, for example, have one of the arguments be an entire command, you could modify how long to wait at a point, or you could even use an argument to switch a comment on or off. Links: Download | Source Changelog: Spoiler 1.0.1 - Updated permissions to be file and folder-specific.
Sweet. Looks good, source-wise. I was afraid you were going to Thread.Sleep to do the waiting but I'm happy to say I was wrong.
Sweet plugin ! Love it ! No more need to check clock for CTG preptime ! It does it all ! Announce rules, countdown, remove antibuild ! Yay !
The problem occurs with characters (ã, õ, ç), etc. How much is a text they are replaced by asterisks (*). Maybe it's inconvenient for those who want to use the special characters, but I personally do not use them because are "bold" and badly formatted in the terraria chat, then do not use accents. @GameRoon, great job, your plugin is very interesting.
umm, only 'bc', the broadcast. and normal english broadcast is working well, so trivial thing. I'm using non-english language, here is an example - '가나다라마바사아자차카타파하' I applied language patch made by countryman, so don't have to worry about the font or format. It was just a minor report, so don't concern yourself too much about this, thanks!
Hi. This is because the font used by Terraria doesn't have these characters. It can't display them, so it displays a * instead
Hmm. Hellow, I tried to make a auto cmd with this pluggin, i used two files 01.txt and 02.txt, 01 txt is only to start 02 again, and the end of 02 is to start 01 in 01 is only [#wait 1000 timeline start 02.txt] in 02 is [#wait 5000 //all #wait 5000 //biome crimson normal #wait 5000 //biome corruption normal #wait 5000 //biome hallow normal #wait 600000 timeline start 01.txt] this commands with two bars "//" is from WorldEdit, Is for recover world of crimson and corruption every 10 min, but the pluggin don't exe the commands whith this two bars.. only whihout bars =/, have some fix for it?
Try using a single /. i.e., Code: [#wait 1000 timeline start 02.txt] [#wait 5000 /all #wait 5000 /biome crimson normal #wait 5000 /biome corruption normal #wait 5000 /biome hallow normal #wait 600000 timeline start 01.txt]
Hello! I'm currently running into a bit of a problem here. I'm trying to create a timeline to do a weekly reset of my server. Most of it works fine, including the fix for the worldedit issue, however the commands /bringtospawn(from https://tshock.co/xf/index.php?threads/1-16-bring-players-to-spawn.3000/), /resetplayers all(from https://tshock.co/xf/index.php?threads/1-16-ssc-character-reset.3059/), and /restart(found in the default TShock command list) state that they're invalid commands upon running the timeline. Separately, all three work fine. Here's the timeline: Spoiler //Resets world back to default #wait 604800000 //1 week bc Server will reset in 30 seconds! Thanks for playing! #wait 15000 bc 15 seconds... #wait 5000 bc 10 seconds #wait 1000 bc 9 #wait 1000 bc 8 #wait 1000 bc 7 #wait 1000 bc 6 #wait 1000 bc 5 #wait 1000 bc 4 #wait 1000 bc 3 #wait 1000 bc 2 #wait 1000 bc 1 #wait 1000 /schematic load World1 /all /paste /bringtospawn /resetplayers all /restart Help would be greatly appreciated. Thanks, Jerry
The WorldEdit commands require a / on the script because it's actually part of the command name (IE //paste). Non-WorldEdit commands should be written without the backslash. Try this: Code: #wait 604800000 bc Server will reset in 30 seconds! Thanks for playing! #wait 15000 bc 15 seconds... #wait 5000 bc 10 seconds #wait 1000 bc 9 #wait 1000 bc 8 #wait 1000 bc 7 #wait 1000 bc 6 #wait 1000 bc 5 #wait 1000 bc 4 #wait 1000 bc 3 #wait 1000 bc 2 #wait 1000 bc 1 #wait 1000 /schematic load World1 /all /paste bringtospawn resetplayers all restart By the way, I think restart is not a good choice if what you seek is an automatic reboot. AFAIK it always ask you to choose a world, even if you have only one. If I'm wrong, please correct me..
Thank you, I shall attempt that once I get back to the computer to run the game in. I've restarted my server numerous times, it's auto-set to load the same world, so for me that's no issue.
I'm aware it's been a while since a new post on here, but an inquiry has come up. How do I have a timeline run every time the server restarts?