Pickpocketing RP

Discussion in 'Plugin Requests' started by Ekoro, Dec 22, 2018.

Thread Status:
Not open for further replies.
  1. Offline

    Ekoro

    Plugin Category: Economy & PvP

    Minecraft Verison: 1.12.2

    Suggested Name: MythicPickpocket

    What I want: I've experimented with multiple plugins, but none offer what looking for. I would love to see a plugin that allows players to right-click another player. The initiating player would get a chat message with clickable options asking "Attempt to pickpocket {Player}?" "Accept" "Deny"
    If a player "Accepts" they would get a message that says "Pickpocket how much?" with clickable options: "0.3% | 20% failure" "0.75% | 50% faulure" "1% | 85% faulure"
    (The initial value would chose the percent of their targets balance they try to steal. The second value is the chance to force the "failure" scenario.

    ---
    When a player "Accepts" They would have a boss bar fill up over a configurable amount of time. If the player & target move out of a range of 2 blocks during the timer, the attempt would force a "failure."

    When a player "succeeds" they would take a configurable percent of the targets eco balance.
    When a player "fails" a configurable command will have a configurable chance to be run on the failed player
    (EXAMPLE:)
    #command to run on failure.
    fail-command: jail {player} 2 20seconds
    #percentage chance to run failure command. (IE 0.5 = 50%. 1.0 = 100%)
    fail-command-chance: 0.55
    --

    If a player is successfully pickpocketed they would have a 20 minute cooldown before anyone can attempt to pickpocket them again. (It would be amazing if the cooldown continued while they are offline)
    Message when attempting to pickpocket someone on cooldown: "This player has been pickpocketed to recently."
    ---

    If a player attempts to pickpocket someone that is already being pick pocketed, it would run the failure command on all pick pocketing players.

    ---

    Ideas for commands:
    /MPPplaceholder
    (Maybe to allow interaction with plugins that look for command runs? Such as deluxe tags.)

    Ideas for permissions:
    pickpocket.allow (Maybe? Allow players to use the plugin to attempt to pickpocket. Or allow it by default)

    When I would like it by: This could be quite the effort, so no time request at all. I only ask that if you have interest in developing it, let me know! :)
     
    Last edited: Dec 23, 2018
  2. Offline

    chogster

    I can give it a go for you. I've got no experience with entities within range but hopefully it shouldn't be to complicated. What economy plugin do you use? or would you rather I set it up so you can run a command ("/balance take <player>, /balance give <player> for example) when a successful pick pocket happens?
     
    Ekoro likes this.
  3. Offline

    Ekoro

    I'm using essentials, but actually running a command to take money could make it more universally compatible. :0
     
    Last edited: Dec 23, 2018
  4. Offline

    Eccentric_Gamer

    Or you could simply use Vault, which links almost every economy plugin out there. It's almost completely universal.
     
    Ekoro likes this.
  5. Offline

    Ekoro

    Yes, sorry, we do also use vault.
     
  6. Offline

    Eccentric_Gamer

    Are there any times where you can't pickpocket (in a certain world, or perhaps a permission for people who are unpickpocketable)?

    Also, does the percentage fail chance happen after the 2 seconds (configurable) of staying near them, or right when they right-click the other player?

    And will there always be 3 options, or how will that work. Are you saying the fail command should be the same for all 3 options or a different one for each option?

    Sorry, lots of questions. :(
     
    Ekoro likes this.
  7. Offline

    Ekoro

    No worries! I'm just super stoked to see someone trying to develop this!
    --
    For "my" server, I planned to let people pick pocket anywhere. A permission to prevent being pickpocketed would be an awesome donor perk though! How the node is written isn't important, as long as you let me know what it is. :)
    --
    I was hoping the fail event would run after the timer. So once the timer expires they either succeed and get their victims money, or they have the fail command(s) run on them.
    For instance, the example in my original post:
    #command to run on failure.
    fail-command: jail {player} 2 20seconds
    #percentage chance to run failure command. (IE 0.5 = 50%. 1.0 = 100%)
    fail-command-chance: 0.55

    Would have the player jailed to jail "2" for 20 seconds using "/jail" after the timer, if they failed.
    --
    I figured the fail event would be the same for each of the 3 options. The options would each have different chances to fail though, then if they DO fail, the fail command would have a "fail-command-chance:" to be run. I just wanted players to have the option to try stealing more or less money at once, for different chances of success.
     
  8. Offline

    Eccentric_Gamer

    Wait. So they pick an option (say 4% of their balance with a 50% fail chance) and that 50% fail chance goes through, they have a (fail-command-chance, so 55%) chance of that command running, and a 45% chance of nothing happening?

    Basically, if you fail, there's a chance the command goes through and a chance that nothing happens (configurable).

    EDIT: I can do the cooldown while they are offline, but not when the server is offline, right? I will make it run off server time, which is easier anyway, if that's okay, instead of real time.
     
    Last edited: Dec 24, 2018
    Ekoro likes this.
  9. Offline

    Ekoro

    (Thanks for all this effort. btw.)
    Yes! there is a chance that the failed pickpocket will not run the fail-command. I figure this allows players to not always be "punished" when they fail. Encouraging people to sometimes try the more risky pickpocket options.

    --
    Running on server time is perfect. Sounds good!
     
  10. Offline

    chogster

    Let me know if you want anything changed/added or find any bugs. The permission to allow someone to pickpocket is "pickpocket.allow" and I also added one which excludes someone from being pickpocketed ("pickpocket.exclude") but I couldn't test it so I don't know if it works.
    https://www.dropbox.com/s/qxy2xq073006o3d/MythicPickpocket.jar?dl=0
     
    Last edited: Dec 26, 2018
    Ekoro likes this.
  11. Offline

    Ekoro

    Wow, the config options are great! I'm testing it all out now and I'll let you know if I come across any issues. I'm actually really impressed so far though. :0

    Both permissions work perfectly for me, thanks for including this feature! The only issue Ive seen is that players can attempt to pickpocket from further than 2 blocks. I totally didn't think about that when requesting the plugin. haha. Would you be able to change the pickpocket distance to 3 blocks?

    --
    Sorry if that's a bit to picky haha. Again, thanks for the effort!

    Oh I did notice one major issue. When players click on citizens NPCs they get the pickpocketing options. haha

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Dec 27, 2018
  12. Offline

    chogster

    Ekoro likes this.
Thread Status:
Not open for further replies.

Share This Page