summaryrefslogtreecommitdiffstats
path: root/src/Entities
diff options
context:
space:
mode:
authorHowaner <franzi.moos@googlemail.com>2014-09-01 21:05:45 +0200
committerHowaner <franzi.moos@googlemail.com>2014-09-01 21:05:45 +0200
commitdfed6f94ca78f2e104ed316d83400b0ca74cb79a (patch)
treed00547328b70bbb4a4ea5d713f6ffe8e3a48ee12 /src/Entities
parentAdded CustomName to cMonster. (diff)
downloadcuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.tar
cuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.tar.gz
cuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.tar.bz2
cuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.tar.lz
cuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.tar.xz
cuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.tar.zst
cuberite-dfed6f94ca78f2e104ed316d83400b0ca74cb79a.zip
Diffstat (limited to 'src/Entities')
-rw-r--r--src/Entities/Boat.cpp2
-rw-r--r--src/Entities/Entity.h2
-rw-r--r--src/Entities/ItemFrame.cpp2
-rw-r--r--src/Entities/Minecart.cpp5
4 files changed, 8 insertions, 3 deletions
diff --git a/src/Entities/Boat.cpp b/src/Entities/Boat.cpp
index 8ff8866a1..328a70846 100644
--- a/src/Entities/Boat.cpp
+++ b/src/Entities/Boat.cpp
@@ -62,6 +62,8 @@ bool cBoat::DoTakeDamage(TakeDamageInfo & TDI)
void cBoat::OnRightClicked(cPlayer & a_Player)
{
+ super::OnRightClicked(a_Player);
+
if (m_Attachee != NULL)
{
if (m_Attachee->GetUniqueID() == a_Player.GetUniqueID())
diff --git a/src/Entities/Entity.h b/src/Entities/Entity.h
index b9c280b6b..774cdb062 100644
--- a/src/Entities/Entity.h
+++ b/src/Entities/Entity.h
@@ -447,7 +447,7 @@ public:
// tolua_end
/// Called when the specified player right-clicks this entity
- virtual void OnRightClicked(cPlayer &) {}
+ virtual void OnRightClicked(cPlayer & a_Player) {}
/// Returns the list of drops for this pawn when it is killed. May check a_Killer for special handling (sword of looting etc.). Called from KilledBy().
virtual void GetDrops(cItems & a_Drops, cEntity * a_Killer = NULL)
diff --git a/src/Entities/ItemFrame.cpp b/src/Entities/ItemFrame.cpp
index 0bc10ec60..3ccb95998 100644
--- a/src/Entities/ItemFrame.cpp
+++ b/src/Entities/ItemFrame.cpp
@@ -22,6 +22,8 @@ cItemFrame::cItemFrame(eBlockFace a_BlockFace, double a_X, double a_Y, double a_
void cItemFrame::OnRightClicked(cPlayer & a_Player)
{
+ super::OnRightClicked(a_Player);
+
if (!m_Item.IsEmpty())
{
// Item not empty, rotate, clipping values to zero to three inclusive
diff --git a/src/Entities/Minecart.cpp b/src/Entities/Minecart.cpp
index 1501eea84..5fabbb542 100644
--- a/src/Entities/Minecart.cpp
+++ b/src/Entities/Minecart.cpp
@@ -1072,6 +1072,8 @@ cRideableMinecart::cRideableMinecart(double a_X, double a_Y, double a_Z, const c
void cRideableMinecart::OnRightClicked(cPlayer & a_Player)
{
+ super::OnRightClicked(a_Player);
+
if (m_Attachee != NULL)
{
if (m_Attachee->GetUniqueID() == a_Player.GetUniqueID())
@@ -1124,8 +1126,7 @@ void cMinecartWithChest::SetSlot(size_t a_Idx, const cItem & a_Item)
void cMinecartWithChest::OnRightClicked(cPlayer & a_Player)
{
- // Show the chest UI window to the player
- // TODO
+ // TODO: Show the chest UI window to the player
}