Jump to content

GUS wins ?


Danboi

Recommended Posts

how can i edit so the wins will work? because you only win if the last player goes in the water why is that ???

alias mta.end { 
  if (%cplayers == 1) { 
    var %a = 0 
    while (%a < $mta.server($1).cmax) { 
      if (!$mta.dead($1,%a)) { 
        mta.text $1 $mta.nick($1,%a) is winner! 
        mta.freeze $1 %a 
!writeini -n " $+ $scriptdir $+ stats.ini" WINS $mta.nick($1,%a) $gus.add($gus.wins($1,%a),1) 
        !halt 
      } 
      !inc %a 
    } 
  } 
} 
on *:SIGNAL:mta.startrace: { 
  set %cplayers $mta.server($1).players 
} 
on *:SIGNAL:mta.part: { 
  if (!$mta.dead($1,$2) set %cplayers $calc(%cplayers - 1) 
  mta.end $1 $2 
} 
on *:SIGNAL:mta.death: { 
  set %cplayers $calc(%cplayers - 1) 
  mta.end $1 $2 
} 
on *:SIGNAL:mta.connect: { 
  set %cplayers 0 
} 

Link to comment

alias mta.end { 
  if (%cplayers == 1) { 
    var %a = 0 
    while (%a < $mta.server($1).cmax) { 
      if (!$mta.dead($1,%a)) { 
        mta.text $1 $mta.nick($1,%a) is winner! 
!writeini -n " $+ $scriptdir $+ stats.ini" WINS $mta.nick($1,%a) $gus.add($gus.wins($1,%a),1) 
        !.timer 1 5 mta.freeze $1 %a 
        !halt 
      } 
      !inc %a 
    } 
  } 
} 
} 
on *:SIGNAL:mta.startrace: { 
  set %cplayers $mta.server($1).players 
} 
on *:SIGNAL:mta.part: { 
  if (!$mta.dead($1,$2) set %cplayers $calc(%cplayers - 1) 
  mta.end $1 $2 
} 
on *:SIGNAL:mta.death: { 
  set %cplayers $calc(%cplayers - 1) 
  mta.end $1 $2 
} 
on *:SIGNAL:mta.connect: { 
  set %cplayers 0 
} 

Add this script to inside GUS

Link to comment

on *:SIGNAL:mta.part: { 
  if (!$mta.dead($1,$2) set %cplayers $calc(%cplayers - 1) 
  mta.end $1 $2 
} 

Correct me if I'm wrong but is there not a bracket mismatch on line 2 of that piece of code?

I would of thought it'd be:

on *:SIGNAL:mta.part: { 
  if ($mta.dead($1,$2)) set %cplayers $calc(%cplayers - 1) 
  mta.end $1 $2 
} 

Link to comment
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...