Advertisement
intersys

Untitled

Aug 15th, 2014
349
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
mIRC 3.51 KB | None | 0 0
  1. on *:text:*:#: {
  2.   if ($1 == !findmix) {
  3.     if ($2 !isnum 2-5) { msg $stl($chan $nick The number players must be move between 2-5.) }
  4.     elseif ($isinmix($nick)) { msg $chan $stl(You already in mix-room $+ $chr(44) for exit please part from the mix-room you are in it $+ $chr(46)) }
  5.     else { fx $2 }
  6.   }
  7.   elseif ($1 == !votekick) && ($isinmix($nick)) {
  8.     msg $chan $stl($nick Turn on votekick for $2 $+ $chr(44) to kick this user type !Yes $+ $chr(44) to kick this player type !No $+ $chr(44) you have 30 seconds to vote!)
  9.     set -u30 %votekick [ $+ [ $isinmix($nick) ] ] on
  10.     .timer $+ %votekick [ $+ [ $isinmix($nick) ] ]  1 30 Votekick $isinmix($nick) $address($2,2)
  11.   }
  12.   elseif ($1 == !Yes) && (%votekick [ $+ [ $isinmix($nick) ] ] == on) { inc %vote.yes [ $+ [ $isinmix($nick) ] ]  }
  13.   elseif ($1 == !No) && (%votekick [ $+ [ $isinmix($nick) ] ] == on) { inc %vote.no [ $+ [ $isinmix($nick) ] ]  }
  14. }
  15.  
  16.  
  17. on !*:join:#: {
  18.   if ($isinmix($nick)) { .timer $+ $nick [ $+ [ 2 ] ] off }
  19. }
  20. on !*:part:#: {
  21.   if ($isinmix($nick)) { writeini -n mixs.ini $isinmix($nick) players $remtok($readini(mixs.ini,$isinmix($nick),players),$nick,44) }
  22. }
  23.  
  24. ;;;;Aliaes;;;;
  25.  
  26. alias stl return 15»07»10» $1- 10«07«15«
  27. alias isinmix { var %x = 1 | while ($ini(mixs.ini,%x)) { if ($istok($readini(mixs.ini,$ifmatch,players),$1,44)) { return $ini(mixs.ini,%x) } | inc %x } }
  28. alias votekick {
  29.   if (%vote.yes [ $+ [ $2 ] ] > %vote.no [ $+ [ $2 ] ]) {
  30.     msg $2 $stl(The votekick is over! the results is: No: %vote.no [ $+ [ $2 ] ] - Yes: %vote.yes [ $+ [ $2 ] ])
  31.   kick $2 $3 You kicked by votekick ( $+ %vote.yes [ $+ [ $2 ] ] $+ / %vote.no [ $+ [ $2 ] ] $+ ) }
  32.   unset %vote.yes [ $+ [ $2 ] ] %vote.no [ $+ [ $2 ] ] %votekick [ $+ [ $2 ] ]
  33. }
  34. alias test {
  35.   var %x = 1, %file = mixs.ini
  36.   while ($ini(mixs.ini,%x)) {
  37.     var %topic = $v1
  38.     if ($readini(%file,%topic,numplayers) > $numtok($readini(%file,%topic,players),44)) && ($readini(%file,%topic,numplayers) == $1) {
  39.       return %topic
  40.     }
  41.     inc %x
  42.   }
  43. }
  44. alias fx {
  45.   if ($ini(mixs.ini) <= 19) { msg %Mainchannel $stl(The maximum channels is over $+ $chr(44) please wait to some channel available $+ $chr(46)) }
  46.   if (!$test($1)) && ($ini(mixs.ini) >= 19) {
  47.     var %num = $rand(100,999), %chans = $+(#mix,%num)
  48.     msg $chan $stl(We dont have a free room, please wait a few seconds we create for you new room.)
  49.     ChannelTest %chans $iif(%channel.user,%channel.user,$nick) $1
  50.     writeini -n Mixs.ini %chans NumPlayers $1
  51.     .timer $+ $iif(%channel.user,%channel.user,$nick) 1 5 invite $iif(%channel.user,%channel.user,$nick) %chans
  52.     msg $iif(%channel.user,%channel.user,$nick) $stl(You invited to %chans $+ $chr(44) you have 20 seconds to get in!)
  53.     writeini mixs.ini %chans players $addtok($readini(mixs.ini,%chans,players),$iif(%channel.user,%channel.user,$nick),44)
  54.   }
  55.   else {
  56.     invite $nick $test($1)
  57.     msg $nick $stl(You invited to $test($1) $+ $chr(44) you have 20 seconds to get in!)
  58.     writeini mixs.ini $test($1) players $addtok($readini(mixs.ini,$test($1),players),$nick,44)
  59.     .timer $+ $nick [ $+ [ 2 ] ] 1 20 writeini -n mixs.ini $isinmix($nick) players $remtok($readini(mixs.ini,$isinmix($nick),players),$nick,44)
  60.   }
  61. }
  62. alias ChannelTest {
  63.   join $1 | who $1
  64.   set %channel.test on
  65.   set %channel.users $1
  66.   set %channel.user $2
  67.   set %channel.num $3
  68. }
  69. raw 366:*: {
  70.   if (%channel.test == on) {
  71.     if ($nick(%channel.users,0) < 1) { remini Mixs.ini %channel.users | fx %channel.num | unset %channel.* | .timer $+ $2 off }
  72.     else { mode %channel.users +isl 6 | unset %channel.* }
  73.   }
  74. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement