summaryrefslogtreecommitdiffstats
path: root/src/Entities/EntityEffect.h
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-07-26 16:47:11 +0200
committerMattes D <github@xoft.cz>2014-07-26 16:47:11 +0200
commit56f417494390ade84dd64167b1d62d28068b790c (patch)
tree7db4a59db1874bf9250e8c2c9bf3271e5a5ae67c /src/Entities/EntityEffect.h
parentMerge pull request #1207 from Howaner/Inventory (diff)
parentSplashPotionEntity: Use `const cItem &` instead of a cItem (diff)
downloadcuberite-56f417494390ade84dd64167b1d62d28068b790c.tar
cuberite-56f417494390ade84dd64167b1d62d28068b790c.tar.gz
cuberite-56f417494390ade84dd64167b1d62d28068b790c.tar.bz2
cuberite-56f417494390ade84dd64167b1d62d28068b790c.tar.lz
cuberite-56f417494390ade84dd64167b1d62d28068b790c.tar.xz
cuberite-56f417494390ade84dd64167b1d62d28068b790c.tar.zst
cuberite-56f417494390ade84dd64167b1d62d28068b790c.zip
Diffstat (limited to 'src/Entities/EntityEffect.h')
-rw-r--r--src/Entities/EntityEffect.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/Entities/EntityEffect.h b/src/Entities/EntityEffect.h
index 396a9bbe0..f9c1e4eb2 100644
--- a/src/Entities/EntityEffect.h
+++ b/src/Entities/EntityEffect.h
@@ -36,6 +36,24 @@ public:
effSaturation = 23,
} ;
+ /** Returns the potion color (used by the client for visuals), based on the potion's damage value */
+ static int GetPotionColor(short a_ItemDamage);
+
+
+ /** Translates the potion's damage value into the entity effect that the potion gives */
+ static cEntityEffect::eType GetPotionEffectType(short a_ItemDamage);
+
+
+ /** Retrieves the intensity level from the potion's damage value. Returns 0 for level I potions, 1 for level II potions. */
+ static short GetPotionEffectIntensity(short a_ItemDamage);
+
+
+ /** Returns the effect duration, in ticks, based on the potion's damage value */
+ static int GetPotionEffectDuration(short a_ItemDamage);
+
+ /** Returns true if the potion with the given damage is drinkable */
+ static bool IsPotionDrinkable(short a_ItemDamage);
+
// tolua_end
/** Creates an empty entity effect */