From 3f4abe8c95e4d37a84018ca4d478a908fca423ac Mon Sep 17 00:00:00 2001 From: madmaxoft Date: Thu, 8 Aug 2013 09:13:13 +0200 Subject: Addeed OnSpawningEntity, OnSpawnedEntity, OnSpawningMonster, OnSpawnedMonster hooks. As requested in FS 418. --- source/Player.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'source/Player.cpp') diff --git a/source/Player.cpp b/source/Player.cpp index bbf39f789..ae119a1fb 100644 --- a/source/Player.cpp +++ b/source/Player.cpp @@ -121,10 +121,14 @@ cPlayer::~cPlayer(void) -void cPlayer::Initialize(cWorld * a_World) +bool cPlayer::Initialize(cWorld * a_World) { - super::Initialize(a_World); - GetWorld()->AddPlayer(this); + if (super::Initialize(a_World)) + { + GetWorld()->AddPlayer(this); + return true; + } + return false; } -- cgit v1.2.3