Advertisement
Guest User

Untitled

a guest
May 6th, 2016
50
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.38 KB | None | 0 0
  1. - script Bombring -1,{
  2. OnInit:
  3. set .eventstarted, 0;
  4. set $bombring_reward,12256;
  5. bindatcmd "enablebombring","Bombring::OnGMStart";
  6. bindatcmd "disablebombring","Bombring::OnGMStop";
  7. hideonnpc "The Baaam#qz";
  8. hideonnpc "The Baaam#prt";
  9. end;
  10.  
  11. OnGMStart:
  12. if (getgroupid() < 99){
  13. dispbottom "You are not eligible for this command.", RED;
  14. end;
  15. }
  16. set .eventstarted, 0;
  17. OnEventStart:
  18. initnpctimer;
  19. hideoffnpc "The Baaam#prt";
  20. set .x, 5;
  21. OnTimer0000:
  22. if (.eventstarted == 1)
  23. end;
  24. announce "The Baaam: The bombring event has started!",bc_all;
  25. announce "The Baaam: Come to prontera and talk to me to join!",bc_all;
  26. announce "The Baaam: "+.x+" minutes remaining before it starts!",bc_all;
  27. set .x, .x - 1;
  28. end;
  29. OnTimer60000:
  30. OnTimer120000:
  31. OnTimer180000:
  32. OnTimer240000:
  33. if (.eventstarted == 1)
  34. end;
  35. announce "The Baaam: "+.x+" minutes remaining before the bombring event starts!",bc_all;
  36. set .x, .x - 1;
  37. end;
  38. OnTimer290000:
  39. if (.eventstarted == 1)
  40. end;
  41. announce "The Baaam: 10 seconds before the bombring event starts!",bc_all;
  42. end;
  43. OnTimer300000:
  44. if (.eventstarted == 1)
  45. end;
  46. set .totalplayers, getmapusers ("quiz_02");
  47. announce "The Baaam: "+.totalplayers+" players joined!",bc_all;
  48. announce "The Baaam: The bombring even has started! Ciao!",bc_all;
  49. hideonnpc "The Baaam#prt";
  50. stopnpctimer;
  51. callsub OnEventStart1;
  52. end;
  53.  
  54. OnEventStart1:
  55. set .totalplayers, getmapusers ("quiz_02");
  56. mapannounce "quiz_02","The Baaam: Okay listen up, this is how it works.",bc_all;
  57. sleep 2000;
  58. mapannounce "quiz_02","The Baaam: Bombrings will run rampant in this area.",bc_all;
  59. sleep 2000;
  60. mapannounce "quiz_02","The Baaam: and all of them will go booooooom!",bc_all;
  61. sleep 2000;
  62. mapannounce "quiz_02","The Baaam: all you have to do is avoid them and stay alive :P",bc_all;
  63. sleep 2000;
  64. mapannounce "quiz_02","The Baaam: This will run for 30 seconds for 5 total rounds.",bc_all;
  65. sleep 2000;
  66. mapannounce "quiz_02","The Baaam: Sooooooooooo, ready or not here they come!!!", bc_all;
  67.  
  68. for (set .round,1;.round <= 5;set .round, .round + 1) {
  69. set .totalplayers, getmapusers ("quiz_02");
  70. callsub OnBombringSummon;
  71. sleep 10000;
  72. }
  73.  
  74. if (.round > 5 && getmapusers("quiz_02") > 0){
  75. hideoffnpc "The Baaam#qz";
  76. mapannounce "quiz_02","The Baaam: Wooooow! That's rare! People won! :D",bc_all;
  77. }
  78. end;
  79.  
  80. OnBombringSummon:
  81. mapannounce "quiz_02","The Baaam: Round "+.round+"!!",bc_all;
  82. set .eventstarted, 1;
  83. initnpctimer;
  84. while (.eventstarted == 1) {
  85. if ( (3 * .totalplayers) <= 60)
  86. areamonster "quiz_02",48,334,71,357,"Run for you life!",1904,3 * .totalplayers;
  87. else
  88. areamonster "quiz_02",48,334,71,357,"Run for you life!",1904,60;
  89.  
  90. if(.round == 1) {
  91. sleep 4000;
  92. } else if (.round == 2) {
  93. sleep 3000;
  94. } else if (.round == 3) {
  95. sleep 2000;
  96. } else if (.round == 4) {
  97. sleep 1500;
  98. } else if (.round == 5) {
  99. sleep 1000;
  100. }
  101. }
  102. if (.eventstarted == 1)
  103. mapannounce "quiz_02","The Baaam: Round "+.round+" has finished!!",bc_all;
  104. if (.round < 5)
  105. mapannounce "quiz_02","The Baaam: Next round in 10 seconds.",bc_all;
  106. return;
  107.  
  108. OnTimer31000:
  109. if (.eventstarted == 0)
  110. end;
  111. else
  112. set .eventstarted, 0;
  113. killmonsterall "quiz_02";
  114. cleanmap "quiz_02";
  115. stopnpctimer;
  116. end;
  117.  
  118. OnPCDieEvent:
  119. if (strcharinfo(3) == "quiz_02") {
  120. mapannounce "quiz_02","The Baaam: "+strcharinfo(0)+" has been blown up!!",bc_all;
  121. dispbottom "You have received 100 CASHPOINTS for participating in this event.";
  122. set #CASHPOINTS, #CASHPOINTS + 100;
  123. warp "savepoint",0,0;
  124. if (getmapusers("quiz_02") <= 1) {
  125. stopnpctimer;
  126. set .eventstarted, 0;
  127. set .round, 6;
  128. killmonsterall "quiz_02";
  129. cleanmap "quiz_02";
  130. hideoffnpc "The Baaam#qz";
  131. mapannounce "quiz_02","The Baaam: Alright! We have a winner!!",bc_all;
  132. }
  133. }
  134. end;
  135.  
  136. OnGMStop:
  137. set .eventstarted, 0;
  138. set .round, 6;
  139. killmonsterall "quiz_02";
  140. cleanmap "quiz_02";
  141. hideoffnpc "The Baaam#qz";
  142. end;
  143. }
  144.  
  145. quiz_02,59,345,5 script The Baaam#qz 856,{
  146. mes "[The Baaam]";
  147. mes "Ha! You were really good back there!";
  148. mes "Here's a token for entertaining me.";
  149. next;
  150. mes "^00FF00You received 250 CASHPOINTS!";
  151. mes "You have received ^00FF00"+getitemname($bombring_reward)+"^000000!";
  152. set #CASHPOINTS, #CASHPOINTS + 250;
  153. getitem $bombring_reward,1;
  154. next;
  155. mes "[The Baaam]";
  156. mes "Now get out of here before I make you explode!";
  157. next;
  158. atcommand "@go 0";
  159. end;
  160. }
  161.  
  162. prontera,153,182,5 script The Baaam#prt 879,{
  163. mes "[The Baaam]";
  164. mes "Hi! Wanna join the Bombring event?";
  165. Switch(Select("Yes!:What is it about?:Nah, not interested.")) {
  166. case 1:
  167. mes "[The Baaam]";
  168. mes "Alright! Get ready!";
  169. next;
  170. warp "quiz_02",59,345;
  171. break;
  172. case 2:
  173. mes "[The Baaam]";
  174. mes "Well all you have to do is stay alive.";
  175. mes "That is by dodging exploding ^00FF00Bombrings^000000!";
  176. next;
  177. mes "[The Baaam]";
  178. mes "If you win, you will get:";
  179. mes "1x ^00FF00250 CASHPOINTS^000000!";
  180. mes "1x ^00FF00"+getitemname($bombring_reward)+"^000000!";
  181. close;
  182. break;
  183. case 3:
  184. mes "[The Baaam]";
  185. mes "Alright, see you around!";
  186. close;
  187. break;
  188. }
  189. end;
  190.  
  191. OnInit:
  192. hideonnpc "The Baaam#prt";
  193. }
  194.  
  195.  
  196.  
  197. quiz_02 mapflag Nopvp
  198. quiz_02 mapflag Nopenalty
  199. quiz_02 mapflag Nowarpto
  200. quiz_02 mapflag Nocommand 99
  201. quiz_02 mapflag Nodrop
  202. quiz_02 mapflag Nomobloot
  203. quiz_02 mapflag Noskill
  204. quiz_02 mapflag NoSave
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement