EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Quests::Q&A (https://www.eqemulator.org/forums/forumdisplay.php?f=599)
-   -   Check for buff? (https://www.eqemulator.org/forums/showthread.php?t=37896)

kimura 02-25-2014 02:19 PM

Check for buff?
 
cant seem to find an if check for a certain buff. is there a variable or function to check if a client has a specific buff?

thanks

Kimura

Township EQ 02-25-2014 02:37 PM

try this.. no clue if it works or not just got it from the wiki.. put this on a random npc and change the spell id.

Code:

sub EVENT_SAY {
        if($text=~/hail/i) {
                if($client->FindBuff(123456) {
                        $client->Message(15, "You have dat buff on you dawwwwwg");
                }
        }
}


kimura 02-25-2014 02:55 PM

thanks, I actually already had that one in the script...just used it wrong lol

Kingly_Krab 02-25-2014 03:00 PM

FROM:
Code:

if($client->FindBuff(123456)
TO:
Code:

if($client->FindBuff(123456))
You're missing a parenthesis, that script would not run.

ghanja 02-25-2014 06:48 PM

Quote:

Originally Posted by Kingly_Krab (Post 228522)
FROM:
Code:

if($client->FindBuff(123456)
TO:
Code:

if($client->FindBuff(123456))

http://www.godlikeproductions.com/sm/cmicsfee.gif

Township EQ 02-26-2014 09:53 AM

Quote:

Originally Posted by Kingly_Krab (Post 228522)
FROM:
Code:

if($client->FindBuff(123456)
TO:
Code:

if($client->FindBuff(123456))
You're missing a parenthesis, that script would not run.

i'm sure he would've figured that out when he changed the spell id.. i was rushed because i had work an stuffs.. wrote it in 2 seconds.


All times are GMT -4. The time now is 01:26 AM.

Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.