Death reclaim npc

Discussion in 'Plugin Requests' started by sinating, Jan 9, 2019.

  1. Offline


    Plugin category: Death plugin

    Minecraft version: 1.12.2

    Suggested name: Death retrieval.

    What I want: Hello, i'd like a simple plugin where if a player dies, their items are not dropped but instead go into a system that can be reclaimed by an npc for cash depending on the players level.
    Example; Player dies to a mob, they respawn at spawn and walk to the retrieval npc, they right click and it and it tells them that in order to retrieve their items it will cost them X amount through the config. if they accept, they will be-able to take out the items. if they decline it will just end the convo, if they don't retrieve with in an hour the stuff will disappear. I am using vault and citizens 2.

    Can set custom permission that can reduce the cost by a percent
    Can set npc id through config

    Ideas for commands: Reload command

    Ideas for permissions: None that I can think of.

    When I'd like it by: Any time
  2. Offline


    I am not finished, but i would like you to test it out with multiple people.


    Notes: I know you want to set your own id and have a reload. I have not finished and only started a bit.
    Something i added was a gui so if a players die multiple times within the hour it will show all those times he died. I can change that if you want, like if you just want it to be the most recent death. Most stuff should be working in this version.

    I should be finished by this weekend since i have work but I wanted to give you a test version for any input that you want to change

    /deadnpc - Spawns the npc
    /confirm - confirms so you can get the items

    deadnpc.make - So you can make the npc
    deadnpc.confirm - lets player confirm with /confirm
  3. Offline


    Thank you so much, i'll check it out ^.^

    Edit: I've tried it out, seems like when the players die their items drop and it goes into the npc aswell. I really love how it looks tbh
    Last edited: Jan 12, 2019
  4. Offline


    Hey I finished the plugin. Changed tiny things to make it more user friendly. Now /confirm gives you the items instead of the player going back in and clicking it again.

    /deadnpc - Spawns the npc Got rid of command so you can set id in config like you wanted
    /confirm - confirms so you can get the items
    /deadnpcreload - reload config

    deadnpc.confirm - lets player confirm with /confirm
    deadnpc.reload - reload config

    Depends: Valut, Citizens

    Config (open)

    Cost: 100 #Cost to buy items back
    PercentOff: 10 #Percent off total So 10% off of $100 is $90
    NpcID: 0 #ID of NPC
    InventoryName: Death Items #Inventory name

    Edit: Posted without finishing post
    Last edited: Jan 12, 2019
  5. Offline


    So it scales off their current level? Also thanks soooo much <3 i'm really loving it and so do the players. For the percent off i was thinking I would beable to set multiple if i created that would have a permission i could set like

    PercentOff: 10 ### 10%
    Permission: warrior ### would be npcdeath.warrior

    if possible? :3
    Also a friend brought this up, but could we add a World selector incase we use different worlds that don't need it?
    I really do appreciate this <3
    Last edited: Jan 12, 2019
  6. Offline


    I saw the level part right now. I guess I forgot about it when making it. For everything else you want in the plugin I'll see what I can do. How would you like the level thing to work? Every so many levels it goes down in price or? Also if you find any bugs let me know. I tried to make sure there was no bugs or ways around stuff
  7. Offline


    Every level it will raise a percent per level, so the higher level you are the more it will cost to get your items back (since the armor scales level and weapons) But from that the percent off permission will decrease that amount by a certain amount.
  8. Offline


    In the config I got rid of
    PercentOff: 10

    Now to take off a certain amount of percent use the permission<percent>
    Example: <--- This will take off 50%

    I added in what worlds the plugin will work in the config. By default its the main minecraft survival words.
    The new config looks like this
    Config (open)

    Worlds:  #Set the worlds you want the plugin to work in
    - world
    - world_nether
    - world_the_end
    StartingCost: 100 #How much the player will pay with if they have 0 levels
    PerLevelPercent: 5 #How much by percentage the cost will go up. Since the starting cost is a 100 5% is only 5 so it will go up by 5 per level
    NpcID: 0 #The npc id that you want to use
    InventoryName: Death Items #The inventory name

    Since the player died their level resets. So their level hooks up to the chest they died with. So lets say they have 0 levels on one death so it will only be $100. Lets say they dont claim that chest and gained 5 levels and died again their next chest will be $125. Each chest will contain information about how many levels they had when they died and set the cost based on that. Hopefully you understand.

    Note: please make sure you fully stop the server and delete the all files in the plugin folder and then start the server with the updated version

    Last edited: Jan 13, 2019
  9. Offline


    Is it possible to make it not take their levels as it's a progression of the server and just check their level and base the cost off that? Other then that it's perfect and i'm inlove <3 I really really do appreciate this a lot.
  10. Offline


  11. Offline


    Thank you soo much.

    We found a bug, When someone that is lv 1 dies, and then a lv 1000 dies, the lv 1 has to pay $5000 instead of $100

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: Jan 14, 2019
  12. Offline


    I'll look into the bug as soon as I get time

    Edit: I think I found the problem, havent had time to test it

    Last edited: Jan 17, 2019

Share This Page