Guest User

Untitled

a guest
May 24th, 2018
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.22 KB | None | 0 0
  1. // - SampleBOT System -
  2. // r0.1a
  3. // by Keoy - 2008
  4.  
  5. - script Initialize_syst -1,{
  6.  
  7. OnInit:
  8. setarray
  9.  
  10. $line_1[0],"0^FF8000****^000000","00^FF80009^00000000","0^FF800011111^000000","0^FF80002222^000000","0^FF800033^000000003","0^FF80004444^000000","0^FF8000555
  11.  
  12. 5^000000","0^FF8000666^0000000","0^FF80007777^000000","0^FF80008888^000000";
  13. setarray
  14.  
  15. $line_2[0],"0^FF8000*^00000000^FF8000*^000000","00^FF80009^00000000","00000^FF80001^000000","0000^FF80002^000000","0^FF800033^000000003","0^FF80004^000000000
  16.  
  17. ","0^FF80005^000000000","000^FF80006^0000000","0^FF80007^00000000^FF80007^000000","0^FF80008^000000000^FF80008^000000";
  18. setarray
  19.  
  20. $line_3[0],"0^FF8000*^00000000^FF8000*^000000","00^FF80009^00000000","0^FF800011111^000000","0^FF80002222^000000","0^FF800033333^000000","0^FF80004444^000000
  21.  
  22. ","0^FF80005555^000000","000^FF80006^0000000","0^FF80007777^000000","0^FF80008888^000000";
  23. setarray
  24.  
  25. $line_4[0],"0^FF8000*^00000000^FF8000*^000000","00^FF80009^00000000","0^FF80001^0000000000","0000^FF80002^000000","0000^FF800033^000000","0000^FF80004^000000
  26.  
  27. ","0^FF8000500^FF80005^000000","000^FF80006^0000000","0^FF80007^00000000^FF80007^000000","0000^FF80008^000000";
  28. setarray
  29.  
  30. $line_5[0],"0^FF8000****^000000","00^FF80009^00000000","0^FF800011111^000000","0^FF80002222^000000","0000^FF800033^000000","0^FF80004444^000000","0^FF8000555
  31.  
  32. 5^000000","000^FF80006^0000000","0^FF80007777^000000","0^FF80008888^000000";
  33. end;
  34.  
  35. }
  36.  
  37. - script SampleBot -1,{
  38.  
  39. OnCheckBOT:
  40. if(checking_person == 1)
  41. {
  42. detachrid;
  43. attachrid(getarg(0));
  44. }
  45. callfunc "Check_bot";
  46. close;
  47. end;
  48.  
  49. OnWhisperGlobal:
  50. if(@whispervar0$ == "andar" || @whispervar0$ == "Andar" || @whispervar0$ == "ANDAR")
  51. {
  52. OnWlkFunc:
  53. dispbottom "Por favor digite agora a coordenada X";
  54. dispbottom "Para onde você deseja que o Monstro ande.";
  55. input @digitX;
  56. dispbottom "Agora por favor digite a Coordenada Y";
  57. input @digitY;
  58. dispbottom "Carregando...";
  59. npcwalkto @digitX,@digitY;
  60. dispbottom "Carregamento Completo!";
  61. dispbottom "Monstro em movimento...";
  62. end;
  63. } else if(@whispervar0$ == "falar" || @whispervar0$ == "Falar" || @whispervar0$ == "FALAR")
  64. {
  65. OnTlkFunc:
  66. dispbottom "Por favor digite o que deseja que o monstro fale:";
  67. input @digitTLK$;
  68. dispbottom "Carregando...";
  69. npctalk @digitTLK$;
  70. dispbottom "Carregamento Completo!";
  71. dispbottom "Monstro falou...";
  72. end;
  73. } else if(@whispervar0$ == "checar" || @whispervar0$ == "Checar" || @whispervar0$ == "CHECAR")
  74. {
  75. OnChkFunc:
  76. dispbottom "Por favor digite o nome da pessoa que deseja que o anti-bot cheque:";
  77. input @checkperson$;
  78. dispbottom "Carregando...";
  79. dispbottom "Pessoa sendo interrogada!";
  80. set @checking,getcharid(3,@checkperson$);
  81. set checking_person,1;
  82. callsub OnCheckBOT,@checking;
  83. end;
  84. } else if(@whispervar0$ == "mover" || @whispervar0$ == "Mover" || @whispervar0$ == "MOVER")
  85. {
  86. OnMovFunc:
  87. dispbottom "Por favor digite o nome do BOT que você deseja que seja movido";
  88. dispbottom "(Obs: Exatamente igual!)";
  89. input @moving_$;
  90. dispbottom "Agora digite a coordenada X";
  91. input @X;
  92. dispbottom "Agora a coordenada Y";
  93. input @Y;
  94. dispbottom "Carregando...";
  95. moveNPC @moving_$,@X,@Y;
  96. dispbottom "Pronto!";
  97. end;
  98. } else
  99.  
  100. dispbottom "-----------------------------------------";
  101. dispbottom "---------SampleBot System [BETA]---------";
  102. dispbottom "-----------------------------------------";
  103. dispbottom "Bem vindo! O que deseja? ----------------";
  104. dispbottom "1 - Fazer o bot andar -------------------";
  105. dispbottom "2 - Fazer o bot falar -------------------";
  106. dispbottom "3 - Fazer o bot checar alguém -----------";
  107. dispbottom "4 - Mover o Bot de local (X/Y) ----------";
  108. dispbottom "0 - Nada --------------------------------";
  109. dispbottom "-----------------------------------------";
  110. dispbottom "-----------------------------------------";
  111. dispbottom "-----------------------------------------";
  112. input @int;
  113. if(@int == 1) callsub OnWlkFunc;
  114. if(@int == 2) callsub OnTlkFunc;
  115. if(@int == 3) callsub OnChkFunc;
  116. if(@int == 4) callsub OnMovFunc;
  117. if(@int == 0) callsub OnAfterTimer;
  118. end;
  119.  
  120. OnInit:
  121. initnpctimer;
  122. npcspeed 150;
  123. end;
  124.  
  125. OnTimer30000:
  126. OnAfterTimer:
  127. setnpctimer 0;
  128. if (getmapxy ($@map$,$@mapx,$@mapy,1)!=0) end;
  129. if (rand(0,1)>0) //+
  130. {
  131. if(rand(6)>3)//++
  132. {
  133. npcwalkto $@mapx+rand(0,15),$@mapy+rand(0,15);
  134. end;
  135. }
  136. npcwalkto $@mapx+rand(0,15),$@mapy-rand(0,15);
  137. callsub OnInit;
  138. end;
  139. }else if(rand(12)>5) //-+
  140. {
  141. npcwalkto $@mapx-rand(0,15),$@mapy-rand(0,15);
  142. end;
  143. } else
  144. set $@x,$@x+rand(1,200);
  145. for(set $@y,500; $@y < $@x ; set $@y,$@y-10) //+++
  146. {
  147. npcwalkto $@x,$@y;
  148. end;
  149. }
  150. end;
  151.  
  152. } //END SCRIPT
  153.  
  154. function script Check_bot {
  155.  
  156. //Pega o IP do jogador, use esta função com cuidado!
  157. set char_ip,query_sql SELECT `last_ip` FROM `login` WHERE `account_id` = " +getcharid(3)+ "";
  158. if(char_ip == -1){ set $global_opt$,"TXT"; }
  159. if(char_ip != -1){ set $global_opt$,"SQL"; }
  160.  
  161. mes "[SampleBot]";
  162. if(USED != 1)
  163. {
  164. set @can_error,5;
  165. set USED,1;
  166. break;
  167. }
  168. mes "Olá, "+strcharinfo(0)+"!";
  169. mes "Espero que não se importe";
  170. mes "Em fazer alguns testes.";
  171. next;
  172. mes "[SampleBot]";
  173. mes "Por favor digite a soma dos números a seguir:";
  174. mes "+$line_1[@i]+""+$line_1[@i_]+""+$line_1[@i3]+";
  175. mes "+$line_2[@i]+""+$line_2[@i_]+""+$line_2[@i3]+";
  176. mes "+$line_3[@i]+""+$line_3[@i_]+""+$line_3[@i3]+";
  177. mes "+$line_4[@i]+""+$line_4[@i_]+""+$line_4[@i3]+";
  178. mes "+$line_5[@i]+""+$line_5[@i_]+""+$line_5[@i3]+";
  179. mes "+$line_1[@i]$+""+$line_1[@i_]+""+$line_1[@i3]+";
  180. mes "+$line_2[@i]$+""+$line_2[@i_]+""+$line_2[@i3]+";
  181. mes "+$line_3[@i]$+""+$line_3[@i_]+""+$line_3[@i3]+";
  182. mes "+$line_4[@i]$+""+$line_4[@i_]+""+$line_4[@i3]+";
  183. mes "+$line_5[@i]$+""+$line_5[@i_]+""+$line_5[@i3]+";
  184. input @str;
  185. if(@str != @i+@i_+@i3) callsub OnError_,1;
  186. next;
  187. mes "[SampleBot]";
  188. mes "Agora por favor digite seu nick:";
  189. mes "(Exatamente Igual!)";
  190. input @str$;
  191. if(@str$ != strcharinfo(0)) callsub OnError_,2;
  192. next;
  193. mes "[SampleBot]";
  194. mes "Checagem concluida, desculpe qualquer transtorno!";
  195. set USED,0;
  196. return;
  197.  
  198. OnError_:
  199. next;
  200. mes "[SampleBot]";
  201. if(@can_error == 0)
  202. {
  203. mes "Me desculpe "+strcharinfo(0)+", mas você";
  204. mes "Errou sucessivamente nas etapas de teste.";
  205. mes "Você será banido por uso de BOTS!";
  206. logmes "H-Defense: O jogador "+strcharinfo(0)+"(ACC ID:"+getcharid(3)+") foi banido do servidor por uso de BOT";
  207. if($global_opt$ == "SQL")query_sql "INSERT INTO ipbanlist (list,btime,rtime,reason) VALUES
  208.  
  209. ('"+char_ip+"','"+gettime(7)+"-"+gettime(6)+"-"+gettime(5)+" "+gettime(3)+":"+gettime(2)+":"+gettime(1)+"','2099-01-01 00:00:00','"Utilizou Bot"')";
  210. if($global_opt$ == "TXT") atcommand "@ban 1yr "+strcharinfo(0);
  211. atcommand "@kick "+strcharinfo(0);
  212. return;
  213. }
  214. set @can_error,@can_error - 1;
  215. mes "Me desculpe "+strcharinfo(0)+", mas você";
  216. mes "Errou na etapa "+getarg(0)+" de nosso teste.";
  217. mes "Peço que repita-a. Você só pode errar mais "+@can_error+"";
  218. if(@can_error > 1)
  219. {
  220. mes "Vezes!";
  221. break;
  222. }
  223. if(@can_error == 1)
  224. {
  225. mes "Vez!";
  226. break;
  227. }
  228. next;
  229. mes "[SampleBot]";
  230. mes "Agora iremos repetir todas as etapas!";
  231. callsub OnError_,getarg(0);
  232. end;
  233. }
  234. // === Duplicatas ===
  235. // Algumas que achei no eAthena
  236. prt_fild02.gat,143,191,8 duplicate(SampleBot) Mandragora#1 1020
  237. prt_fild02.gat,265,310,8 duplicate(SampleBot) Mandragora#2 1020
  238. prt_fild02.gat,143,139,8 duplicate(SampleBot) Mandragora#3 1020
  239. prt_fild02.gat,109,319,8 duplicate(SampleBot) Mandragora#4 1020
  240. prt_fild02.gat,307,191,8 duplicate(SampleBot) Mandragora#5 1020
  241.  
  242. beach_dun3.gat,189,195,8 duplicate(SampleBot) Sapo de Thara#1 1034
  243. beach_dun3.gat,187,150,8 duplicate(SampleBot) Sapo de Thara#2 1034
  244. beach_dun3.gat,147,234,8 duplicate(SampleBot) Sapo de Thara#3 1034
  245. beach_dun3.gat,100,140,8 duplicate(SampleBot) Sapo de Thara#4 1034
  246. beach_dun3.gat,180,216,8 duplicate(SampleBot) Sapo de Thara#5 1034
  247.  
  248. ein_fild07.gat,264,142,8 duplicate(SampleBot) Geographer#1 1368
  249. ein_fild07.gat,203,169,8 duplicate(SampleBot) Geographer#2 1368
  250. ein_fild07.gat,218,297,8 duplicate(SampleBot) Geographer#3 1368
  251. ein_fild07.gat,319,184,8 duplicate(SampleBot) Geographer#4 1368
  252. ein_fild07.gat,201,100,8 duplicate(SampleBot) Geographer#5 1368
Add Comment
Please, Sign In to add comment