עמוד ראשי מירק סקריפטינג תוספים Mix Bot - בוט קובע קבוצות

Mix Bot - בוט קובע קבוצות

mIRC Addons - בפורום זה יפורסמו תוספים למירק שנועדו לשימוש יומיומי ולהרחבת המירק בפונקציות חדשות אשר לא מובנות. לפרסום תוספים יש לפרסמם תחילה בפורום "פרסום קודים ומדריכים" ולאחר מכאן הם יועברו לפורום זה.

הצטרף: 13 אוגוסט 2010, 12:44
הודעות: 41
פורסם: 13 אוקטובר 2012, 12:23
שם הקוד: Mix Bot
יוצר: Sw1ft
גרסה: 0.2
תיאור: Mix Bot, תפקידו לקבוע רנדומלי את השחקנים בקבוצות.
הפעלה: כנסו למירק ולחצו במקלדת ALT + R, לחצו למעלה בצד שמאל File ואז New, תעתיקו את הסקריפט ותאשרו.
; Mix Bot v0.2 By Sw1ft
; Date: 24/05/05
; Copright(c) @ #UK.Mix
 
;;Commands
;;$start
;;$stop
;;$access owner/remove/give
 
;; owner = owner
;;give = mix admin
;;remove == remove there admin/owner
 
;; HF !
 
 
 
on 1:LOAD:{
  set %mix.channel $$?=\"Enter you Mix Channel"
  set %mix.Server $$?=\"Enter Mix Server IP"
  set %owner $$?=\"Enter Owners Nick"
  writeini owner.ini %mix.channel $address(%owner,1) owner
  unset %team
  unset %mix.count
  set %mix.map None
  set %mix.server None
  set %mix.players 5
}
 
on 1:TEXT:$($!access*):%mix.channel:{
  if ($readini(owner.ini,%mix.channel,$address($nick,1) == owner)) {
    if ($2 == Give) {
      writeini mix-admins.ini $chan $address($3,1) admin
      msg # Done.
      mode $chan +v $3
      notice $3 You Are now A Mix Admin
      halt
    }
    if ($2 == remove) {
      remini mix-admins.ini %mix.channel $address($3,1)
      msg # done.
      mode $chan -v $3
      notice $3 You Are no Longer A Mix Admin.
      halt
    }
    if ($2 == owner) {
      writeini owner.ini %mix.channel $address($nick,1) owner
      mode $chan +o $3
      msg # done.
      notice $3 you Are Now A Mix Admin !
      halt
    }
  }
}
 
 
 
 
on 1:JOIN:%mix.channel:{
  if ($readini(mix-admins.ini,$chan,$address($nick,1) == admin)) {
   mode $chan +v $nick
    msg # [- $nick Is A Mix Admin. -]
  }
}
 
on 1:TEXT:$($!Start):%mix.channel:{
  if ($readini(mix-admins.ini,$chan,$address($nick,1) == admin)) {
    if (%mix == on) { notice $nick Mix Allready Active $nick $+ .
    }
    else {
      amsg [- Mix Has Started @ $chan , Type !add To Play! -]
      inc %mix.total
      set %mix on
      set %mix.admin $nick
      topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
      notice $nick [- Setup commands: $chr(36) $+ map < Map> ][ $chr(36) $+ game <Game Type> ][ $chr(36) $+ Stop To Stop The Mix! -]
      notice $nick /msg $me password <password>
      notice $nick [- Commands To Be done In Channel! -]
      halt
    }
  }
}
on 1:TEXT:$($!map*):%mix.channel:{
  if ($nick == %mix.admin) {
    set %mix.map $2
    topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    notice $nick Map Is Set To $2
    halt
  }
}
 
on 1:TEXT:$($!game*):%mix.channel:{
  if ($nick == %mix.admin) {
    set %mix.game $2
    topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    notice $nick Game Type Is Set To $2
    halt
  }
}
 
