//======Name======================================== // Dice Event //======Version===================================== // 1.0 //======Author(s)=================================== // Sandbox //======Comments==================================== // In loving memory of AstralRO //================================================== - script AutoEventTrigger -1,{ OnWhisperGlobal: if (getgmlevel() >= 90) { donpcevent "DiceTrigger::OnDiceETrigger"; end; } OnClock2030: OnClock2330: OnClock1730: OnClock1430: OnClock1130: donpcevent "DiceTrigger::OnDiceETrigger"; end; } - script DiceTrigger -1,{ OnInit: disablenpc "Dice Event Warper#dice"; disablenpc "Claim Your Prize!#dice"; end; OnJoinDice: warp "quiz_02",55,87; end; OnDiceETrigger: if(agitcheck() == 1) end; bindatcmd "joindice",strnpcinfo(3)+"::OnJoinDice",0,99; announce "Dice Event: We are going to have a Dice Event",bc_all,0xFF7F50; sleep2 3000; announce "Dice Event: For those who want to join, please use @joindice!",bc_all,0xFF7F50; sleep2 3000; announce "Dice Event: You have 2 Minutes to join!",bc_all,0xFF7F50; sleep2 60000; announce "Dice Event: Last 60 Seconds! use @joindice now!",bc_all,0xFF7F50; sleep2 60000; announce "Dice Event: Portal Closed!",bc_all,0xFF7F50; unbindatcmd "joindice"; donpcevent "DiceEvent::OnDiceStart"; end; } quiz_02,55,90,3 script Got Stuck?#dice 779,{ mes "[ Got Stuck? ]"; mes "Do you wish to go back?"; menu "Yes",-; warp "prontera",156,153; close; } quiz_02,37,80,3 script Box 1 111,{ warp "quiz_02",37,70; close; } quiz_02,49,80,3 script Box 2 111,{ warp "quiz_02",49,70; close; } quiz_02,61,80,3 script Box 3 111,{ warp "quiz_02",61,70; close; } quiz_02,73,80,3 script Box 4 111,{ warp "quiz_02",73,70; close; } quiz_02,37,64,3 script Go Back#1 858,{ warp "quiz_02",55,76; close; } quiz_02,49,64,3 script Go Back#2 858,{ warp "quiz_02",55,76; close; } quiz_02,61,64,3 script Go Back#3 858,{ warp "quiz_02",55,76; close; } quiz_02,73,64,3 script Go Back#4 858,{ warp "quiz_02",55,76; close; } - script DiceEvent -1,{ OnDiceStart: mapannounce "quiz_02","We are about to start the Dice event.",bc_blue; sleep2 1000; mapannounce "quiz_02","Rules are simple:",bc_blue; sleep2 1000; mapannounce "quiz_02","I'm going to pick a number, 1 to 4. Then I'll do a countdown from 5 to 0",bc_blue; sleep2 1000; mapannounce "quiz_02","All you have to do is go to box of the number you want",bc_blue; sleep2 1000; mapannounce "quiz_02","Example, If I get the number 4, All players standing on number 1 to 3 loses.",bc_blue; sleep2 1000; mapannounce "quiz_02","We'll do it again and again until we have 1 player left on this map.",bc_blue; sleep2 2000; mapannounce "quiz_02","Before I forget, you must GO INSIDE THE BOX! because if you're caught standing outside the box you'll be automatically disqualified!",bc_blue; sleep2 2000; mapannounce "quiz_02","That's it.. Now let's get it on!",bc_blue; sleep2 3000; goto L_start; end; L_start: enablenpc "Go Back#1"; enablenpc "Go Back#2"; enablenpc "Go Back#3"; enablenpc "Go Back#4"; if(getmapusers("quiz_02") == 1) goto L_winner; enablenpc "Box 1"; enablenpc "Box 2"; enablenpc "Box 3"; enablenpc "Box 4"; if(getmapusers("quiz_02") == 0) goto L_noone; if(getmapusers("quiz_02") > 1) { set $@number,rand(1,4); sleep2 1000; mapannounce "quiz_02","I'm ready to pick a number. Please go to the box of the number you want! Go go go!",bc_blue; sleep2 20000; mapannounce "quiz_02","5",bc_blue; sleep2 1500; mapannounce "quiz_02","4",bc_blue; sleep2 1500; mapannounce "quiz_02","3",bc_blue; sleep2 1500; mapannounce "quiz_02","2",bc_blue; sleep2 1500; mapannounce "quiz_02","1",bc_blue; disablenpc "Box 1"; disablenpc "Box 2"; disablenpc "Box 3"; disablenpc "Box 4"; disablenpc "Go Back#1"; disablenpc "Go Back#2"; disablenpc "Go Back#3"; disablenpc "Go Back#4"; areawarp "quiz_02",32,95,79,76,"prontera",156,153; areawarp "quiz_02",80,85,80,76,"prontera",156,153; areawarp "quiz_02",31,85,31,76,"prontera",156,153; if(getmapusers("quiz_02") == 0) goto L_noone; sleep2 1000; mapannounce "quiz_02","Time's Up. Winning number is "+$@number+"!",bc_blue; if($@number == 4) goto L_Lose1; if($@number == 3) goto L_Lose2; if($@number == 2) goto L_Lose3; if($@number == 1) goto L_Lose4; end; } L_Lose1: //Edit to where will you warp players that lost areawarp "quiz_02",33,73,41,52,"prontera",156,153; areawarp "quiz_02",45,73,53,52,"prontera",156,153; areawarp "quiz_02",57,73,65,52,"prontera",156,153; goto L_start; end; L_Lose2: //Edit to where will you warp players that lost areawarp "quiz_02",33,73,41,52,"prontera",156,153; areawarp "quiz_02",45,73,53,52,"prontera",156,153; areawarp "quiz_02",69,73,77,52,"prontera",156,153; goto L_start; end; L_Lose3: //Edit to where will you warp players that lost areawarp "quiz_02",33,73,41,52,"prontera",156,153; areawarp "quiz_02",57,73,65,52,"prontera",156,153; areawarp "quiz_02",69,73,77,52,"prontera",156,153; goto L_start; end; L_Lose4: //Edit to where will you warp players that lost areawarp "quiz_02",45,73,53,52,"prontera",156,153; areawarp "quiz_02",57,73,65,52,"prontera",156,153; areawarp "quiz_02",69,73,77,52,"prontera",156,153; goto L_start; end; L_noone: announce "No one won the Dice Event!",bc_all,0xFF7F50; disablenpc "Claim Your Prize!#dice"; disablenpc "Dice Event Warper#dice"; end; L_winner: enablenpc "Claim Your Prize!#dice"; disablenpc "Dice Event Warper#dice"; end; } quiz_02,55,84,3 script Claim Your Prize!#dice 904,{ getitem 7227,1; //Edit on what prize would you give to the winner set #RPSPOINTS,#RPSPOINTS+5; dispbottom "You received 5 RPS Point."; dispbottom "Your total RPS Points is: "+#RPSPOINTS+" RPS Points"; announce strcharinfo(0)+" won the Dice Event!",bc_all,0xFF7F50; disablenpc "Claim Your Prize!#dice"; disablenpc "Dice Event Warper#dice"; warp "prontera",156,153; close; end; } quiz_02 mapflag nowarp quiz_02 mapflag nowarpto quiz_02 mapflag noteleport quiz_02 mapflag nomemo quiz_02 mapflag nosave SavePoint quiz_02 mapflag noicewall quiz_02 mapflag noloot