[MECH] Autorun Commands v3.2.4 - Set custom commands to run automatically [1.5.2-R1.0]

Discussion in 'Archived: Plugin Releases' started by LittleGruz, Oct 24, 2011.

  1. Offline

    LittleGruz

    Autorun Commands - Set custom commands to run automatically
    Version: 3.2.4

    Made in response to this thread.

    Visit the BukkitDev page for more details and downloads.

    Want to execute a command which displays stats just by right clicking the desired player? Or how about giving them a rose or 64 many, many times with ease? Or even make a command run which kicks players if they walk over a certain block? You can do that and more with this plugin!

    Features:
    • Allows the execution of a command simply by right clicking on a player
    • Allows the execution of a command simply by walking over a block
    • Allows the execution of a command simply by pressing a stone button
    • Allows the execution of a command simply by dying
    • Allows the execution of a command simply by respawning
    • Allows the execution of a command at server start up
    • Allows the execution of a command on a regular interval
    • Allows the execution of a command when a player joins
    • Allows the execution of a command when a player first joins
    View the source here.

    Check out my sweet site here.

    Enjoy my mods? Donate here! Dislike my mods? Donate here (and give feedback)! Powers of two are cool (e.g. $1.28, $2.56, etc.).

    Changelog:
    Past versions (open)
    Version 3.2.2:
    • Allow death commands to be set with GLOBAL.
    • Fixed problem of not being able to set OP commands for auto death commands.
    Version 3.2.1:
    • Replaced depreciated code.
    • Fixed some player messages.
    Version 3.2:
    • Option to have a delay for join commands added.
    • Bug fix for OP startup commands.
    Version 3.1.2:
    • Fix for when Multiverse would not load before AutorunCommands.
    Version 3.1.1:
    • Support for the plugin MultiWorld.
    Version 3.1:
    • First join commands.
    • Toggle for first join commands.
    • Multiple join commands executed.
    Version 3.0.3:
    • Fixed bug where respawn commands are executed when player was loading.
    Version 3.0.2:
    • Fixed bug which caused multiple instances of repeat commands to run.
    Version 3.0.1:
    • Fixed bug which occurred if there was no join command.
    Version 3.0:
    • Finally fixed multiworld bug.
    • Added display commands for blocks.
    • Added display commands for repeating tasks.
    • Added display commands for commands.
    • Command blocks can only be destroyed by an OP player.
    • Remembers the time remaining for a repeating task when the server is shutdown.
    • Allows commands to be executed when a player joins.
    Version 2.7.2:
    • Remove repeat command bug fix.
    Version 2.7.1:
    • Bug fix which caused the repeat commands to be saved and read incorrectly.
    Version 2.7:
    • Allows commands to be executed at a set frequency.
    Version 2.6:
    • Allows commands to be executed upon a player's death.
    • A myriad of bug fixes
    Version 2.5:
    • Allows buttons to cause a command to execute.
    • Fixed op command removal.
    Version 2.4.1:
    • Changed event listeners to support the new Bukkit event system.
    Version 2.4:
    • Added op support for command blocks.
    • Added a remove command command.
    Version 2.3:
    • Added ability to set commands to run at server start up.
    Version 2.2:
    • Added the ability to assign commands which are run by an op (console).
    • Allow commands to be executed upon player execution.
    Version 2.1:
    • Made command blocks more responsive.
    Version 2.0:
    • Gave blocks to ability to initiate the execution of a command.
    Version 1.0:
    • Added the ability to have a global command.
    Version 0.1:
    • Release.
     
    sk8r776 and Lextao like this.
  2. Offline

    Dominic

    Take your time! Real life is more important ;)

    Can't wait for it to be fixed though...this plugin offers a cruical piece of a server that I can't find ANYWHERE else. I hope you can find the fix soon :D!!!
     
  3. Offline

    LittleGruz

    Nowhere else, huh...time to start with the extortion! Mwhahahahahah!
     
  4. Offline

    Dominic

    Haha it's true. Spent at least 1 hour searching for something like this. Nope. Can't find it.
     
  5. Offline

    Dominic

    Hey guys, just FYI. If you are using a windows server ( :p ) just use a .bat file to copy and paste the file upon every restart if you're having issues with the blocklist.txt dissapearing. It's a dirty work around for now but it works for me! :D!

    Not sure if anyone needs an example, just shoot me a message if so.

    EDIT: Hey LittleGruz, really love your sense of humor and attitude. I love the potato variable in this plugin and your other remarks throughout your posts. Keep up the good work on this awesome plugin!!
    /donate
     
    LittleGruz likes this.
  6. Offline

    LittleGruz

    Thank you so much for your kind words. They really mean a lot. *big bear hug for Dominic*

    I love my sense of humour and attitude too! It seems to come from only taking things as seriously as they need to be (so I am not serious terribly often) as well as my desire to continue to be different/unconventional. It keeps life interesting :).
    I mean, what kind of "normal" bloke would have this as their websites sitemap? Or calls himself LittleGruz when people need to kick him in the crotch to see eye to eye? Or teaches emus to steal other peoples shiny stuff when they are not looking?
     
  7. Offline

    beatlesboy67

    I like this alot, but i am just wondering if you could make it so multiple commands ca bu run from one reapting command?

    If there already is please tell me

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 20, 2016
  8. Offline

    LittleGruz

    beatlesboy67
    It probably is possible, but a similar effect can be achieved by setting multiple repeating commands with the same repeating period.
     
  9. Offline

    Dominic

    Hahahahaha. Wow at that. You sir. Take the cake ^_^

    Keep up the good work. Enjoy life and the etc. Lookin' forward to an update ;) (Slightly creepy face?)
     
  10. Offline

    LittleGruz

    Dominic
    @WhoEverElseCares

    With just an hour left of my Monday, I manage to release version 3.0 from my cave!

    It seems that wretched block file disappearing act is due (at least in part) to loading up before the Multiverse plugin, which is fixed now. If any of you still have this issue and have a different multi-world generating plugin, please tell me its name and I will try to sort it out.

    Other interesting tidbits with this update is the addition of 3 new display commands for blocks, repeating tasks and added commands as well as allowing only OP players to destroy a block with a command set to it, allowing a command to be run when a player joins and making the plugin remember the time left of a repeating tasks period when the server shuts down (e.g. if '/say LittleGruz is awesome' runs every 5 seconds and the server shuts down after 3 seconds, then it will resume repeating with 2 seconds left when the plugin is reloaded).
     
  11. Offline

    Dominic

    In one hour? Most efficent developer I know...

    Hey guys, I only had 15 minutes to work today...BUT I SOLVED CANCER. Haha, thanks man! Muchly appreciated. Now I just need to get off work so I can play...eight hours shifts ._.

    Hope your exams went well!
     
  12. Offline

    Beimeith

    Upon upgrading to version 3.0, I now get this every time I start the server:

    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.
    13:11:14 [INFO] No original repeating task remaining file, creating new one.

    I also get this:

    13:13:27 [SEVERE] Could not pass event PlayerJoinEvent to AutorunCommands
    org.bukkit.event.EventException
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:304)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.jav
    a:62)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.j
    ava:459)
    at net.minecraft.server.ServerConfigurationManager.c(ServerConfiguration
    Manager.java:132)
    at net.minecraft.server.NetLoginHandler.b(NetLoginHandler.java:129)
    at net.minecraft.server.NetLoginHandler.a(NetLoginHandler.java:41)
    at net.minecraft.server.NetworkListenThread.a(NetworkListenThread.java:6
    1)
    at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:567)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:459)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
    Caused by: java.lang.NullPointerException
    at littlegruz.autoruncommands.listeners.CommandPlayerListener.onPlayerJo
    in(CommandPlayerListener.java:116)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:302)
    ... 9 more

    and finally, my previously configured commandblocks do not work. I have tried copying the blocklist.txt from a backup (I have the deletion problem as well from upgrading), but that does not help.

    I've gone back to 2.7.2 for now, which I might suggest other people do as well until it gets fixed.
     
  13. Offline

    jycs

    Hello,

    I'm looking for a possibility to send commands on a set (day):hour:minute and ideally with variables, like a macro.

    It's possible ?
     
  14. Offline

    LittleGruz

    Whoa. I am on it.
    Also for the command block files to work, in the file you will need to change the world UID (the horribly long string) to the human readable name for the world (e.g. world).

    Seems possible and interesting.
     
  15. Offline

    Dominic

    Beimeith
    Are you running the most up to date bukkit?I haven't quite had this issue reported to me yet. I will have to check for myself later.... Might be plugin conflicts?
     
  16. Offline

    jycs

    And "x" time after someone is saying "a text".
    And "x" time after someone is loging on. (I'm not lucky with your plugin)
     
  17. Offline

    Beimeith

    I am running 1.2.5 R3 on java7 x64

    I tried it again, and it looks like it was not creating the new 'joinList.txt" and "taskRemainder.txt" files and that might have been the cause. I restarted the server about 4-5 times and they finally showed up and I stopped getting spammed.
     
  18. Offline

    LittleGruz

    I never liked that game. The pay-cheque game played every now and then does kinda make up for it though.
    Oh, and I have also developed a unified field theory which makes string theory look like a childs crayon drawing of the Mona Lisa by comparison. That was a tricky one so it took about 25 minutes.

    Thanks, I hope so too.


    I can not seem to reproduce that problem with the spam of missing file messages, but I have managed to find why the exception for join commands is thrown.

    Version 3.0.1! Fixes the aforementioned join command bug.
     
  19. Offline

    Beimeith

    I think the cause was it was not generating the new files for me for some reason. When they finally showed up I stopped getting spammed. The question then becomes, why wasn't it generating the files? :(

    Also, changing the string to my world's name worked for my commandblocks, and the file is no longer being wiped.
     
  20. Offline

    jycs

    Do you think to add what I wrote? If yes, when you can please, because I found a plugin that does 1/4 of what I research (it's already not bad).

    More clearly I research :

    "if the clock is 'xx:xx', type /thecommand"
    "if the clock is between 'xx:xx' and 'yy:yy'... type 'x seconds' after serveur is on /thecommand" << indispendable for me.

    secondary but very usefull too:
    "if a player x logon between 'xx:xx' and 'yy:yy', type /thecommand"
    "If a player x says y, type /thecommand"

    But the problem is that without an ergonomic config file, it will be impossible to do simply a script...

    Thank you, I am eager to find that features.
     
  21. Offline

    LittleGruz

    After thinking about it for a bit, I have decided I will not add it since I feel it is out of this plugins scope. But thanks for the suggestion anyway.
     
  22. Offline

    jycs

    Without a clock your plugin is useless... next...
     
  23. Offline

    Dominic

    That's really disrespectful man. That's like saying 'You don't sell tacos at your hamburger stand? Well, your hamburger stand is useless then.'
    Come on man, did you really need to post that ?
     
  24. Offline

    jycs

    Sorry but it's true, a macro without a clock is like... Something useless. He seems to not be motivated :D
     
  25. Offline

    COOKIE_EATER_13

    HELP when i try to add a repeat command it does not work I go /addrepeatcommand restart reload 1200
    And yes i want to restart my server like every 3 hours Please help me
     
  26. Offline

    LittleGruz

    Yep, totally useless. Absolutely no one has downloaded this plugin and I have had no motivation to work on this plugin at all since its release.

    But I see you have edited your post after my decision, I did not realise you basically wanted a clock with 'alarms' that trigger commands. I am curious though, when you say "clock", do you mean the clock on the server?

    It looks like you are not using it properly. To use that command properly you need to create an identifier for your restarting command:
    e.g. /addopcommand serv_restart reload
    Then you can use the repeat command
    e.g. /addrepeatcommand serv_restart 1200

    As a side note, the interval is in seconds so: 1200 == 20 minutes

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 20, 2016
  27. Offline

    jycs

    I mean 12:00 12:30 0:40 (hours:minutes)
     
  28. Offline

    LittleGruz

    But did you want your desired clock to be synchronised with the clock on the server or something else?

    Looking at your comments here and on this (discontinued) plugin thread, to meet both your primary and secondary needs you will have to make separate plugin (unless you find another one). So it would be best to describe your scenario and requirements in the requests forum.
     
  29. Offline

    jycs

    Said earlier that you do not know how to do...

    I only wan't a possibility to launch command between 2 hours, but gives up...
     
  30. Offline

    LittleGruz

    It may be different for you, but when someone repeatedly says uncalled-for negative things about me, I feel less compelled to help them with their problem.
     
  31. Offline

    skywalk

    I'm wondering how a "/time set 0" command will look like?
    Can't get it working in any way. Since adding the command will have a number for interval, resolving in error if you wanna go "/time set 0 600".
     

Share This Page