Autorun Commands
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 mod!
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 join
How to use:
Step 1:
- Assign a command to an identifier.
- For this example, we want to say 'Hello <playername>!' and we will assign it the identifier "wassup"
- type: /addacommand wassup say Hello potato!
- Adding the word 'potato' will substitute the name of the player who is the target of the event
OR
- Assign an OP command to an identifier.
- For this example, we want to give me 64 TNT blocks and assign it the identifier "TNT_spam"
- type: /addopcommand TNT_spam give LittleGruz 46 64
Step 2:
- Assign the identifier to an appropriate event.
- For this example we will assign "TNT_spam" to occur every 10 minutes (600 seconds) and to assign "wassup" to be run when a player right clicks another player
- type: /setclickcommand wassup GLOBAL
- NOTE: The use of the word GLOBAL (all caps) means that when anyone right clicks someone, "wassup" will be run instead of just me running it
- type: /addrepeatcommand TNT_spam 600
Step 3:
- Watch them trigger!
- Now if I right click someone called "Bruce". I will execute the command '/say Hello Bruce!'
- And every 10 minutes I will get a full stack of TNT
Future plans:
- Sleep
If you have any comments or questions, please head on over to the forums.
View the source here. Check out the main website here.
Apparently, the lovely Socram8888 has fixed an error in my code that produces ConcurrentModificationExceptions. Get it from Github here.
-
View User Profile
-
Send Message
Posted May 6, 2012@crehop
Probably not within any reasonable time period.
@Anonymous777
Thanks
I think that would be an idea which I should implement eventually, but unfortunately for you at the moment, the time left on any repeating command is reset on startup.
-
View User Profile
-
Send Message
Posted May 6, 2012hey nice plugin but i have a little question: it is time persistence? because i make daily restarts and would like to use this plugin du run a command in a 24h interval
-
View User Profile
-
Send Message
Posted May 6, 2012any way you can add region support so if i have a command on death in a certain region it will say/do something different
-
View User Profile
-
Send Message
Posted May 6, 2012@Ocomobock
You use /addopcommand to create a command that will be run by the console (op). If the command to add potion effects requires the name of the player, then you just type 'potato' where the players name should be.
e.g. '/addPotionEffect potato'
The above command will be run by the console as '/addPotionEffect Ocomobock' if you stepped on the block.
-
View User Profile
-
Send Message
Posted May 4, 2012Is it possible to let players who don't have permission to a command only be able to run it by walking over a block, or pressing a button, etc? I'm using permissions, and there's a plugin that lets you activate the effect of a potion by running a command. People who don't have permission to it just get an error message.
-
View User Profile
-
Send Message
Posted May 3, 2012@Tonopia
Having a command run when someone says a certain phrase sounds like a good idea...particularly if you want to freak people out. But you are correct with the observation that it is not possible, yet.
@icheesy
If you add a command with /addacommand then any situation which it is run(e.g. right clicking, button press, respawn etc.), it will be run by the player that caused the event.
I do not believe I understand what you mean by not 'binding' the command properly, do you mean binding the command to the player, block or console? Due to my misunderstanding, I am not sure if I have answered you properly.
-
View User Profile
-
Send Message
Posted May 3, 2012Please make the player actually run the command. Do not bind the command.
Or have an option for "/addplayercommand <identifier> <command> [arguments]>
As I made some aliases of commands from CommandHelper and the user has to actually RUN the command (no binding).
It would be a great addition. It would be great if you could not bind the command, but have the player run it.
-
View User Profile
-
Send Message
Posted May 1, 2012Is it possible that you could add to this when a something is said on the server like "Blah won!" It can run a command. I have been trying to figure this out with your plugin but it does not seem possible.
-
View User Profile
-
Send Message
Posted Apr 30, 2012@Minerscentral
That depends completely on when you want them to be teleported.
If you want to teleport players when they respawn, use: /setrespawncommand
Or to teleport them when they step on a block or press a button, use: /setcommandblock
-
View User Profile
-
Send Message
Posted Apr 30, 2012hello i would like this to warp all my players to one area how can i do this?
-
View User Profile
-
Send Message
Posted Apr 20, 2012@aczchef
Ah. I see. Fixin' it up now
EDIT: Fixed in v2.7.1
-
View User Profile
-
Send Message
Posted Apr 18, 2012@littlegruz
i understand how it works but the repeat-file that saves the command. saves it as the command not the identifier so when it tries to read "say hey 5" it reads the command as say and the interval as hey because it comes second. there's an error saying incorrect repeat command then on the next server restart it removes the command. but i did /addacommand test say hey. then did /addrepeatcommand test 5. but it is saved as "say hey 5" in the file.
Edit: i haven't made any other type of commands just repeat commands. so i dont know how their saved. except that the command is second not first
-
View User Profile
-
Send Message
Posted Apr 17, 2012@aczchef
Correct, none of them do (EDIT: i.e. None of the events take multi worded commands). You need to add the command you want into the program with /addacommand (or /addopcommand) then use the identifier you used there with the /addrepeatcommand command.
e.g. /addacommand talk say hey
/addrepeatcommand talk 5
-
View User Profile
-
Send Message
Posted Apr 17, 2012Repeat commands doesn't work for 2 worded commands
repeatfile:
<command> <time>
say hey 5
file tries to read it as Command: say Time: hey.
then deletes command
it doesn't use the identifier. just uses it to set it
-
View User Profile
-
Send Message
Posted Apr 17, 2012@Cat121
Hmm, this seems to the same error as Esaych below. I will try and fix this evasive bugger.
Sorry about the slowness, since the notification system on this site for comments is...well there isn't really one so I tend to miss comments.
-
View User Profile
-
Send Message
Posted Apr 8, 2012This is really GREAT !
I was planning to code something like that and i have been told of your plugin. It's exaclty what i needed :)
Edit : maybe you should add a notification when we remove a command from a block.
Edit 2 : after a few moment, i have an error : http://pastebin.com/siKwcLQk
But it's only when :
- i sneak
- i look forward
- i break a block byhitting is upper half
- there are three free blocs between
Like this, no problem
Like that, error
I have the latest version, of course. Should i open a ticket ?
Still editing : i have an other "could not pass playerinteractevent to autoruncommands" but i was flying. You may have a problem in your listener :x
Final edit : waw, it's been a while since you didn't say aything in fact.
-
View User Profile
-
Send Message
Posted Mar 20, 2012@Esaych
Judging by the position of the error that is thrown, I think you may have an old version. Please update and check again.
In the future please use something like pastie.org for dumps and the post the link it gives you. I have opened up a bug thread in the forum as well.
@FiddyCraft
There is a weather change event which I could use easily, but I think you may mean for when people move between different biomes which would be quite tricky.
-
View User Profile
-
Send Message
Posted Mar 11, 2012any way you can add an option to connect this with seasons so like every season you can run a command >_>
-
View User Profile
-
Send Message
Posted Mar 7, 2012Works OK with CB 1.2.3 Beta
-
View User Profile
-
Send Message
Posted Feb 19, 2012How about a command that executes multiple commands?
For example /autorun ban KJanar
This command would run:
bukkits ban system /ban KJanar
authme system /authme unregister KJanar
easyban /eban KJanar
Thats the basic idea.
Thanks