01-22-2012, 08:57 AM
Pages: 1 2
01-24-2012, 07:02 AM
(01-22-2012 08:57 AM)mehipsta19 Wrote: [ -> ]Is there a script to use buffs scrolls(event) every 29 minutes before they expire?
same problem with me ! please help us
01-24-2012, 07:08 AM
01-24-2012, 07:46 AM
(01-24-2012 07:08 AM)satanou Wrote: [ -> ]http://forum.l2tower.eu/showthread.php?tid=2420
This will help
Just wanna ask if Sleep(1000*60*60); = 1 hour , what is the command for 29 minutes or 30 minutes only?im trying to follow the guide above but im really confuse and dont know the command for 29 minutes or 30 minutes only ,, sorry for bad english
01-24-2012, 08:25 AM
i dont know much about coding lua scripts but i guess the command for 30 mins will be (1000*30*30) test it
01-24-2012, 09:07 AM
(01-24-2012 08:25 AM)satanou Wrote: [ -> ]i dont know much about coding lua scripts but i guess the command for 30 mins will be (1000*30*30) test it
i thought its (1000*60*30) , anyway i will try it later when the magmeld server is up , sadly the server is down now ! i just hope (1000*30*30) or (1000*60*30) will work...anyway thanks bro
01-24-2012, 09:44 AM
Yes you might be right (1000*60*30) sounds more likely
GOGO server up! :PPP
GOGO server up! :PPP
01-24-2012, 11:25 AM
the scripts are counting mili-second
1000 mili-second = 1 second
so
30 min is 30*60 sec and is 30*60*1000 mili-sec, or 1800000 mili-sec
1000 mili-second = 1 second
so
30 min is 30*60 sec and is 30*60*1000 mili-sec, or 1800000 mili-sec
Code:
repeat
UseItem(ItemId);
Sleep(1800000);
until false;
01-24-2012, 13:44 PM
I was looking for the same thing but i made it BETTEr, it's with autodetect the buff scroll uses the right scroll, so no need for 29 minutes.
LUA Programming
repeat
if(GetMe():GetBuffsCount() < 4) then
ShowToClient("Buffs:","DOWN time to use scrol");
if (GetMe():GotBuff(9200) == false) then
UseItem(34006);
end;
if (GetMe():GotBuff(9203) == false) then
UseItem(34007);
end;
if (GetMe():GotBuff(9199) == false) then
UseItem(34008);
end;
if (GetMe():GotBuff(9199) == false) then
UseItem(34009);
end;
if (GetMe():GotBuff(9202) == false) then
UseItem(34010);
end;
if (GetMe():GotBuff(9199) == false) then
UseItem(34011);
end;
end;
until false;
(01-24-2012 13:44 PM)ursuhack2 Wrote: [ -> ]I was looking for the same thing but i made it BETTEr, it's with autodetect the buff scroll uses the right scroll, so no need for 29 minutes.The only bad thing is it spamm's the chat, and i dunno what to do.
LUA Programming
repeat if(GetMe():GetBuffsCount() < 4) then ShowToClient("Buffs:","DOWN time to use scrol"); if (GetMe():GotBuff(9200) == false) then UseItem(34006); end; if (GetMe():GotBuff(9203) == false) then UseItem(34007); end; if (GetMe():GotBuff(9199) == false) then UseItem(34008); end; if (GetMe():GotBuff(9199) == false) then UseItem(34009); end; if (GetMe():GotBuff(9202) == false) then UseItem(34010); end; if (GetMe():GotBuff(9199) == false) then UseItem(34011); end; end; until false;
01-24-2012, 13:51 PM
lol you included ShowToClient in repeat without any conditions so yeah it supposed to be spammed like hell.
add
Sleep(1000);
before until false; and everything should look great.
tho remember people wanted the other way(time based) because they dont want their chars look like bot that keep rebuffing everytime it loses buffs (if gm plays with ur buff bar)
add
Sleep(1000);
before until false; and everything should look great.
tho remember people wanted the other way(time based) because they dont want their chars look like bot that keep rebuffing everytime it loses buffs (if gm plays with ur buff bar)
Pages: 1 2