• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[C++] game.cpp remove the mana message that appears when dying

ronyashley

New Member
Joined
Feb 1, 2015
Messages
49
Reaction score
1
Location
Mexico City
hello otland guys
It happens that I want to delete 2 messages that appear to you when you die both in the game and in the Serverlog and it is about the mana
I leave some videos to explain myself better
Could someone tell me which line I should edit so that the message stops appearing
Beforehand thank you very much
Video Hide mana when dying

Game.cpp
 
Solution
friend, could you help me
I would greatly appreciate it
not the most elegant solution but should do the job:

in line 5312 add:
if((player = target->getPlayer()) && (attacker != target) && (target->getHealth() > 0))

and in line 5387:
if((player = target->getPlayer()) && (attacker != target) && (target->getHealth() > 0))

this way these messages should not appear when your health is 0
So it happens cause you downgraded one level and you lost 30 base mana points, you should check player.cpp instead,
also its hard to help you since you didn't posted tfs version and this cannot be reproduced in master tfs
I forgot to put the version, the version I am using is OTX Server 2.15 :: Version "SNAPSHOT"
Could you help me which line should I edit? to remove it
 
Would someone be so kind as to tell me where I should edit to prevent that message from appearing?
In the next video that I leave you, that message does not appear when the player dies
What I want to do is delete the message that says "you lose % mana" or the other message "you are regenerated with % mana"

this is what it should look like when you die
 
Last edited:
Would someone be so kind as to tell me where I should edit to prevent that message from appearing?
In the next video that I leave you, that message does not appear when the player dies
What I want to do is delete the message that says "you lose % mana" or the other message "you are regenerated with % mana"

this is what it should look like when you die
you want to delete those messages completly or only upon dying?
 
friend, could you help me
I would greatly appreciate it
not the most elegant solution but should do the job:

in line 5312 add:
if((player = target->getPlayer()) && (attacker != target) && (target->getHealth() > 0))

and in line 5387:
if((player = target->getPlayer()) && (attacker != target) && (target->getHealth() > 0))

this way these messages should not appear when your health is 0
 
Last edited:
Solution
not the most elegant solution but should do the job:

in line 5312 add:
if((player = target->getPlayer()) && (attacker != target) && (target->getHealth() > 0))

and in line 5387:
if((player = target->getPlayer()) && (attacker != target) && (target->getHealth() > 0))

this way these messages should not appear when your health is 0
Thanks very much buddy
yes it worked

the message no longer appears when they die
 
Back
Top