• 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!

Regeneration in PZ?

breadmaker

New Member
Joined
Jul 16, 2010
Messages
160
Reaction score
3
Hello there.
TFS 0.3.6pl1
I have a question - where in C++ I can change that - if player is in PZ he have regeneration health & mana from food??

@ BUMP
 
Last edited by a moderator:
You are supposed to wait atleast 24 hours before bumping a thread, please read the rules.

Have you tried opening the project in a compiler and searching all files for any of those keywords?

"pz" "regeneration" "protection"
 
Hello there.
TFS 0.3.6pl1
I have a question - where in C++ I can change that - if player is in PZ he have regeneration health & mana from food??

@ BUMP
Condition.cpp
Code:
bool ConditionRegeneration::executeCondition(Creature* creature, int32_t interval)
{
    internalHealthTicks += interval;
    internalManaTicks += interval;
    if(creature->getZone() != ZONE_PROTECTION)
    {
        if(internalHealthTicks >= healthTicks)
        {
            internalHealthTicks = 0;
            creature->changeHealth(healthGain);
        }

        if(internalManaTicks >= manaTicks)
        {
            internalManaTicks = 0;
            creature->changeMana(manaGain);
        }
    }

    return ConditionGeneric::executeCondition(creature, interval);
}
 
Back
Top