document.write('
Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. prontera,155,168,4 script Disguise Event 795,{
  2. //--- Basic Script Configuration Options ---//
  3. setcell "prontera",156,169,154,167,cell_walkable,0;
  4. setcell "prontera",154,169,156,167,cell_walkable,0;
  5. set .@npcname$,"[^0000FFDisguise NPC^000000]"; //<- NPC Name.
  6. set $@GMLevel,60; //<- GM Level needed to be considered a GM.
  7. //--- The Script ---//
  8. if (getgmlevel()>=$@GMLevel){goto GM_Player;}
  9. if ($@EventON){end;}
  10.  
  11. mes .@npcname$;
  12. mes "Welcome, how may i be of assistance.";
  13. menu "Information",iInfo,"Nothing, just passing through.",iNothing;
  14. iInfo:
  15. next;
  16. mes .@npcname$;
  17. mes "This event is actually quite simple";
  18. mes "At the start of the event, I will disguise myself";
  19. mes "into a monster randomly. You will then merely have to shout that monsters name outloud.";
  20. next;
  21. mes "If you get it correct, you get a prize. If not, then keep trying.";
  22. mes "Thatis all there is to know about this event.";
  23. close;
  24. iNothing:
  25. close;
  26. GM_Player:
  27. mes .@npcname$;
  28. mes "Please select an Option to modify.";
  29. menu "Turn ON/OFF Event",iEvent,"Event Settings",iSettings;
  30. iEvent:
  31. next;
  32. mes .@npcname$;
  33. if ($@EventON){mes "The Event is currently: [^0000FFON^000000]";
  34. mes "Would you like to turn it OFF?";}
  35. if (!$@EventON){mes "The Event is currently: [^FF0000OFF^000000]";
  36. mes "Would you like to turn it ON?";}
  37. menu "Yes",iYes,"No",iNothing;
  38. iYes:
  39. if ($@EventON)
  40. {set $@EventON,0; set $@Timer,0;
  41. setnpctimer 0; stopnpctimer;
  42. announce "A GM has decided to turn the Disguise Event off. As a result no further prizes will be given.",bc_map | bc_blue;
  43. deletepset 1;
  44. setnpcdisplay "Disguise Event",795;
  45. close;}
  46. set $@EventON,1; set $@Timer,1; setnpctimer 0; initnpctimer;
  47. set $@ResetCounter,$@ResetCounter+1;
  48. announce "The Disguise Event will begin in 3 minutes.",bc_all | bc_blue;
  49. announce "The Event is being held in Prontera.",bc_all | bc_blue;
  50. close;
  51. iSettings:
  52. next;
  53. mes .@npcname$;
  54. mes "Please select a setting to modify.";
  55. menu "Monster Display",iMonster,"Number of Rounds",iRounds,"Prize Settings",iPrize;
  56. iMonster:
  57. callfunc "Monster_Display";
  58. iRounds:
  59. callfunc "Rounds";
  60. iPrize:
  61. callfunc "Prize";
  62.  
  63. OnInit:
  64. defpattern 1,"([^:]+):.\\\\s*OMFGBBQLEETSAUCEGMOCEANRULESHAI!!.*", "iCorrect";
  65. activatepset 1;
  66. set $@EventON,0;
  67. set $@Wait,0;
  68. set $@Winner,0;
  69. set $Points,$Points;
  70. set $@ResetCounter,0;
  71. set $Rounds,20;
  72. set $Prize,7539;
  73. set $PrizeAmt,1;
  74. set $Rule,1;
  75. setarray $@MVP[0],1038,1039,1046,1059,1086,1087,1112,1115,1147,1150,1157,1159,1190,1251,1252,1272,1312,1373,
  76. 1389,1399,1418,1492,1502,1511,1583,1623,1630,1646,1647,1648,1649,1650,1651,1658,1685,1688,
  77. 1708,1719,1734,1751,1768,1779,1785,1802,1832,1871,1874,1885,1917,1980,2022,2068,2087,2131,
  78. 2156,2165;
  79. setarray $@BlackList[0], 1003,1006,1017,1021,1022,1027,1043,1075,1136,1137,1168,1171,1172,1173,1181,1210,1217,1218,
  80. 1222,1223,1224,1225,1226,1227,1228,1233,1284,1407,1411,1414,1495,1501,1900,1996,2000,2001,
  81. 2002,2003,2004,2005,2006,2007,2011,2012,2025,2028,2029,2030,2031,2032,2033,2034,2035,2036,
  82. 2037,2038,2039,2040,2041,2042,2043,2044,2045,2046,2047,2048,2049,2050,2051,2052,2053,2054,
  83. 2055,2056,2057,2058,2059,2060,2061,2062,2063,2064,2065,2066,2067,2075,2076,2077,2078,2079,
  84. 2080,2081,2083,2084,2085,2086,2087,2088,2089,2090,2091,2092,2093,2094,2095,2096,2097,2098,
  85. 2099,2100,2101,2012,2103,2104,2105,2106,2107,2108,2109,2110,2111,2112,2113,2114,2115,2116,
  86. 2117,2118;
  87. setarray $@BlackList2[0],2119,2120,2121,2123,2124,2125,1496;
  88. end;
  89. OnClock0000:
  90. OnClock0100:
  91. OnClock0200:
  92. OnClock0300:
  93. OnClock0400:
  94. OnClock0500:
  95. OnClock0600:
  96. OnClock0700:
  97. OnClock0800:
  98. OnClock0900:
  99. OnClock1000:
  100. OnClock1100:
  101. OnClock1200:
  102. OnClock1300:
  103. OnClock1400:
  104. OnClock1500:
  105. OnClock1600:
  106. OnClock1700:
  107. OnClock1800:
  108. OnClock1900:
  109. OnClock2000:
  110. OnClock2100:
  111. OnClock2200:
  112. set $@ResetCounter,$@ResetCounter+1;
  113. set $@EventON,1;
  114. set $@Timer,1;
  115. set $@Wait,1;
  116. announce "The Disguise Event will begin in 3 minutes.",bc_all | bc_blue;
  117. announce "The Event is being held in Prontera.",bc_all | bc_blue;
  118. setnpctimer 0;
  119. initnpctimer;
  120. end;
  121. OnTimer10000:
  122. if ($@Timer){end;}
  123. if ($@Change){end;}
  124. set $@Wait,0;
  125. goto iDisguise;
  126. //donpcevent "DisguiseEvent::OnDisguise";
  127. end;
  128. OnTimer30000:
  129. if ($@Timer){end;}
  130. set $@Change,0;
  131. setnpcdisplay "Disguise Event",795;
  132. npctalk "You took too long to guess what i was. Please wait 10 seconds while i disguise again.";
  133. specialeffect 725;
  134. set $MonsterName$,"OMFGBBQLEETSAUCEGMOCEANRULESHAI!!";
  135. deletepset 1;
  136. stopnpctimer;
  137. setnpctimer 0;
  138. initnpctimer;
  139. end;
  140. OnTimer60000:
  141. if ($@Timer!=1){end;}
  142. if ($@Timer==1)
  143. {announce "The Disguise Event will begin in 2 minutes.",bc_all | bc_blue;
  144. announce "The Event is being held in Prontera.",bc_all | bc_blue;
  145. end;}
  146. OnTimer120000:
  147. if ($@Timer!=1){end;}
  148. if ($@Timer==1)
  149. {announce "The Disguise Event will begin 1 minute.",bc_all | bc_blue;
  150. announce "The Event is being held in Prontera.",bc_all | bc_blue;
  151. end;}
  152. OnTimer180000:
  153. if ($@Timer!=1){end;}
  154. if ($@Timer==1)
  155. {announce "The Disguise Event has begun!",bc_all | bc_blue;
  156. announce "The Event is being held in Prontera.",bc_all | bc_blue;
  157. set $@Timer,0; stopnpctimer;
  158. setnpctimer 0; initnpctimer;
  159. goto iDisguise;
  160. //donpcevent "DisguiseEvent::OnDisguise";
  161. end;}
  162. announce "Something went wrong with the Disguise Event.",bc_all | bc_blue;
  163. announce "Please notify a GM ASAP. Thank you.",bc_all | bc_blue;
  164. end;
  165. iDisguise:
  166. if ($Rule==1)
  167. {set $@Winner,0;
  168. set $@Monster,1000+rand(1,995);
  169. for(set .@BL,0; .@BL<getarraysize($@BlackList); set .@BL,.@BL+1)
  170. {if ($@Monster==$@BlackList[.@BL] || $@Monster==$@BlackList2[.@BL])
  171. {goto iDisguise;}}
  172. if ($@Monster==$@LastMonster){goto iDisguise;}
  173. set $@LastMonster,$@Monster;
  174. set $MonsterName$,getmonsterinfo($@Monster,0);}
  175. if ($Rule==2)
  176. {set $@Winner,0;
  177. set $@Monster,rand(49);
  178. set $MonsterName$,getmonsterinfo($@MVP[$@Monster],0);}
  179. deletepset 1;
  180. defpattern 1,"([^:]+):.\\\\s*"+$MonsterName$+".*", "iCorrect";
  181. activatepset 1;
  182. if ($Rule==1){setnpcdisplay "Disguise Event",$@Monster;}
  183. if ($Rule==2){setnpcdisplay "Disguise Event",$@MVP[$@Monster];}
  184. set $@Change,1;
  185. setnpctimer 0;
  186. //Hint
  187. end;
  188. iCorrect:
  189. if ($@Winner){dispbottom "Someone has already won this round."; end;}
  190. set $@Winner,1;
  191. set $@RoundCount,$@RoundCount+1;
  192. deletepset 1;
  193. defpattern 1,"([^:]+):.*\\\\sOMFGBBQLEETSAUCEGMOCEANRULESHAI!!.*", "iFailCheater";
  194. activatepset 1;
  195. getitem $Prize,$PrizeAmt;
  196. announce ""+strcharinfo(0)+" is correct! I was disguised as: "+$MonsterName$+"",bc_map | bc_blue;
  197. if ($@RoundCount>=$Rounds)
  198. {setnpcdisplay "Disguise Event",795;
  199. set $@RoundCount,0; set $@Change,0; set $@EventON,0;
  200. setnpctimer 0; stopnpctimer;
  201. npctalk "Thank you all for playing. That was the last round of the Disguise Event. Come play again later.";
  202. end;}
  203. setnpcdisplay "Disguise Event",795;
  204. set $@Change,0;
  205. setnpctimer 0;
  206. end;
  207.  
  208. iFailCheater:
  209. end;
  210. }
  211. //--- The Functions ---//
  212. function script Rounds {
  213. next;
  214. mes "Please Input the number of rounds you want the event to last.";
  215. mes "Current Number of Rounds: [^0000FF"+$Rounds+"^000000]";
  216. input .@Rounds;
  217. set $Rounds,.@Rounds;
  218. next;
  219. mes "The number of rounds has been changed successfully.";
  220. mes "Number of Rounds: [^0000FF"+$Rounds+"^000000]";
  221. mes "Come again.";
  222. close;
  223. }
  224. function script Prize {
  225. next;
  226. mes "Please Input the ItemID of the prize that will be given each round.";
  227. mes "Current Items is: [^0000FF"+getitemname($Prize)+"^000000] ItemID - ^0000FF"+$Prize+"^000000";
  228. input .@Prize;
  229. if (getitemname(.@Prize)=="" || getitemname(.@Prize)=="null")
  230. {next; mes "That item does not exist. Please try again."; close;}
  231. set $Prize,.@Prize;
  232. next;
  233. mes "Please Input the Ammount that is to be given.";
  234. input .@Ammount;
  235. if (.@Ammount<=0 || .@Ammount>=10000)
  236. {next; mes "That ammount is invalid. Using default ammount of 1.";}
  237. set $PrizeAmt,.@Ammount;
  238. next;
  239. mes "The Prize has been changed successfully.";
  240. mes "Prize: [^0000FF"+getitemname($Prize)+"^000000]x(^0000FF"+$PrizeAmt+"^000000)";
  241. close;
  242. }
  243. function script Monster_Display {
  244. setarray .@Rule[0],0,1,2;
  245. setarray .@Desc$[0],"","Transform as all monsters.","Transform as MvP's only.";
  246. next;
  247. mes "Please select a Disguise Rule.";
  248. mes "Rule 1 - Transform as all monsters.";
  249. mes "Rule 2 - Transform as MvP's only.";
  250. menu "Rule 1:Rule 2",iRule;
  251. iRule:
  252. set $Rule,.@Rule[@menu];
  253. next;
  254. mes "The Disguise Rule, has been changed successfully.";
  255. mes "Current Rule: ^0000FF"+$Rule+"^000000 - ^0000FF"+.@Desc$[@menu]+"^000000";
  256. close;
  257. }
  258.  
  259. prontera,155,169,4 script . 1084,1,1,{
  260. if (BaseLevel > 50) {
  261. atcommand "@die";
  262. }
  263. }
  264. prontera,154,169,0 duplicate(.) .#02 1084,1,1
  265. prontera,156,169,0 duplicate(.) .#03 1084,1,1
  266. prontera,154,168,0 duplicate(.) .#04 1084,1,1
  267. prontera,156,168,0 duplicate(.) .#05 1084,1,1
  268. prontera,155,167,0 duplicate(.) .#06 1084,1,1
  269. prontera,154,167,0 duplicate(.) .#07 1084,1,1
  270. prontera,156,167,0 duplicate(.) .#08 1084,1,1
');