prontera,100,100,5 script Poring Event 909,{
if ($win == 1) {mes "sorry, but one player already won."; close;}
set @rnd,rand(1,100000); // 1,100000 = 1-100000 you can edit the chance to win or lose
set .@itemid,602; // Set item id here
set .@itema,1; // Set item amount here
//Win option
if (@rnd == 1) {goto win;}
//Lose option
if (@rnd < 2) {goto lose;}
win:
set $win,1; // prevents that more than one player can win at a time
mes "wow...";
mes "You've won!";
next;
mes "Here is your Reward";
getitem .@itemid,.@itema;
disablenpc "Poring Event";
close;
lose:
warp "prontera",103,103;
end;
OnHour16:
enablenpc "poring#event1";
set $win,0;
end;
}