on 1:TEXT:$($!stop):%mix.channel:{
  if ($readini(owner.ini,%mix.channel,$address($nick,1) == owner)) {
    if ($nick == %mix.admin) {
      dec %mix.total
      topic $chan 7[- Welcome To %mix.channel 7][ Supported By #United-Kingdom 7][ Total Mixes: %mix.total 7][ News: %news -7]
      set %mix.map None
     unset %mix.count
     unset %team
     unset %mix.admin
     set %mix off
      set %team
      set %mix.game 0
      set %mix.map 0 
      set %password 0
      notice $nick Mix Has Been Stopped.
      halt
    }
  }
}
on *:text:!add*:%mix.channel:{
  if (%mix != on) { halt
  }
  else {
    inc %mix.count
    if ($istok(%team, $nick, 32)) { notice $nick You're already In The Mix.
      return
    }
    else {   
      if (%mix.count == %mix.players) {
        mode %mix.channel +m
        topic %mix.channel 7[- Welcome To %mix.channel 7][ Supported By #United-Kingdom 7][ Total Mixes: %mix.total 7][ News: %news -7]
        getip
        msg %mix.channel [- Supported By: #United-Kingdom ][ Sponsored By: you? and You? -]
        msg %mix.channel [- If you didnt get pass contact the admin: %mix.admin -]
        set %mix off
        set %team
        set %mix.game 0
        set %mix.map 0 
        set %password 0
        unset %mix.admin
        mode %mix.channel -m
      }
      else {
        set %team $addtok(%team, $nick, 32)
        topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
        halt
      }
    }
  }
}
on 1:TEXT:!remove:%mix.channel:{
  if ($istok(%team, $nick, 32)) {
    dec %mix.count
    set %team $remtok(%team, $nick, 32)
    topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    notice $nick Done.
    halt
  }
  else { notice $nick You Are Not In The Team.
  }
}
 
on 1:TEXT:!mixes:%mix.channel:{
  msg # Total Mixes: %mix.total
}
 
on 1:TEXT:!team:%mix.channel:{
  if (%mix) {
    msg $chan Current Mix Team: %team
    halt
  }
  else { halt
  }
}
 
alias getip {
  var %d = 1
  while (%d <= $numtok(%team,32)) {
    msg $gettok(%team, %d, 32) [- Mix Has Now Started ][Server: %mix.server ][IP: %password ][ If There Is No Details Here, Please Conatct: %mix.admin ][ Please Join Server Now, Thx ]
    inc %d
  }
}
on 1:TEXT:password*:?:{
  if ($readini(owner.ini,%mix.channel,$address($nick,1) == OWNER)) {
    if ($readini(mix-admins.ini,$chan,$address($nick,1) == admin)) {
      if ($nick isop %mix.channel) {
        set %password $2
        notice $nick Password Has Been Set.
      }
    }
  }
}
 
on 1:TEXT:$($!news*):%mix.channel:{
  if ($readini(owner.ini,%mix.channel,$address($nick,1) == OWNER)) {
    if (%mix == on) {
      /set %news $2-
      /topic %mix.channel 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
      halt
    }
    elseif (%mix == off) {
      /set %news $2-
      /topic %mix.channel 7[- Welcome To %mix.channel 7][ Supported By #United-Kingdom 7][ Total Mixes: %mix.total 7][ News: %news -7]
    }
  }
}
 
 
on 1:PART:%mix.channel:{
  if ($istok(%team, $nick, 32)) {
    /set %team $remtok(%team, $nick, 32)
    /topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    halt
  }
}
 
on 1:KICK:%mix.channel:{
  if ($istok(%team, $nick, 32)) {
    /set %team $remtok(%team, $nick, 32)
   / topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    halt
  }
}
 
 
on 1:BAN:%mix.channel:{
  if ($istok(%team, $nick, 32)) {
    /set %team $remtok(%team, $nick, 32)
    /topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    halt
  }
}
 
on 1:QUIT:{
  if ($istok(%team, $nick, 32)) {
    /set %team $remtok(%team, $nick, 32)
    /topic $chan 7[- Mix Sarted 7][ !add 7/ !remove 7][ Map: %mix.map 7][ Game Type: %mix.game 7][ Team: %team 7][ Total Mixes: %mix.total -7]
    halt
  }
}
 

יש למצוא גם: pastebin.php?mode=view&s=26
Main Editor
Server: irc.quakanet.org - Channel: #mIRCs
Automatically connect: irc://irc.quakenet.org/mIRCs

חזור אל תוספים

cron