/buff command

09/15/2012 00:50 PvtPils#1
Hey all,

I've recently added this piece of code to my server:
Code:
ON_TEXTCMDFUNC( TextCmd_BuffPlayer,               "Buff",      "buff",                    "±Ó¼Ó¸»",         "±Ó",      TCM_SERVER, AUTH_GENERAL      , "±Ó¼Ó¸» [/¸í·É ¾ÆÀ̵𠳻¿ë]" )
Code:
BOOL TextCmd_BuffPlayer( CScanner& scanner )
{
#ifdef __WORLDSERVER
    CUser* pUser = (CUser*)scanner.dwValue;

    pUser->DoActiveSkill( 20, 20, pUser );
    pUser->DoActiveSkill( 49, 20, pUser );
    pUser->DoActiveSkill( 50, 20, pUser );
    pUser->DoActiveSkill( 52, 20, pUser );
    pUser->DoActiveSkill( 53, 20, pUser );
    pUser->DoActiveSkill( 114, 20, pUser );
    pUser->DoActiveSkill( 115, 20, pUser );
    pUser->DoActiveSkill( 116, 20, pUser );
#endif // __WORLDSERVER
    return TRUE;
}
Credits to Sedrika.

Anyways my problem is that these buffs skill time is calculated by their INT.

How can I make it like all buffs last 1h (no matter how many INT you have?)

Thanks in advance.
09/15/2012 02:23 420twisted1#2
theres another way to do it to change the time I messaged you
09/15/2012 11:48 Unleashed!#3
Quote:
Originally Posted by 420twisted1 View Post
theres another way to do it to change the time I messaged you
I think it would be nicer for everybody here, to just post it in this thread. ^^
09/16/2012 10:06 kaltaria#4
Credits to uKnow. He has progamm it for Final-Core.
09/16/2012 10:09 Sedrika#5
Quote:
Originally Posted by kaltaria View Post
Credits to uKnow. He has progamm it for Final-Core.
Credits gehen wohl eher an Offi für die Funktionen oder hat uKnow eine neue funktion hinzugefügt ?
09/16/2012 21:06 SteamSwag#6
Hey PvtPils,

I got the same code on my server and the buff time of these buffs doesnt get calculated by the INT of the user.
It just give me 1 hour (3600 sec) buffs like the Buff Pang, so it should be the same for you.



PS: dont forget to add a Anti-spam tick, otherwise people will spam the command an this can cause huge lags (client side) or even client crashes!