Prevent selling items given with cmds

Discussion in 'Archived: Plugin Requests' started by chuiby, Aug 16, 2011.

  1. Offline

    chuiby

    I have implemented a premium rank in my server.
    Those premiums can give themself items. But i dont want them to sell those items at the shop.
    I would like a plugin that could watch the player /item usage...
    I code C#, not java. I tried to code a plugin and i didn't liked coding in that language... even if java looks a lot like C#.

    Name of the plugin: cheatItems

    Settings for the plugin would look like that:
    Features:
    Show Spoiler

    Monitoring cheated block placing... on break then pickup...= +1 for the hacked blocks count of x type in the database

    Disabling certain items

    Disabling selling hacked items (The main reason of this plugin request)

    Anti block-giveaway to other players

    Disabling certain groups to give blocks to others

    Disabling certain players to give blocks to others

    Transfer the flag on the cheated item when giving away the item to someone else

    Limit the maximum of sell-able blocks to the legitimately gained blocks (i.e: i currently have 50 wool, i give myself 10 wool, i try to sell my 60 wool, it will automatically lower it to 50 wool


    Avaible commands:
    Show Spoiler

    /citem add blacklist 35:1 = add orange wool to disabled items
    /citem rem blacklist 35:1 = remove orange wool from disabled items
    /citem remove blacklist 35:1 = same as above and for the others rem|remove cmds
    /citem set giveaway false/true = disable/enable block giveaway
    /citem add shop-sell-cmd /shop sell {0}:{1} = add a new shop-item-selling-command-hook
    /citem rem shop-sell-cmd /shop sell {0}:{1} = remove a certain shop-item-selling-command
    /citem help = display help (obviously)


    Permissions nodes:
    Show Spoiler

    - cheatItems.blacklist.add
    - cheatItems.blacklist.remove
    - cheatItems.giveaway.set
    - cheatItems.giveaway.bypass
    - cheatItems.sellcmd.add
    - cheatItems.sellcmd.remove
    - cheatItems.bypass


    Note to anyone that may code this plugin: take care of the superpickaxe plugins, when a block is broken it doesn't trigger the event BLOCK_BREAK (or whatever the event is) on the player, so it will not remove it from the placed-hacked-blocks/hacked items database. Easy fix: make a cleanup function just like LWC (/lwc admin cleanup) to cleanup unexistant blocks or invalid blocks (eg: gold block got insta-broken then replaced by a dirt block).


    Thanks to whoever that is gonna code this =)

    Edit: i was pretty tired when i typed this, i might have made typo or even wrong words, just i've put /shop add instead of /citem add, so watch out ;)
     
  2. Offline

    chuiby

Share This Page