[RPG/FUN] PvPReward v1.1 - Killers steal money from their victims [953]

Discussion in 'Inactive/Unsupported Plugins' started by Codisimus, Apr 1, 2011.

     
  1. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    This page will no longer be updated. Please follow this project at the Bukkit Dev Page

    PvPReward - Killers steal money from their victims:
    Version: 1.1 (7/16/2011)
    Supports iConomy, BOSEconomy, Essentials, Permissions
    Download Page

    This plugin adds to PvP, in addition to any items that may be dropped, players also steal money from the players they kill. The amount stolen is configurable but is defaulted as follows. (Other variations explained below)

    This plugin does more than just add to PvP, it has many other features for when a player dies of natural causes.

    [IMG]
    Description:

    Scene01:
    Bob and Jacob have done nothing, all stats are base:
    KARMA POINTS: 0
    DROP PERCENT: 10%
    500 COINS IN ACCOUNT

    Scene02:
    Bob attacks and kills Jacbob, this will do the following things:

    - Bob will gain 2 karma points
    - Jacob will lose 1 karma point ( if he is at 0, it will stay at 0 )
    - Bob's chance for drop of gold will be increased by a 2% modifier if his karma is less than 50
    - If the chance for drop of coins from Jacob ( the killed ) is a success, a random value ( default range of 0%-5% ) will be taken from Jacob's bank account

    Scene03:
    Bob has been bad, and has killed lots of people, he kills Jacob again, the following things occur.

    - Bob will gain 2 karma points putting him over the 50 karma making him an outlaw
    - Jacob will lose 1 karma point ( cannot go below 0 )
    - Bob's chance for drop of gold will be increased to 100% since he is considered an ( outlaw ) and still gains +2 karma
    - If the chance for drop of coins from Jacob ( the killed ) is a success, a random value (default range of 0%-5% ) will be taken from Jacob's bank account

    Scene04:
    Jacob kills bob after bob has 52 karma, the following occurs:

    - Bob will lose 1 point of karma taking him down to 51
    - Bob is still an outlaw so he has 100% chance of drop of gold/coins
    - Jacob WILL NOT earn karma points because he killed an outlaw


    For example: If the modifier is set to 20, whenever an outlaw kills a non-outlaw, he gets 20% more coin on top of the rewards he already would have gotten (if he successfully gets the drops in the first place). Likewise, if the modifier was set to 150, he'd get 150% more coin.

    Now, more in-depth and complex mode: The modifier increases after certain karma thresholds. For example: You have set your options in the config file as follow: karmaThreshold: 10, outlawModifier: 2, modifierMax: 50

    With this, every 10 karma after 50 (60, 70, 80, etc.) will grant the outlaw a 2% bonus to all drops stolen. After it reaches 50% extra drops stolen, it stops increasing (as based on the modifierMax variable). It seems complex, and it's probably not for everyone, but it'd be cool in my opinion.

    (All of that is amount of coin stolen, not the rate at which they drop them, to make it clear!)

    Config Settings:

    RewardType may be any of the following:
    • Karma
    • FlatRate
    • Range
    • Percent
    • PercentRange
    • PercentKDR
    All other settings depend on what the reward type is set to.
    Karma:
    This type has the most features, It is explained above^, the settings are as follows:
    • Percent - The base percentage for calculating whether there will be a drop
    • Amount - The amount of Karma needed to be considered an Outlaw
    • High - The maximum percentage that could be taken from a killed players account
    • Low - The minimum percentage that could be taken from a killed players account
    • OutlawModifier - Outlaws steal an additional x%
    • KarmaThreshold - Increase OutlawModifier every x kills
    • ModifierMax - OutlawModifier will not go beyond x
    • Last three are further explained above
    FlatRate:
    The Killer will always steal a specific amount from the killed, the settings are as follows:
    • Amount - The amount of money that will be stolen upon each murder
    • All other settings don't matter
    Range:
    The Killer will steal an amount of money within a given range, the settings are as follows:
    • High - The maximum amount that could be taken from a killed players account
    • Low - The minimum amount that could be taken from a killed players account
    • All other settings don't matter
    Percent:
    The Killer will steal a certain percent of the killed players total balance, the settings are as follows:
    • Percent - The percent of money that will be taken from a killed player account
    • All other settings don't matter
    PercentRange:
    The Killer will steal a percent of money within a given range, the settings are as follows:
    • High - The maximum percent that could be taken from a killed players account
    • Low - The minimum percent that could be taken from a killed players account
    • All other settings don't matter
    PercentKDR:
    The Killer will steal an percent of money based on the two players KDRs. You receive a higher percent from players with a higher KDR (formula is killedKDR/killerKDR). This percent is taken from the killed players total balance. No settings are used.

    Features:
    • Configure how much money people get
    • Several reward methods/algorithms
    • Option to lose money upon death, whether PvP or not
    • Option of having tombstones instead of players dropping items
    • KDR Leaderboard
    • Configurable combat time
    • Optional penalties for logging or teleporting while in combat
    • Fully customizable messages
    • MultiWorld support
    • Uses iConomy, BOSEconomy or Essentials for money
    • Restrict use with Permissions
    • Included in CraftBukkitUpToDate for easy updating (make sure you come check the changelog if somthing is not working right)
    Commands:
    • /pvp kdr - Display total kills and deaths
    • /pvp karma - Display current Karma level and Karma level to be an Outlaw
    • /pvp outlaws - List current Outlaws
    • /pvp kdr - Display total kills and deaths
    • /pvp rank - List current rank
    • /pvp top - List top 5 KDRs
    Permissions:
    • pvpreward.getreward - no reward if killer does not have this node
    • pvpreward.givereward - no reward if killed does not have this node
    • pvpreward.ignoredeathtoll - will not be charged money when dying
    ToDo:
    • Add Leaderboard
    • Add option of changing an Outlaws permission group *Still trying to figure out the Permissions API
    • Add cooldown for Karma
    • Add drop options
    Changelog:
    Old Versions + ChangeLog can be found at Download Page

    Version 1.1 (7/16/2011)
    • Added Permission node for Ignoring DeathToll
    • Fixed kdr values getting reset
    • Fixed errors when Logging in combat
    • Added color support for all customizable messages
    Version 1.0 (6/26/2011)
    • Added config options
    • Penalties are now optional
    • Added a Penalty Message (DenyTeleMessage)
    Version 0.9 (6/26/2011)
    • Improved OP options
    • Updated Economy support
    • Got rid of Karma commands for non Karma users
    • Added grave feature
    • Added Leaderboard
    • Added cooldown for Karma
    Version 0.8.1 (6/13/2011)
    • Fixed PvP registering
    • Fixed money amount messages
    Version 0.8 (6/12/2011)
    • Cleaned up code/fixed errors
    Version 0.7.2 (6/4/2011)
    • Cleaned up errors and added error messages
    Version 0.7.1 (6/3/2011)
    • Various fixes and code cleanup
    Version 0.7 (6/3/2011)
    • Added Essentials support
    • Added customization options
    • Added option of losing money open death
    • Changed ModifierMax to support negative values
    • Added configurable combat time
    • Added penalty for logging or teleporting
    Version 0.6 (5/4/2011)
    • Updated to iConomy 5
    • Updated to build 740
    • Few various fixes
    Version 0.5 (4/15/2011)
    • Improved Karma system
    • Fixed percent of steal
    • Added /pvp commands
    • Added [Outlaw] tag
    Version 0.4 (4/4/2011)
    • New karma based reward system (set as default)
    • Added Permissions support
    Version 0.3 (3/31/2011)
    • Initial Release

    This post has been edited 1 time. It was last edited by Codisimus Oct 9, 2011.
    Joh, kahlilnc and Mitsugaru like this.
  2.  
  3. Offline

    Lars1011

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Looks good, I'll try it tomorrow! :)
  4. Offline

    darthsiddious

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    this looks cool, but could you possibly make it so only certain people can steal the cash? ie: only a barbarian class can rob citizens once he kills the citizen?
  5. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    This is what we talked about on my forums.

  6. Offline

    halvors

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Codisimus: Could you release source?
  7. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    @darthsiddious
    Permissions support should be in next version

    @riuthamus
    Sounds good, i don't quite understand all of it but if i have trouble while coding it ill talk to you (might take a little bit to get it exactly how you want it)

    @halvors
    I will start releasing source code with the next version
  8. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    You ever play lineage 2? It is a similar system. Perhaps a drawing with a diagram would help! :p
  9. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    nvr heard of it, yes a diagram proly would help
  10. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    [IMG]

    Scene01:
    Bob and Jacob have done nothing, all stats are base:
    KARMA POINTS: 0
    DROP PERCENT: 10%
    500 COINS IN ACCOUNT

    Scene02:
    Bob attacks and kills Jacbob, this will do the following things:

    - Bob will gain 2 karma points
    - Jacob will lose 1 karma point ( if he is at 0, it will stay at 0 )
    - Bob's chance for drop of gold will be increased by a 2% modifier if his karma is less than 50
    - If the chance for drop of coins from Jacob ( the killed ) is a success, a random value ( a variable in the config ) will be taken from Jacob's bank account

    Scene03:
    Bob has been bad, and has killed lots of people, he kills Jacob again, the following things occur.

    - Bob will gain 2 karma points putting him over the 50 karma ( outlaw marker)
    - Jacob will lose 1 karma point ( if he is at 0, it will stay at 0 )
    - Bob's chance for drop of gold will be increased to 100% since he is considered an ( outlaw ) and still gains +2 karma
    - If the chance for drop of coins from Jacob ( the killed ) is a success, a random value ( a variable in the config ) will be taken from Jacob's bank account

    Scene04:
    Jacob kills bob after bob has 52 karma, the following occurs:

    - Bob will lose 1 point of karma taking him down to 51
    - Bob is still an outlaw so he has 100% chance of drop of gold/coins
    - Jacob WILL NOT earn karma points because he killed an outlaw

    Hope this clears up the system.

    POSSIBLE VARIABLES:
  11. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Crystal, I hope I can have this ready for you by the end of the weekend
  12. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Donated for your hard work! keep up the good stuff, and .. perhaps maybe at some point you might want to code for me on the regular! :p
    MaltheF likes this.
  13. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    i appreciate the donation, i will most likely update tonight
  14. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    I have finished coding this however i cant really test it...
    PvPReward
    here is the test jar if you want to try it, i will proly be able to test it later today
  15. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    testing it right now!
  16. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    i forgot, all players involved must have pvpreward.reward in order to use this plugin
  17. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Correction, can you explain each of the config options for me?
  18. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    no... it should be 4 i think
  19. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Amount=50
    RewardType=Karma
    High=5
    Percent=10
    Low=0
    they are kinda vague bc for different reward types they do different things they are defaulted to wut you explained to me b4
  20. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    i got those, so...

    - Amount, is the Karma max, for 100% drop
    - ReardType is just the name for the points awarded for a kill?
    - High is the currency lost?
    - Low is the currency lost?
    - Percent is the default % for possible drop
  21. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    - RewardType is either Karma, or percent, or flatrate, or percentrange, or percentKDR
    since we have it set to karma,
    - Amount, is the Karma max, for 100% drop
    - High is the max percentage lost
    - Low is the min percentage lost
    - Percent is the default % for possible drop

    Does that help at all?
  22. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    perfect, now, what if a person wants to see their Karma? do we have a command to view that?
  23. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    once i get it functioning correctly i will add that along with seeing who are outlaws and also your kills and deaths
  24. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    So cool, we are testing it now! Right now people are saying they are losing currency but its not being reported as lost, they just say 0 lost, every time, despite the fact that they think they did lose some.
  25. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    but the money transition is correct?
  26. Offline

    Faust

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    I haven't tried the plugin yet, so I don't know if it already does this, but what about making an [OutLaw] Tag in the name of outlaws?
  27. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Thats our config, it takes the stuff but does not report that it took any, says took 0.0 And the person who killed did NOT get the money, although i lost the money
  28. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
  29. Offline

    riuthamus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Okay, it works, and reports, but its using decimals, our system uses integers only... :( But this is epic, we are having so much fun doing it.
  30. Offline

    Codisimus

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
  31. Offline

    Faust

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Minecraft account:
    MCUSERNAME
    Codi I believe theres a function named SetDisplayName or something a long the lines, that should help

Share This Page