Plugin category: Doesn't matter Suggested name: CommandCodes (Whatever) What I want: A plugin that can generate a "code", that can be used to run a command once. For example, you generate a code for a player, and this player can use /ccc code and it will run the command that the admin bound to it. When the code is used, it will no longer work again. I also want a option for how many codes the admin want to generate, and these codes should be stored for later use, and the admin can list codes (and it also show the bound command) For example, the admin uses /ccc list and a list (with pages if there is many codes) pops up in the chat and show the code + the command that was bound. If the admin want to bind a command and generate code(s) this is how it's done: /ccc generate [command] [Number of codes that is generated] Note: it should support spaces, for example: /ccc generate time set day 1 After the Admin done that command, the codes are generated. When the Admin uses /ccc list the codes will list in the chat like this: Current codes: ABC123: time set day Note: the codes should be random, and not the same if you want many codes. (It can be 6 digits, it doesn't really matter) It should also log if the code is used already, and wich player that used it with /ccc ABC123 So if you do /ccc used it will list the code as normal: ABC123: time set day by Player123 When the code is used it will no longer be visible in /ccc list Ideas for commands: /ccc generate [command] [Number of generated codes] - Generates codes with the [command] and generating [number] codes. /ccc code -Use the code to run the bound command once, and the same code won't work anymore. /ccc list - Lists the available codes, and wich command that is bound to the code. /ccc used - Lists the used codes, wich command that was bound to it, and wich player that used it. (optional, it can show date and time when the player used it) Ideas for permissions: ccc.generate - so the player can generate codes. ccc.use - so the player can use /ccc code ccc.list - so the player can list available codes. ccc.used - so the player can list used codes. When I'd like it by: Before the new eula of minecraft begins Why i want this plugin: When the new minecraft eula begins (1st august.) you can no longer sell things ingame. (Directly) So, we will sell codes via email, (has nothing todo with the minecraft eula yet ) and these codes that we email our players can later use the codes to get ranks. We sell the codes outside minecraft (meaning that we will bypass the eula) and it should be legal to use codes with a plugin aswell
Jocke155 I'm sure that Mojang won't be so happy about your 'bypass'. I see two possible outcomes for this scenario. a) Mojang is slightly ticked but because your server is small, just enforces 'email-selling' as against the EULA too b) Mojang is very ticked and sues you for all you're worth.
zombiekiller753 Before the player USE the code, it's outside the EULA It's just a code that we sell outside the game But the code is generated in the server ofc.. For example, you take a piece of paper.. and write a code on it, and sell it to a friend.. The purchase was totally outside Minecraft.. BUT the player can also USE the code, if he wants.. The paper is sold, not items or something ingame BEFORE the code is used.
Jocke155 Look at it how you may, but I'm sure Mojang's lawyers will make mincemeat of you. In the words of just about any investor on Dragon's Den (Great show by the way)..
simgar98 Yeah... But anyway, Mojang can't stop anyone for selling the codes (Outside the game) The problem might be that it CAN be used ingame aswell, but the owner of the code can choose to use it or not
zombiekiller753 There are plenty of servers just choosing to ignore the EULA the least of minecrafts worries is a server like Jocke155 's who is choosing to find a way around it.
Onlineids Yeah.. I don't wanna "Ignore" the eula, but the server still need money to run.. else it must close.. And i'm good at problem solving, and this was my first idea.. Mojang can't tell me to not sell codes that are sold outside the game..
Jocke155 Donations without game changing stuff, hats etc, spark trails, pets that don't do anything, balloon above their heads. Money for playtime that is always the same amount for everybody.
timtower So: you sell this "code" outside the game... Totally outside the game.. This isn't yet a problem. The code CAN be used, for running a command. Will this be a big problem? I guess not Mojang doesn't even know that the codes are sold for real money
Still, you are just not allowed, simple as that. You are making a currency, a very small currency, your codes! A paper bill is pretty much the same as that code, you can pay something with it (on your server) and you can get it with some money... it is just setting up another currency, so it is still illegal, done. Just ignore the EULA, small servers will slip thru, they wont be worth the effort (probably)
simgar98 Better to sell it outside totally anyway the plugin would be nice for other purposes aswell..
Well, it is pretty much the difference between selling it from paypal directly to the server or paypal > whateveronlinecurrencylikepayoneerorwhatever > server... I don't think it's worth the effort, since it just doesnt do what you think it will?
I'll write this plugin, because it seems a cool idea in general. Quick question: For the list of previous codes, how long do they need to persist - is it OK if you can't view them anymore after a server restart, or do they need storing?
simgar98 As i said, it might be good for other purposes aswell But i see it this way: PayPal > code > server Otherwise it would be: PayPal > server The CODE replaces the direct link from REAL money to the server, but ofc the codes value will be the same as real money. The green color shows that the selling of the code is legal (It's outside the game!), But that the problem might be using the code on the server. If you pay real money directly the whole thing turns bad.. PandazNWafflez Yeah it must be available after restart EDIT by Moderator: merged posts, please use the edit button instead of double posting.
I'm not incompetent - I would have no difficulty storing them, it's just that if it isn't necessary there's no reason to do it. Seeing as the requester wants it I'll do it, probably not in YAML though. Jocke155 I've made a solid start on this, and I more or less just need to implement the commands - the framework is pretty much done. The source is currently hosted at https://github.com/DziNeIT/commandcodes However, I won't be available for the next few days. You mentioned it must be before the EULA enforcement starts, and it will be, but I won't be able to work on it for the next few days. EDIT by Moderator: merged posts, please use the edit button instead of double posting.
PandazNWafflez In your code, when generating the code you should execute this runnable Code:java new Runnable(){ @Override public void run() { UUID.randomUUID().toString().replace("-", "").substring(0, 6); }};
Why? TheSpherret That takes 100ms. Long time. It isn't really necessary for this. EDIT by Moderator: merged posts, please use the edit button instead of double posting.
Anyways Jocke155 I've made loads more progress on this. I've changed storing codes to JSON instead of YAML, and I've also now written the '/ccc generate' command. Only thing here is that you have to write the amount of times the code can be used before you write the command, as if you were to write: /ccc generate time set day 1 Then the plugin would have no way of being able to tell whether the 1 is part of the command or not.
The eula states that you cant give normal players a playing advantage over others. So this would constitute as giving an advantage. So its illegal
PandazNWafflez This might be a problem yes... Maybe a special character when you are choosing how many codes that are made? Example: /ccc generate time set day #1 Then it will also be able to have numbers in the command. For example: /ccc generate time set day 100 #1 Geekxboy So, you can't give the players advantage for free?
Jocke155 Would it not be acceptable to just have the <amount> argument before the command argument? That's how it is currently. Jocke155 Unless you want me to change the generate command as above, I'm pretty much finished. I'll need to test it, but it should be working. EDIT by Moderator: merged posts, please use the edit button instead of double posting.
Jocke155 In that case, I'm done. https://dl.dropboxusercontent.com/u/61889828/Dev/CommandCodes.jar I've tested it so there shouldn't be any issues, but if there are, tell me and I'll fix them.