diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-05-19 20:22:37 +0200 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-05-19 20:22:37 +0200 |
commit | 90c398a3926f097e51955817e2829d831ae2bd2b (patch) | |
tree | af4e2d236a5e0595f19975dcd2295c60c4a59712 /source/Item.cpp | |
parent | Debuggers: sorted things into separate functions, commented out most of them; added ForEachEntity() testing - list all and kill all entities. (diff) | |
download | cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.tar cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.tar.gz cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.tar.bz2 cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.tar.lz cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.tar.xz cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.tar.zst cuberite-90c398a3926f097e51955817e2829d831ae2bd2b.zip |
Diffstat (limited to '')
-rw-r--r-- | source/Item.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/Item.cpp b/source/Item.cpp index 60bd7da95..a2e4a9f24 100644 --- a/source/Item.cpp +++ b/source/Item.cpp @@ -58,7 +58,7 @@ short cItem::GetMaxDamage(void) const -bool cItem::DamageItem(void) +bool cItem::DamageItem(short a_Amount) { short MaxDamage = GetMaxDamage(); if (MaxDamage == 0) @@ -67,7 +67,7 @@ bool cItem::DamageItem(void) return false; } - m_ItemDamage++; + m_ItemDamage += a_Amount; return (m_ItemDamage >= MaxDamage); } |