Hi Pan, just want to ask if the reward will go directly to players inventory? or I still need to create NPC to call the script you made.Has been awhile since I wrote my last script but here it is:
http://pastebin.com/DimazGWd
Haven't tested it though, if any error pops up, just post here and I'll fix it.
Thank you again! I'll test it later and give you feedback..Here it is: http://pastebin.com/3RmAGytY
Just change .time_lapse[0], it works exactly the same as before.
setarray .time_lapse[0],FIRST ID TIME LAPSE,SECOND ID TIME LAPSE,0;If you have four prizes but only one time_lapse set there's no problem, the time lapse for all prizes will be the same. As usual I haven't tested, any errors just post c:
EDIT:
Don't forget that every time a time_lapse is met the time is set to zero.
setarray .time_lapse[0],60*60*2,60*60*3,0;A player will only win the second prize (.item_reward[1]) if he stays logged for 5 hours.
You are absolutely right c:If I'm not mistaken:
1 minute = 1, and so on for the rest of minutes.
For 1 minute for first prize and 3 for the second:Sir thank you its working now.. I'll let you know if I find anything unusual.
Sir One more thing. Can you please create one timelapse
for 1 minute and 3 minutes (for testing purposes only i dont want to w8 an hour or 2 just for testing it)? Im so confused on how to set the time lapse for 1 and 3 minutes.
setarray .time_lapse[0],60*60*2,60*60*3,0;
setarray .time_lapse, 1, 2, 0;
.time_lapse[0]+.time_lapse[1] = REAL time lapse [1]
got it! Thank you so much!You are absolutely right c:If I'm not mistaken:
1 minute = 1, and so on for the rest of minutes.For 1 minute for first prize and 3 for the second:setarray .time_lapse, 1, 2, 0;Remember that after the first time_lapse condition is met the timer resets. So even if the second lapse (.time_lapse[1]) looks like just 2 minutes it's actually 3.>Sir thank you its working now.. I'll let you know if I find anything unusual.
Sir One more thing. Can you please create one timelapse
for 1 minute and 3 minutes (for testing purposes only i dont want to w8 an hour or 2 just for testing it)? Im so confused on how to set the time lapse for 1 and 3 minutes.
setarray .time_lapse[0],60*60*2,60*60*3,0;Code:.time_lapse[0]+.time_lapse[1] = REAL time lapse [1]
*checkvending({"<Player Name>"})
*checkchatting({"<Player Name>"})
Checks if the player is vending or in a chatroom.
Name is optional, and defaults to the attached player if omitted.
Return values for 'checkvending' are
0 = not vending
1 = normal vending
2 = vending using @autotrade
'checkchatting' returns 1 if they are in a chat room, 0 if they are not.
Examples:
//This will check if Aaron is vending, and if so, put a message in
//front of the attached player saying Aaron is vending.
if (checkvending("Aaron"))
mes "Aaron is currently vending!";
//This will check if the attached player in a chat room or not.
if (checkchatting())
mes "You are currently in a chat room!";
---------------------------------------
*checkidle({"<Player Name>"})
Returns the time, in seconds, that the specified player has been idle.
Name is optional, and defaults to the attached player if omitted.
Thank you, I wasn't aware of that.try not to use attachnpctimer unnecessary
attachnpctimer I only use them in 1 scenario
which use in botkiller script to kick players which doesn't answer in a certain time period
means, only use in a npc dialog script
because if this script already uses attachnpctimer,
if there is other script use attachnpctimer again, the timer wouldn't run anymore
for this kind of script, I rather use sleep2
http://rathena.org/board/topic/90989-hourly-points-help/?p=238289
I added new configurations:// Account idle players? 1 - true; 0 - falseset .idle,1;// Account players using autotrade? 1 - true; 0 - falseset .autotrade,1;// Account players that are in chats? 1 - true; 0 - falseset .chat, 1;Set to false if you want that those players don't receive any prize.http://pastebin.com/aJV6beP8Well how can I make the reward goes to online players only, excluding @at. Since they may spam merchants and @at to get rewards.
And can I make reward totally unable to change the owner including dropping, trading and vending.
We use essential cookies to make this site work, and optional cookies to enhance your experience.