Solved Tool / weapon durability

Discussion in 'Plugin Requests' started by jf3000, Jan 2, 2015.

  1. Is there such a plugin for this yet?
     
  2. would be great if we could get a plugin so admins could get control over turning durability off or on
     
  3. It would be nice to have the option for tools breaking or not
     
  4. edit: Posts got consolidated
     
    Last edited by a moderator: Feb 12, 2015
  5. great, thanks.
     
  6. A plugin to adjust or turn on and off Durability for weapons and tools would be awesome.
     
  7. Been requested twice now lol. Guys, use the search!
     
  8. Wulf

    Wulf Community Admin

    Merged duplicate requests.
     
  9. CHR

    CHR

    So for now there is no plugin like that or am i wrong?
     
  10. there is no plugin
     
  11. yes there is
    ItemConfig
    you can edit maxConditions (i think that's the name)
    for each tools.

    you can't turn it off with it but at least you can set 1000000.0 condition making it basically invul
     
  12. A nasty workaround would be to check the condition and repair it for maxcondition - currentcondition to get it back to full on every player attack :p
     
  13. More code ^^ and lag
    ^^
    when it's currently possible to pût infinite condition :p
     
  14. Should be possible actually by setting the maxCondition to 0 in the item definition.

    Code:
        public bool hasCondition
        {
            get
            {
                if (this.isBlueprint)
                {
                    return false;
                }
                return ((this.info != null) && (this.info.maxCondition > 0f));
            }
        }
    [DOUBLEPOST=1423812239][/DOUBLEPOST]
    And I did say it was a nasty workaround :p
     
  15. Yep 0f seems fine :)
     
  16. Set the maxConditions to 0 make it unuseable !
     
  17. how about -1
     
  18. to step it up a notch to select which items could have durability and which would not would be nice.
     
  19. ItemConfig can do this
     
  20. I did it this way and it works.