summaryrefslogtreecommitdiff
path: root/src/game-server/character.cpp
diff options
context:
space:
mode:
authorErik Schilling <ablu.erikschilling@googlemail.com>2012-07-08 17:20:34 +0200
committerErik Schilling <ablu.erikschilling@googlemail.com>2012-07-08 17:54:57 +0200
commit4d88724f011090de417284668d2264931f1bfcc3 (patch)
tree94e2783c3f588e43663d7307730bc21dc46a64c9 /src/game-server/character.cpp
parent6da6afe8ad3ffc3d690af9b60975c5f183f2aba8 (diff)
downloadmanaserv-4d88724f011090de417284668d2264931f1bfcc3.tar.gz
manaserv-4d88724f011090de417284668d2264931f1bfcc3.tar.bz2
manaserv-4d88724f011090de417284668d2264931f1bfcc3.tar.xz
manaserv-4d88724f011090de417284668d2264931f1bfcc3.zip
Added bind for setting login callback
Reviewed-by: bjorn.
Diffstat (limited to 'src/game-server/character.cpp')
-rw-r--r--src/game-server/character.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/game-server/character.cpp b/src/game-server/character.cpp
index 4816f3c1..71427342 100644
--- a/src/game-server/character.cpp
+++ b/src/game-server/character.cpp
@@ -55,6 +55,7 @@ const float Character::EXP_LEVEL_FLEXIBILITY = 1.0f;
Script::Ref Character::mDeathCallback;
Script::Ref Character::mDeathAcceptedCallback;
+Script::Ref Character::mLoginCallback;
static bool executeCallback(Script::Ref function, Character *character)
{
@@ -830,3 +831,8 @@ void Character::clearSpecials()
{
mSpecials.clear();
}
+
+void Character::triggerLoginCallback()
+{
+ executeCallback(mLoginCallback, this);
+}