Exeus
Advanced OT User
- Joined
- Oct 8, 2012
- Messages
- 859
- Reaction score
- 198
Hi!
I'm using TFS 1.2 and I'm kind of changing TFS' death but I found some part that I struggle to understand
Here's the code:
also playerdeath.lua which prints
Now I'm struggling to understand one thing
I'm killing character A and everything so far prints fine
but now nothing happens until I logout from character
so, after logout message appears:
but why? what's blocking it?
thanks in advance!
I'm using TFS 1.2 and I'm kind of changing TFS' death but I found some part that I struggle to understand
Here's the code:
forgottenserver/src/creature.cpp at master · otland/forgottenserver
A free and open-source MMORPG server emulator written in C++ - otland/forgottenserver
github.com
Code:
for (CreatureEvent* deathEvent : getCreatureEvents(CREATURE_EVENT_DEATH)) {
printf("started executin onDeath script \n");
deathEvent->executeOnDeath(this, corpse, lastHitCreature, mostDamageCreature, lastHitUnjustified, mostDamageUnjustified);
printf("ended executin onDeath script \n");
}
also playerdeath.lua which prints
exiting playerdeath.lua
Code:
function onDeath(player, corpse, killer, mostDamageKiller, unjustified, mostDamageUnjustified)
(...)
print("exiting playerdeath.lua");
return false;
end
Now I'm struggling to understand one thing
I'm killing character A and everything so far prints fine
started executin onDeath script
exiting playerdeath.lua
but now nothing happens until I logout from character
so, after logout message appears:
ended executin onDeath script
but why? what's blocking it?
thanks in advance!