/* Easter Egg Hunt Script Version 1.0 Created by: Aeromesi Built for: Hercules/rAthena on the day before Easter! Happy Easter Hercules ^^ - with @commands for ease-of-use! - '@repeategghunt' - Allow you to repeat the previous Easter Egg Hunt setup you made! - '@egghunt' - Able to start off by creating Easter Egg Hunt settings. Able to disable or delete the setup to start configuring new Easter Egg Hunt event. (Note: It will be able to tell if created or event is active.) - '@joinegghunt' - Allow player to warp to the the map the event is happening on (Basic version only support Prontera)*/prontera,147,162,4 script Easter Egg Hunt 4_GEFFEN_03,{mes .Tname$;if($@Easter_Active){mes"Information";mes"Map event is active: ^FF0000"+$EHuntMap$+"^000000";mes"Easter Egg Hunt info:";mes"^CCCCCCSilver^000000 Egg Reward: "+getitemname($SItem_ID)+" x "+$SReward_AM+" ";mes"^ffd700Gold^000000 Egg Reward: "+getitemname($GItem_ID)+" x "+$GReward_AM+"";}elsemes"No ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt in-progress";close;OnInit: .Tname$ ="[^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt]"; $EHuntMap$ ="prontera"; // DO NOT CHANGE THIS - Basic Version will only work on Prontera. $EggHuntTotal =150; // DO NOT CHANGE THIS - Basic Version will only allow a total of 150, because the Normal Egg+Silver Egg+Gold Egg is equal to 150. (Can change this for you upon request via PM or on Skype. $EggHuntTotal2 =150; // DO NOT CHANGE THIS - Is simply just the variable that gets counted down.end;}- script EasterEggHunt#Sys FAKE_NPC,{OnInit: .easter_name$ ="[^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt]";bindatcmd"egghunt",strnpcinfo(0)+"::OnAtEasterEggHunt";bindatcmd"repeategghunt",strnpcinfo(0)+"::OnAtRepeatEasterEggHunt";bindatcmd"joinegghunt",strnpcinfo(0)+"::OnAtJoinEasterEggHunt";end;OnAtJoinEasterEggHunt:if(!$@Easter_Active){dispbottom"No Easter Egg Hunt Event In-Progress.";}else{warp $EHuntMap$, 0 ,0;dispbottom"Successfully joined Easter Egg Hunt Event.";}end;OnAtRepeatEasterEggHunt:if(getgmlevel() >=99){if($@Easter_Active){dispbottom"Easter Egg Hunt Event is currently active.";}else{if($ELast_Setup){ $@Easter_Active++;donpcevent"EasterEggHunt#Sys::OnCounterReset";announce"Easter Egg Hunt Event has been restarted by GM "+strcharinfo(0)+"!",bc_all;sleep22500;donpcevent"EasterEggHunt#Sys::OnStartEvent";}else{dispbottom"You haven't setup a Easter Egg Hunt Event before.";}}}end;OnAtEasterEggHunt:if(getgmlevel() >=99){mes .easter_name$;if($ELast_Setup >=1){mes"Delete last Setup or Disable Event?";switch(select("Delete last Setup", "Disable Easter Egg Hunt", "Exit")){case1:if($@Easter_Active){mes"Currently the ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt is active. Disable or finish the event to delete your setup.";close;}else $ELast_Setup =0;mes"Previous setup deleted. Proceed using '^ff0000@egghunt^000000' to create a new ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt Event.";close;case2:if($@Easter_Active){mes"Would you like to Disable/Prematurely end ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt for whatever reason?";next;switch(select("Yes please.", "No thanks!")){case1:mes"Now Disabling Easter ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Event.";sleep24000; $@Easter_Active =0;for(.@i =1; .@i <=50; .@i++){disablenpc"Golden Egg#"+ .@i;disablenpc"Silver Egg#"+ .@i;disablenpc"Normal Egg#"+ .@i;}sleep21000;announce"Easter Egg Hunt has been disabled by GM "+strcharinfo(0)+".",bc_map;close;case2:mes .easter_name$;mes"Alrighty then!";close;}}elsemes"^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt is currently not active.";close;case3:close;}}elsemes"Create ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt?";next;switch(select("[Event] ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt", "Exit")){case2:close;case1:if($@Easter_Active){mes .easter_name$;mes"Currently there is a ^8B3626^CCCCCCEaster^000000 ^ffd700Egg^000000 Hunt in session. Please wait until it is over or Disable in the GM options to end the Easter Egg Hunt Event prematurely.";close;}mes .easter_name$;mes"Now input the item ID for the ^CCCCCCSilver^000000 Easter Eggs."; .@check =0;do{input $SItem_ID;if($SItem_ID ==0 || getitemname($SItem_ID)=="null"){dispbottom"Sorry, but it's impossible to enter 0/Invalid ItemID.";dispbottom"Please reinput the total amount of Rewards you'd like players to get catching each Silver Egg.";}else .@check =1;}while(.@check ==0);next;mes .easter_name$;mes"Now input the item ID for the ^ffd700Gold^000000 Easter Eggs."; input $GItem_ID; .@check =0;do{input $GItem_ID;if($GItem_ID ==0 || getitemname($GItem_ID)=="null"){dispbottom"Sorry, but it's impossible to enter 0/Invalid ItemID.";dispbottom"Please reinput the total amount of Rewards you'd like players to get catching each Gold Egg.";}else .@check =1;}while(.@check ==0);next;mes .easter_name$;mes"Now input amount of Reward you would like player to receive from catching ^CCCCCCSilver^000000 Easter Egg:";do{input $SReward_AM;if($SReward_AM ==0){dispbottom"Sorry, but it's impossible to enter 0 for Rewards.";dispbottom"Please reinput the total amount of Rewards for players who catch Silver Eggs.";}}while($SReward_AM > 0);next;mes .easter_name$;mes"Now input amount of Reward you would like player to recieve from catching ^ffd700Gold^000000 Easter Egg:";do{input $GReward_AM;if($GReward_AM ==0){dispbottom"Sorry, but it's impossible to enter 0 for Rewards.";dispbottom"Please reinput the total amount of Rewards for players who catch Gold Eggs.";}}while($GReward_AM > 0);next;mes .easter_name$;mes"Now activating Easter Egg Hunt Event."; $ELast_Setup++; $@Easter_Active++;// $@EggHuntCount = 0;// $EggHuntTotal2 = 150;donpcevent"EasterEggHunt#Sys::OnStartEvent";close;}}end;OnStartEvent:for(.@i =1; .@i <=50; .@i++){donpcevent"Golden Egg#"+ .@i +"::OnEnableGoldEgg";donpcevent"Silver Egg#"+ .@i +"::OnEnableSilverEgg";donpcevent"Normal Egg#"+ .@i +"::OnEnableNormalEgg";}end;OnCounterReset: $@EggHuntCount =0; // DO NOT TOUCH $EggHuntTotal2 =150; // DO NOT TOUCHend;OnEggEndCheck:if($@EggHuntCount >= $EggHuntTotal){ $@Easter_Active =0;announce"[Easter Egg Hunt] The Egg Hunt is now over! Hope everyone had fun!",bc_all;donpcevent"EasterEggHunt#Sys::OnCounterReset";donpcevent"EasterEggHunt#Sys::OnDisableEggs";}end;OnDisableEggs:for(.@i =1; .@i <=50; .@i++){disablenpc"Golden Egg#"+ .@i;disablenpc"Silver Egg#"+ .@i;disablenpc"Normal Egg#"+ .@i;}end;}prontera,150,151,4 script Normal Egg#14_DRAGON_EGG,{ $@EggHuntCount++;dispbottom"That's just a Normal egg! Try to catch the Silver and Gold Eggs!";announce"[Easter Egg Hunt] Total of ("+$@EggHuntCount+"/"+$EggHuntTotal2+") have been captured! Better find the Eggs before it's too late!",bc_all;disablenpcstrnpcinfo(0);donpcevent("EasterEggHunt#Sys")+"::OnEggEndCheck";end;OnInit:disablenpcstrnpcinfo(0);end;OnEnableNormalEgg:enablenpcstrnpcinfo(0);donpceventstrnpcinfo(0)+"::OnEggMove";end;OnEggMove:npcspeed70;while(true){getmapxy .@map$, .@x, .@y, 1;while(checkcell( .@map$, .@x2 = .@x +rand(-10,10), .@y2 = .@y +rand(-10,10), cell_chknopass));npcwalkto .@x2, .@y2;sleeprand(100,200);}end;}prontera,150,151,4 script Silver Egg#14_DRAGON_EGG,{ $@EggHuntCount++;dispbottom"You just captured a Silver Egg! Lucky you!";announce"[Easter Egg Hunt] Total of ("+$@EggHuntCount+"/"+$EggHuntTotal2+") have been captured! Better find the Eggs before it's too late!",bc_all;getitem $SItem_ID, $SReward_AM;disablenpcstrnpcinfo(0);donpcevent("EasterEggHunt#Sys")+"::OnEggEndCheck";end;OnInit:disablenpcstrnpcinfo(0);end;OnEnableSilverEgg:enablenpcstrnpcinfo(0);donpceventstrnpcinfo(0)+"::OnEggMove";end;OnEggMove:npcspeed70;while(true){getmapxy .@map$, .@x, .@y, 1;while(checkcell( .@map$, .@x2 = .@x +rand(-10,10), .@y2 = .@y +rand(-10,10), cell_chknopass));npcwalkto .@x2, .@y2;sleeprand(100,200);}end;}prontera,150,151,4 script Golden Egg#14_DRAGON_EGG,{ $@EggHuntCount++;dispbottom"You just captured a Gold Egg! Lucky you!";announce"[Easter Egg Hunt] Total of ("+$@EggHuntCount+"/"+$EggHuntTotal2+") have been captured! Better find the Eggs before it's too late!",bc_all;getitem $GItem_ID, $GReward_AM;disablenpcstrnpcinfo(0);donpcevent("EasterEggHunt#Sys")+"::OnEggEndCheck";end;OnInit:disablenpcstrnpcinfo(0);end;OnEnableGoldEgg:enablenpcstrnpcinfo(0);donpceventstrnpcinfo(0)+"::OnEggMove";end;OnEggMove:npcspeed50;while(true){getmapxy .@map$, .@x, .@y, 1;while(checkcell( .@map$, .@x2 = .@x +rand(-10,10), .@y2 = .@y +rand(-10,10), cell_chknopass));npcwalkto .@x2, .@y2;sleeprand(100,200);}end;}// Silver Egg Copies