Advertisement
Guest User

Untitled

a guest
Jun 18th, 2017
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 26.60 KB | None | 0 0
  1. ; Lottery/Bigno Bot By `Xronic ;
  2. ; Please dont change credits ;
  3. ; version bot: 1.3 / update: soon ;
  4. ; //////////////////////////////// ;
  5. ; Variables (% | Exmaple: %b.chan) ;
  6. ; %b.chan = channel, %b.sign = ! ;
  7. ; //////////////////////////////// ;
  8. on *:kick:%b.Chan: if ($read(bingoregs.txt,w,* $+ $address($knick,2)) { write -dl $+ $readn bingoregs.txt }
  9. on *:ban:%b.chan: if ($read(bingoregs.txt,w,* $+ $banmask) { write -dl $+ $readn bingoregs.txt }
  10. on *:part:%b.Chan: if ($read(bingoregs.txt,w,* $+ $wildsite) { write -dl $+ $readn bingoregs.txt }
  11. on *:Quit: if ($read(bingoregs.txt,w,* $+ $wildsite) { write -dl $+ $readn bingoregs.txt }
  12. on *:nick: if ($read(bingoregs.txt,w,* $+ $wildsite) { write -l $+ $readn bingoregs.txt $nick $wildsite }
  13. on *:connect:{
  14. timer 1 2 /join %b.chan
  15. echo -s %color1 Welcome to Xronic lotterybot Version: 1.3 %color2
  16. echo -s %color1 Have Bug? do /q [P51]`Xronic %color2
  17. echo -s %color1 Ty for you use in my bot %color2
  18. echo -s %color1 Ty Vendetta for the help %color2
  19. echo -s %color1 Next a good day. %color2
  20. window -e @עדכונים
  21. echo @עדכונים %color1 ברוכים הבאים לגרסא החדשה 1.3 %color2
  22. echo @עדכונים %color1 !login User Pass מה שעודכן בבוט,מערכת אדמינים ע"י התחברות לבוט %color2
  23. echo @עדכונים %color1 נוספו דיאלוגים חדשים וידותיים יותר %color2
  24. echo @עדכונים %color1 תודה מיוחדת לעוזרים בבוט: Vendetta` %color2
  25. }
  26. on *:load:{
  27. set %b.chan $input(channel,e,channel( $+ %b.chan $+ )
  28. set %b.sign $input(Sign,e,sign ex: !)
  29. set %color1 0,1[11«0 | set %color2 11»0]
  30. echo -a %color1 on load settings is over! %color2
  31. window -e @עדכונים
  32. echo @עדכונים %color1 ברוכים הבאים לגרסא החדשה 1.3 %color2
  33. echo @עדכונים %color1 !login User Pass מה שעודכן בבוט,מערכת אדמינים ע"י התחברות לבוט %color2
  34. echo @עדכונים %color1 נוספו דיאלוגים חדשים וידותיים יותר %color2
  35. echo @עדכונים %color תודה מיוחדת לעוזרים בבוט: Vendetta` %color2
  36. }
  37. on *:text:*:%b.chan: {
  38. if ($1 == %b.sign $+ Regs) && (%bingo.status == ON) && (!%flood) { bingoregs | set -u3 %flood 1 }
  39. elseif (($1 == %b.sign $+ Regs) || ($1 == %b.sign $+ Reg) || ($1 == %b.sign $+ Status) || ($1 == %b.sign $+ Del) || $1 == %b.sign $+ prize)) && (%bingo.status == OFF) && (!%flood) { msg %b.chan %color1 There isn't lottery for the momnet, Ready for the next match. %color2 | set -u3 %flood 1 }
  40. elseif (($1 == %b.sign $+ Commands) || ($1 == %b.sign $+ Help)) && (%bingo.status == OFF) && (!%flood) { msg %b.chan %color1 %color3 $+ Commands are: $+ %color4 $+ %color3 %b.sign $+ %color4 $+ Admin $+ %color3 %b.sign $+ %color4 $+ Prize $+ %color3 %b.sign $+ %color4 $+ Regs $+ %color3 %b.sign $+ %color4 $+ status $+ %color3 %b.sign $+ %color4 $+ Regs $+ %color3 %b.sign $+ %color4 $+ Last %color2 | set -u3 %flood 1 }
  41. elseif (($1 == %b.sign $+ Commands) || ($1 == %b.sign $+ Help)) && (%bingo.status == ON) && (!%flood) { msg %b.chan %color1 %color3 $+ Commands are: $+ %color4 $+ %color3 %b.sign $+ %color4 $+ Admin $+ %color3 %b.sign $+ %color4 $+ Prize $+ %color3 %b.sign $+ %color4 $+ Regs $+ %color3 %b.sign $+ %color4 $+ status $+ %color3 %b.sign $+ %color4 $+ Regs $+ %color3 %b.sign $+ %color4 $+ Last %color2 | set -u3 %flood 1 }
  42. elseif ($1 == %b.sign $+ Prize) && (%bingo.status == ON) && (!%flood) { msg %b.chan %color1 %color3 $+ The prize is: %color4 $+ %b.prize %color2 | set -u3 %flood 1 }
  43. elseif ($1 == %b.sign $+ status) && (%bingo.status == ON) && (!%flood) { msg %b.chan %color1 %color3 $+ The lottery started in: %color4 $+  $+ $readini(Settings.ini,At,Date-time) $+  $+ %color3 admin: %color4 $+  $+ %b.admin $+  %color3 $+ prize: %color4 $+  $+ %b.prize $+ , %color4 $+ to register type: %color3 $+ %b.sign $+ %color4 $+ Reg $+ . %color2 | set -u3 %flood 1 }
  44. elseif ($1 == %b.sign $+ Last) && (%bingo.status == OFF) && (!%flood) { msg %b.chan %color1 %color3 $+ The last lottery started in: %color4 $+  $+ $readini(Settings.ini,At,Date-time) $+  %color3 $+ prize: %color4 $+  $+ %b.prize $+ , %color3 $+  $+ admin: $+  $+ %color4 %b.admin $+ , %color3 $+ winner: %color4 $+  $+ %last.win $+  %color2 }
  45. elseif ($1 == %b.sign $+ Admin) && (%bingo.status == ON) && (!%flood) { msg %b.chan %color1 %color3 $+ The admin is: %color4 $+ %b.admin %color2 | set -u3 %flood 1 }
  46. if ($1 == %b.sign $+ Admins) && (!%flood) {
  47. var %x = 1
  48. while ($ini(Admins.ini,%x)) {
  49. if ($readini(Admins.ini,$ini(Admins.ini,%x),Logged)) set %ononon %ononon $ini(Admins.ini,%x)
  50. else set %ofofff %ofofff $ini(Admins.ini,%x)
  51. inc %x
  52. }
  53. msg %b.chan %color1 Admins Are: 3 $+ %ononon 4 $+ %ofofff %color2
  54. unset %ofofff , %ononon
  55. }
  56. elseif ($1 == %b.sign $+ Credits) && (!%flood) { msg %b.chan %color1 %color4 $+ Lottery bot was created by %color3 $+ Xronic %color4 $+ version: $+ %color3 1.3 %color2 | set -u3 %flood 1 }
  57. elseif ($1 == %b.sign $+ Version) && (!%flood) { msg %b.chan %color1 Lotterybot version: 1.3 %color2 }
  58. elseif (($1 == %b.sign $+ Del) || ($1 == %b.sign $+ Remove)) && (%bingo.status == ON) && (!%flood) {
  59. if ($read(bingoregs.txt,w,* $+ $wildsite)) { write -dl $+ $readn bingoregs.txt | msg %b.chan %color1 %color3 $+  $+ $nick $+  $+ %color4 $+ , You are removed from the Lottery in success! %color2 | set -u2 %flood 1 }
  60. else { msg %b.chan %color1 %color3 $+  $+ $nick $+  $+ %color4 $+ , You are not registered to the lottery! %color2 | set -u2 %flood 1 }
  61. }
  62. elseif ($1 == %b.sign $+ Reg) && (%bingo.status == ON) && (%b.tagg == 1) && (* $+ %b.tag $+ * iswm $nick) && (!%flood) { msg %b.chan %color1 %color3 $+  $+ $nick $+  $+ %color4 $+ , admin %color3 $+  $+ %b.admin $+  $+ %color4 blocked your tag! ( $+ %color3 $+ %b.tag $+ %color4 $+ ) %color2 | set -u3 %flood 1 }
  63. elseif ($1 == %b.sign $+ Reg) && (%bingo.status == ON) && (!%flood) {
  64. if ($read(bingoregs.txt,w,* $+ $wildsite)) { msg %b.chan %color1 %color3 $+  $+ $nick $+  $+ %color4 $+ , You are already register to the lottery %color2 | set -u3 %flood 1 | halt }
  65. else { write bingoregs.txt $nick $wildsite | msg %b.chan %color1 %color3 $+  $+ $nick $+  $+ %color4 $+ , succesfully registered to the lottery now %color2 | set -u3 %flood 1
  66. if ($lines(bingoregs.txt) == %b.users) { endbingo }
  67. }
  68. }
  69. }
  70. on *:text:$(%b.sign $+ *):*:{
  71. tokenize 32 $mid($1-,2) | var %n = Ctl $nick,%c = Ctl %b.chan
  72. if (!%Cfld) {
  73. if ($target == %b.chan) || ($target !ischan) {
  74. %e = Ctl $iif($target ischan,%b.chan,$nick)
  75. if ($1 == Admins) { %e $Admins | inc -u5 %flood }
  76. if ($Admins($right($wildsite,-4)).logged) {
  77. if ($1 == TEXT) { %e TEXT | cfld }
  78. }
  79. }
  80. if ($target !ischan) {
  81. if ($1 == Login) && ($Admins($2 $3).login) && (!$Admins($right($wildsite,-4)).logged) { writeini Admins.ini $2 Logged $right($wildsite,-4) | %c $nick has been connected to admin account. User: $Admins($right($wildsite,-4)).user ( $+ $wildsite $+ ) | %n You have been connected to admin account. User: $Admins($right($wildsite,-4)).user ( $+ $wildsite $+ ) | /mode %b.chan +v $nick | inc -u5 %flood }
  82. elseif ($1 == Logout) && ($Admins($right($wildsite,-4)).logged) { %c $nick has been disconnected from admin account. User: $Admins($right($wildsite,-4)).user $+ $Chr(44) Reason: Logout ( $+ $wildsite $+ ) | %n You have been disconnected to admin account. User: $Admins($right($wildsite,-4)).user $+ $Chr(44) ( $+ $wildsite $+ ) | remini Admins.ini $Admins($right($wildsite,-4)).user Logged | inc -u5 %flood }
  83. elseif ($1 == Add && $5) {
  84. if ($2 == Admin) {
  85. if ($3 == %botpass) {
  86. if ($Admins($4).isin) { %n Error: the username $4 is already in use $+ $chr(44) please try another user name. }
  87. else { writeini Admins.ini $4 Pass $5 | %n Admin successfully added $+ $chr(44) for login /msg $me %Cign $+ login $4 $5 }
  88. }
  89. else { %n Error: the bot pass is wrong ! }
  90. }
  91. inc -u5 %flood
  92. }
  93. elseif ($1 == Del && $4) {
  94. if ($2 == Admin) {
  95. if ($3 == %botpass) {
  96. if ($Admins($4).isin) { remini Admins.ini $4 | %n Admin successfully removed $+ $chr(44) user: $4 }
  97. else { %n Error: the username $4 is not on the admins list. }
  98. }
  99. else { %n Error: the bot pass is wrong ! }
  100. }
  101. inc -u5 %flood
  102. }
  103. elseif ($1 == Change && $5) {
  104. if ($2 == Botpass) {
  105. if ($3 == %botpass) {
  106. if ($4 == $5) { %n The bot pass is successfully changed from %botpass to $4 | set %botpass $4 }
  107. else { %n Error: Wrong syntax. !Change botpass <botpass> <newbotpass> <newbotpass> }
  108. }
  109. else { %n Error: the bot pass is wrong ! }
  110. }
  111. inc -u5 %flood
  112. }
  113. if (!$Admins($right($wildsite,-4)).logged) halt
  114. if ($1 == Help) || ($1 == commands) && (!%flood) { msg $nick %color1 Commands are: %b.sign $+ start, %b.sign $+ stop, %b.sign $+ set-users, %b.sign $+ set-admin, %b.sign $+ set-prize, %b.sign $+ set-mahur, %b.sign $+ set-lomahur, %b.sign $+ set-chan, %b.sign $+ set-winner, %b.sign $+ setblock-tag, %b.sign $+ statusblock-tag (options: 1/2), %b.sign $+ Statusbot (options: 0/1) %color2 | set -u3 %flood 1 }
  115. elseif ($1 == start) && (!%flood) { unset %bingo.status | startbingo-pm | set -u3 %flood 1 }
  116. elseif ($1 == start) && (%bingo.status == ON) && (!%flood) { msg $nick %color1 The Lottery 9running %color4 $+ in the channel.| set -u3 %flood 1 }
  117. elseif ($1 == stop) { notbingo }
  118. elseif ($1 == stop) && (%bino.status == OFF) && (!%flood) { msg $nick %color1 Lottery isn't running at the momenet. %color2 | set -u3 %flood 1 }
  119. elseif ($1 == set-users) && (!%flood) { set %b.users $2 | set %b.users $2- | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  120. elseif ($1 == set-admin) && (!%flood) { set %b.admin $2- | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  121. elseif ($1 == set-prize) && (!%flood) { set %b.prize $2- | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  122. elseif ($1 == set-mahur) && (!%flood) { set %bingo.rand ON | msg $nick %color1 Done!, now setting the winner for lottery commands: !set-winner <nick> Exmaple: !set-winner Xronic %color2 | set -u3 %flood 1 }
  123. elseif ($1 == newwiner) && (!%flood) { set %n.win ON | newwiner }
  124. elseif ($1 == set-lomahur) && (!%flood) { set %bingo.rand OFF | unset %b.winner | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  125. elseif ($1 == set-chan) && (!%flood) { set %b.chan $2 | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  126. elseif ($1 == set-winner) && (!%flood) { set %b.winner $2 | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  127. elseif ($1 == set-blocktag) && (!%flood) { set %b.tag $2- | msg $nick %color1 Done! %color2 | set -u3 %flood 1 }
  128. elseif ($1 == statusblock-tag) && (!%flood) { set %b.tagg $2 | msg $nick %color1 Done %color2 | set -u3 %flood 1 }
  129. elseif ($1 == StatusBot) && (!%flood) { set %bingo.run $2 | msg $nick %color1 Done %color2 | set -u3 %flood 1 }
  130. elseif ($1 == settings) && (!%flood) {
  131. if ($numtok(%b.chan,32) isnum 1-100) { msg $nick %color1 Cahnnel is: %b.chan %color2 | set -u3 %flood 1 }
  132. if ($numtok(%b.sign,32) isnum 1-100) { msg $nick %color1 Sign is: %b.sign %color2 | set -u3 %flood 1 }
  133. if ($numtok(%b.prize,32) isnum 1-100) { msg $nick %color1 Prize is: %b.prize %color2 | set -u3 %flood 1 }
  134. if (%bingo.run == 0) { msg $nick %color1 StatusBot: 4,1OFF!0,1 %color2 | set -u3 %flood 1 }
  135. if (%bingo.run == 1) { msg $nick %color1 StatusBot: 3,1ON!0,1 %color2 | set -u3 %flood 1 }
  136. if ($numtok(%b.winner,32) isnum 1-100) { msg $nick %color1 Winner is: %b.winner %color2 | set -u3 %flood 1 }
  137. if ($numtok(%b.admin,32) isnum 1-100) { msg $nick %color1 Admin is: %b.admin %color2 | set -u3 %flood 1 }
  138. if (%bingo.rand == ON) { msg $nick %color1 Mahur status: 3,1ON!0,1 %color2 | set -u3 %flood 1 }
  139. if ($numtok(%b.winner,32) == isnum 1-100) { msg $nick %color1 Winner: %b.winner %color2 | set -u3 %flood 1 }
  140. if (%bingo.rand == OFF) { msg $nick %color1 Mahur status: 4,1OFF!0,1 %color2 | set -u3 %flood 1 }
  141. }
  142. }
  143. }
  144. }
  145. alias Admins {
  146. if ($1) {
  147. if ($prop == user) { var %x = 1 | while (%x <= $ini(Admins.ini,0)) { if ($1 == $readini(Admins.ini,$ini(Admins.ini,%x),Logged)) return $ini(Admins.ini,%x) | inc %x } }
  148. if ($prop == login) && ($readini(Admins.ini,$gettok($1,1,32),Pass) == $gettok($1,2,32)) { return $true }
  149. if ($prop == isin) { var %x = 1 | while (%x <= $ini(Admins.ini,0)) { if ($1 == $ini(Admins.ini,%x)) { return $true | break } | inc %x } }
  150. if ($prop == logged) { var %x = 1 | while (%x <= $ini(Admins.ini,0)) { if ($1 == $readini(Admins.ini,$ini(Admins.ini,%x),Logged)) { return $true | break } | inc %x } }
  151. }
  152. if (!$prop) { var %x = 1, %y = 0 | while (%x <= $ini(Admins.ini,0)) { var %admins = %admins $iif($readini(Admins.ini,$ini(Admins.ini,%x),Logged),3,4) $+ $ini(Admins.ini,%x) | if ($readini(Admins.ini,$ini(Admins.ini,%x),Logged)) inc %y | inc %x } | return Admins are ( $+ $iif(%y == 0,14,03) $+ %y $+ %Color1 $+ / $+ $ini(Admins.ini,0) $+ ) $replacE(%admins,$chr(32),$+(%Color1,$chr(44),$chr(32))) }
  153. }
  154. alias Ctl /msg $1 %color1 %Color4 $+ $2- %color2
  155. alias bingoregs {
  156. unset %timer
  157. var %x 1,%k 1,%t
  158. while (%x <= $lines(bingoregs.txt)) {
  159. var %t = %t $gettok($read(bingoregs.txt,%x),1,32) | inc %x | inc %k
  160. if (%k == 15) { inc %timer | .timer 1 $calc(%timer *2) msg %b.chan %color1 $iif(%timer == 1,Lottery regs ( $+ $Lines(bingoregs.txt) $+ / $+ %b.users $+ ): $+ $chr(32)) $+ $replace(%t,$chr(32),$+($chr(44),$chr(32))) %color2 | var %k $null,%t $null }
  161. }
  162. if (!$read(bingoregs.txt)) { msg %b.chan %color1 There are no registered users ( $+ $Lines(bingoregs.txt) $+ / $+ %b.users $+ ) %color2 }
  163. elseif ($calc($lines(bingoregs.txt) - %x) < 15) { inc %timer | .timer 1 $calc(%timer *2) msg %b.chan %color1 $iif(%timer == 1,Lottery regs ( $+ $Lines(bingoregs.txt) $+ / $+ %b.users $+ ): $+ $chr(32)) $+ $replace(%t,$chr(32),$+($chr(44),$chr(32))) %color2 }
  164. inc $(-u $+ $calc(%timer *2 +5)) %flood
  165. unset %timer
  166. }
  167. alias endbingo {
  168. .remove lastregs.txt
  169. ;lo mahur
  170. mode %b.chan +m
  171. .timer 1 10 mode %b.chan -m
  172. if (%bingo.rand == OFF) {
  173. set %b.winner $gettok($read(bingoregs.txt),1,32)
  174. .timer 1 1 msg %b.chan %color1 Lotterybot is now mixing the %color3 $+ registers %color4 $+ please wait %color2
  175. .timer 1 2 msg %b.chan %color1 I`m choose the %color3 $+ winner $+ %color4 please waiting 2secs.. %color2
  176. .timer 1 4 msg %b.chan %color1 And the %color3 $+ winner $+ %color4 is ... %color2
  177. .timer 1 5 msg %b.chan %color1 And the %color3 $+ winner $+ %color4 is ... %color2
  178. .timer 1 6 msg %b.chan %color1 The winner is: %color3 $+ %b.winner $+ %color4 $+ , send now message to %color3 $+ %b.admin $+ %color4 to get your prize: %color3 $+ %b.prize $+ %color4 $+ . %color2
  179. .timer 1 7 /notice %b.admin %color1 %color3 $+ System msg: $+ %color4 for do newwiner %color3 $+ %b.sign $+ %color4 $+ newwiner tpye: /msg $me %color3 $+ %b.sign $+ %color4 $+ newwiner %color2
  180. }
  181. ;mahur
  182. if (%bingo.rand == ON) {
  183. .timer 1 1 msg %b.chan %color1 Lotterybot now mixing the %color3 $+ registers %color4 $+ please wait %color2
  184. .timer 1 2 msg %b.chan %color1 I`m choose the winner please waiting 2secs.. %color2
  185. .timer 1 4 msg %b.chan %color1 And the winner is ... %color2
  186. .timer 1 5 msg %b.chan %color1 And the winenr is ... %color2
  187. .timer 1 6 msg %b.chan %color1 The winner is: %color3 $+ %b.winner $+ %color4 $+ , send now message to %color3 $+ %b.admin $+ %color4 to get your prize: %color3 $+ %b.prize $+ %color4 $+ . %color2
  188. .timer 1 7 /notice %b.admin %color1 %color3 $+ System msg: $+ %color4 for do newwiner %color3 $+ %b.sign $+ %color4 $+ newwiner tpye: /msg $me %color3 $+ %b.sign $+ %color4 $+ newwiner %color2
  189. }
  190. timer 1 8 mode %b.chan +v %b.winner
  191. timer 1 8 msg %b.winner //echo -a %color1 Hello %b.winner $+ , You are won in %color3 $+ %b.chan %color4 $+ lottery send message to %color3 $+ %b.admin %color4 $+ to get you are prize %color2
  192. set -u7 %flood on
  193. .copy -o bingoregs.txt lastregs.txt
  194. .remove bingoregs.txt
  195. .timer 1 420 .remove lastregs.txt | timer 1 421 set %n.win OFF
  196. off
  197. }
  198.  
  199. alias newwiner {
  200. if (%n.win == OFF) { msg $nick %color1 Over the time for newwiner %color2 }
  201. if (%bingo.rand == OFF) {
  202. if (%n.win == ON) {
  203. timer 1 1 set %b.winner $gettok($read(lastregs.txt),1,32)
  204. timer 1 2 /mode %b.chan +m
  205. timer 1 3 msg %b.chan %color1 I choose a new winner right now. please waiting 2secs.. %color2
  206. timer 1 4 msg %b.chan %color1 Please wait 1sec. %color2
  207. timer 1 5 msg %b.chan %color1 The new winner is: %color3 $+ %b.winner $+ $+ %color4 $+ , send now message to %color3 $+ %b.admin $+ %color4 to get your prize: %color3 $+ %b.prize $+ %color4 $+ . %color2
  208. timer 1 6 /mode %b.chan +v %b.winner
  209. }
  210. }
  211. if (%bingo.rand == ON) {
  212. timer 1 1 msg %b.chan %color1 I choose a new winner right now. please waiting 2secs.. %color2
  213. timer 1 2 msg %b.chan %color1 Please wait 1sec. %color2
  214. timer 1 3 msg %b.chan %color1 The new winner is: %color3 $+ %b.winner $+ $+ %color4 $+ , send now message to %color3 $+ %b.admin $+ %color4 to get your prize: %color3 $+ %b.prize $+ %color4 $+ . %color2
  215. timer 1 4 /mode %b.chan +v %b.winner
  216. }
  217. timer 1 7 /mode %b.chan -m
  218. timer 1 120 set %n.win OFF
  219. }
  220. alias startbingo {
  221. writeini settings.ini Lottery Number $calc($readini(Settings.ini,Lottery,Number) +1) | unset %b.ttag | set %bingo.status ON | set %regs | set %b.winner | writeini settings.ini At Date-time $time $date
  222. timer 1 1 mode %b.chan +m
  223. timer 1 3 msg %b.chan %color1 The lottery number < $+ %color3 $+  $+ $readini(Settings.ini,Lottery,Number) $+  $+ %color4 $+ > has been started at: %color3 $+  $+ $readini(Settings.ini,At,Date-time) $+  %color2
  224. timer 1 5 msg %b.chan %color1 %color3 $+ Details lottery: %color4 $+ admin: %color3 $+  $+ %b.admin $+  $+ %color4 prize: %color3 $+  $+ %b.prize $+  $+ %color4 users: %color3 $+  $+ %b.users $+  $+ %color4 sign: %color3 $+  $+ %b.sign $+  $+ %color4 %color2
  225. timer 1 7 msg %b.chan %color1 Commands: %color3 $+ %b.sign $+ %color4 $+ Reg %color3 $+ %b.sign $+ %color4 $+ Del %color3 $+ %b.sign $+ %color4 $+ Regs %color2
  226. timer 1 9 msg %b.chan %color1 The register started in more %color3 $+ (3 secs...) $+ %color4 $+ , ready for -m %color2
  227. timer 1 12 mode %b.chan -m
  228. }
  229. alias startbingo-pm {
  230. if (%bingo.run == 0) {
  231. msg $nick %color1 4,1Error0: are you not settings lottery status commands: !StatusBot 1 = Statusbot ON! %color2
  232. }
  233. if ($numtok(%b.users,32) == 0) {
  234. msg $nick %color1 4,1Error0: are you not setting users commands: !set-users <users> example: !set-users 35 %color2
  235. }
  236. if (%bingo.status == ON) {
  237. msg $nick %color1 Lottery is right now running in channel: %b.chan %color2
  238. }
  239. if ($numtok(%b.prize,32) == 0) {
  240. msg $nick %color1 4,1Error0: are you not setting prize please set, commands: !set-prize <prize> exmaple: !set-prize VENT
  241. }
  242. if ($numtok(%b.admin,32) == 0) {
  243. msg $nick %color1 4,1Error0: are you not setting admin please set, commands: !set-admin <admin> exmaple: !set-admin Xronic %color2
  244. }
  245. if (%bingo.rand == ON) {
  246. if ($numtok(%b.winner,32) == 0) {
  247. msg $nick %color1 4,1Error0: are you not setting winner please set, commands: !set-winner <winner> exmaple: !set-winner Xronic %color2
  248. }
  249. }
  250. ;Lo mahur
  251. if (%bingo.run == 1) {
  252. if (%bingo.rand == OFF) {
  253. msg $nick %color1 $nick $+ ,are you succesfully started lottery in channel: %b.chan %color2
  254. writeini settings.ini Lottery Number $calc($readini(Settings.ini,Lottery,Number) +1) | unset %b.ttag | echo -a done! 1 | set %bingo.status ON | set %regs | set %b.winner | echo -a done! 2 | writeini settings.ini At Date-time $time $date
  255. timer 1 1 mode %b.chan +m
  256. timer 1 3 msg %b.chan %color1 The lottery number < $+ %color3 $+  $+ $readini(Settings.ini,Lottery,Number) $+  $+ %color4 $+ > has been started at: %color3 $+  $+ $readini(Settings.ini,At,Date-time) $+  %color2
  257. timer 1 5 msg %b.chan %color1 %color3 $+ Details lottery: %color4 $+ admin: %color3 $+  $+ %b.admin $+  $+ %color4 prize: %color3 $+  $+ %b.prize $+  $+ %color4 users: %color3 $+  $+ %b.users $+  $+ %color4 sign: %color3 $+  $+ %b.sign $+  $+ %color4 %color2
  258. timer 1 7 msg %b.chan %color1 Commands: %color3 $+ %b.sign $+ %color4 $+ Reg %color3 $+ %b.sign $+ %color4 $+ Del %color3 $+ %b.sign $+ %color4 $+ Regs %color2
  259. timer 1 9 msg %b.chan %color1 The register started in more %color3 $+ (3 secs...) $+ %color4 $+ , ready for -m %color2
  260. timer 1 12 mode %b.chan -m
  261. }
  262. }
  263. ;Mahur
  264. if (%bingo.run == 1) {
  265. if (%bingo.rand == ON) {
  266. msg $nick %color1 $nick $+ ,are you succesfully started lottery in channel: %b.chan %color2
  267. writeini settings.ini Lottery Number $calc($readini(Settings.ini,Lottery,Number) +1) | unset %b.ttag | set %bingo.status ON | set %regs | writeini settings.ini At Date-time $time $date
  268. timer 1 1 mode %b.chan +m
  269. timer 1 3 msg %b.chan %color1 The lottery number < $+ %color3 $+  $+ $readini(Settings.ini,Lottery,Number) $+  $+ %color4 $+ > has been started at: %color3 $+  $+ $readini(Settings.ini,At,Date-time) $+  %color2
  270. timer 1 5 msg %b.chan %color1 %color3 $+ Details lottery: %color4 $+ admin: %color3 $+  $+ %b.admin $+  $+ %color4 prize: %color3 $+  $+ %b.prize $+  $+ %color4 users: %color3 $+  $+ %b.users $+  $+ %color4 sign: %color3 $+  $+ %b.sign $+  $+ %color4 %color2
  271. timer 1 7 msg %b.chan %color1 Commands: %color3 $+ %b.sign $+ %color4 $+ Reg %color3 $+ %b.sign $+ %color4 $+ Del %color3 $+ %b.sign $+ %color4 $+ Regs %color2
  272. timer 1 9 msg %b.chan %color1 The register started in more %color3 $+ (3 secs...) $+ %color4 $+ , ready for -m %color2
  273. timer 1 12 mode %b.chan -m
  274. }
  275. }
  276. }
  277. alias notbingo {
  278. if (%bingo.status == ON) && (!%flood) {
  279. mode %b.chan -m
  280. /OFF
  281. msg %b.chan %color1 The lottery has been finished by ( $+  $+ $nick $+  $+ ) %color2
  282. msg $nick %color1 The lottery succesfully finished by ( $+  $+ $nick $+  $+ ) %color2
  283. }
  284. }
  285. alias OFF {
  286. unset %bingo.status | set %bingo.status OFF | unset %b.winner | set %bingo.run 0 | set %b.tagg 0 | set %bingo.rand OFF
  287. if ($numbok(%b.tag,32) == 0) { set %b.tagg 0 }
  288. if ($numtok(%b.tag,32) isnum 1-100 $+ ) { set %b.tagg 1 }
  289. }
  290. dialog LottetySettings {
  291. title "Lotterybot settings"
  292. size -1 -1 117 155
  293. option dbu
  294. text "Set channel:", 1, 6 8 36 10
  295. edit "", 2, 45 8 69 11
  296. edit "", 3, 45 23 69 11
  297. text "Set sign (!):", 4, 6 23 36 10
  298. text "Admin bigno:", 5, 6 38 36 10
  299. edit "", 6, 45 39 69 11
  300. text "Prize bigno:", 7, 5 53 36 10
  301. edit "", 8, 45 53 69 11
  302. text "Users bigno:", 9, 5 68 36 10
  303. edit "", 10, 45 68 69 11
  304. text "Blocktag:", 11, 5 82 36 10
  305. edit "", 12, 45 82 69 11
  306. button "Start lottery", 13, 21 112 79 12
  307. button "Stop lottery", 14, 20 126 79 12
  308. text "No randonmally (mahur):", 15, 5 96 70 10
  309. button "Yes", 16, 78 95 16 12
  310. button "No", 17, 97 95 16 12
  311. button "New winner", 18, 20 140 79 12
  312. }
  313. on *:dialog:LottetySettings:*:*: {
  314. if ($devent == sclick) {
  315. if ($did == 13) { set %b.chan $did(2) | set %b.sign $did(3) | set %b.admin $did(6) | set %b.prize $did(8) | set %b.users $did(10) | set %b.tag $did(12) | set %B.tagg $input(Set b.tagg,e,write 1 == ON/2 == OFF) | echo -a %color1 Lottery settings finished. %color2 | timer 1 3 /startbingo }
  316. if ($did == 14) { notbingo }
  317. if ($did == 16) { set %bingo.rand ON | set %b.winner $input(Winner,e,Winner?) | echo -a %color1 Lottery Mahur $+ , Winner: %b.winner %color2 }
  318. if ($did == 17) { set %bingo.rand OFF | echo -a %color1 Lottery lo mahur %color2 }
  319. if ($did == 18) { newwiner | echo -a %color1 Newwiner run %color2 }
  320. }
  321. }
  322. alias LS { dialog -m LottetySettings LottetySettings }
  323. dialog style {
  324. title "Styles"
  325. size -1 -1 117 131
  326. option dbu
  327. text "Color 1 (Main): ", 1, 3 15 41 10
  328. text "Color 2 (Alt): ", 2, 3 28 41 10
  329. edit "", 3, 48 15 65 11
  330. text "Color 3 (Regullary): ", 5, 4 44 48 10
  331. edit "", 6, 57 44 56 11
  332. text "Color 4 (Regullary): ", 7, 4 59 48 10
  333. edit "", 8, 57 58 57 11
  334. text " Bot styles: ", 9, 31 90 44 10
  335. text " You styles: ", 10, 27 2 44 10
  336. button "Green and black", 11, 31 103 44 12
  337. button "Blue and black", 12, 31 116 44 12
  338. button "Save Colors", 13, 34 72 37 12
  339. edit "", 4, 49 28 64 11
  340. }
  341. alias sy { dialog -m style style }
  342. on *:dialog:style:*:*: {
  343. if ($devent == sclick) {
  344. if ($did == 13) { set %color1 $did(3) | set %color2 $did(4) | set %color3 $did(6) | set %color4 $did(8) | echo -a color1: %color1 color2 %color2 color3 %color3 $+ Xronic 1color4 %color4 $+ Xronic }
  345. if ($did == 11) { Set %color1 0,1[9«0 | set %color2 9,1»0] | set %color3 9 | set %color4 0 | echo -a %color1 Done! %color2 }
  346. if ($did == 12) { set %color1 0,1[11«0 | set %color2 11»0] | set %color3 11 | set %color4 0 | echo -a %color1 Done! %color2 }
  347. }
  348. }
  349. Menu * {
  350. Xronic lotterybot version 1.3
  351. .Lottery Settings { /LS }
  352. .Admins system
  353. ..Set Botpass: var %p = $?=\"Type botpass" | $iif(%p,set %Botpass %p,echo -a Error: Type botpass)
  354. ..Clear Admins: .remove Admins.ini
  355. ..Open admins file: $iif($exists(Admins.ini),run Admins.ini,echo -a There are no admins.)
  356. .Styles { /sy }
  357. .אודות {
  358. window -e @אודות
  359. echo @אודות %color1 ברוכים הבאים לגרסא החדשה 1.3 %color2
  360. echo @אודות %color1 !login User Pass מה שעודכן בבוט,מערכת אדמינים ע"י התחברות לבוט %color2
  361. echo @אודות %color1 נוספו דיאלוגים חדשים וידותיים יותר %color2
  362. echo @אודות %color1 תודה מיוחדת לעוזרים בבוט: Vendetta` %color2
  363. }
  364. .Help {
  365. window -e @Help
  366. echo @help %color1 Add Admin: /msg $me !add admin <BotPass> <Nick> <Pass> %color2
  367. echo @Help %color1 Del Admin: /msg $me !del admin <BotPass <Nick> %color2
  368. echo @Help %color1 Login bot: /msg $me !login <Nick> <Pass> %color2
  369. echo @Help %color1 All Commands: /msg $me !Commands/!Help when you logged to bot %color2
  370. echo @Help %color1 Lottery Settings do: /LS %color2
  371. echo @Help %color1 Lottery Style do: /sy %color2
  372. }
  373. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement