• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

Advanced Buff script

uDev

Illustrious Member
Hello, I'm releasing my first lua script which is buff command.
Buffs:
Mark Of The Wild
Prayer Of Shadow Protection
Prayer Of Fortitude
Prayer Of Spirit
Greater Blessing Of Kings
Arcane Intellect
Thorns

Power Buffs:
all same from Buffs +
Berserk

The command to do this is ~buff

With tokens:
http://pastebin.com/8R9QqvSJ

With money:
http://pastebin.com/U7TxrDvA

Example if user dont have on first script required item it will get normal buff if it has required item then it will get power buff

Same for second script only it requires money.

Credits to me for coding it.
Also tnx to mathias234 and ToxicDev for fixing my problem - http://emudevs.com/showthread.php/2007-Player-loose-golds

And tnx to Ghostcrawler336 for idea of his buff command :)
 
Last edited:

Tommy

Founder
About time someone decided to use a loop instead of spamming one method over and over again. Nice job. :p
 

gurch

Enthusiast
Hi Guys got a slight problem with mine, i added it and it works fine when i remove line -
Code:
        player:RemoveItem(TOKEN_ID) -- Remove this line if you don't want player to loose token.
When i have the line above in i type in #buff and it shows up in the chat and in worldserver it says
Code:
scripts\buff_tokens.lua:9: bad arguement #1 to 'RemoveItem' <number executed, got no value>
 

Foereaper

Founder
Hi Guys got a slight problem with mine, i added it and it works fine when i remove line -
Code:
        player:RemoveItem(TOKEN_ID) -- Remove this line if you don't want player to loose token.
When i have the line above in i type in #buff and it shows up in the chat and in worldserver it says
Code:
scripts\buff_tokens.lua:9: bad arguement #1 to 'RemoveItem' <number executed, got no value>

Have you defined a token ID at the top of the script?
 

gurch

Enthusiast
[MENTION=7]Foereaper[/MENTION] Yup sorry i forgot to add my pastebin link, does it matter if i use a custom token?
http://pastebin.com/FREmWC6S
[MENTION=552]µDev[/MENTION] i thought i had it all working fine just realiased i had deleted line 9 lol, but i do want it to remove the tokens from the user
 

Foereaper

Founder
change:

player:RemoveItem(TOKEN_ID)

to

player:RemoveItem(TOKEN_ID, 1)

The 1 is the amount of tokens being removed, udev forgot this in his script :)
 

uDev

Illustrious Member
It worked on levelup script forgot there was count sorry will update first post right away :/ Im really sorry xD
 

FusionLawL

Enthusiast
How can I make one of the 2 scripts buff VIP players?

Also the commands ~buff doesn;t seem to workd for me. wonder why
 
Last edited:
Top