Vice City Multiplayer

VC:MP 0.3 => mIRC/pawn Scripting => Topic started by: Force on July 01, 2008, 05:22:13 pm

Title: [RESOLVED]Snipers Mini - Game
Post by: Force on July 01, 2008, 05:22:13 pm
Hi,

I am making a Snipers Mini - Game (M60's for now :P) with Windlord for Sansan. I have got this code to sort the round but I don't know how I am going to restore everyone's control's when the !go command is typed :(. Here is the code, if you are able to help it would be appreciated :)

Code: [Select]
    elseif ($2 == !go) {
      if ($hget(SnipeHashTable,$vcmp.hgetname($1)) != Sniping) { vcmp.adminmsg %id You are not participating! }
      elseif ($hget(GoHashTable,Go) != Standby) { vcmp.adminmsg %id You can't start yet! Other paricipants may want to join! }
      else {
        timer 1 1 vcmp.gametext.all vcmp.doforall - 3 -
        timer 1 2 vcmp.gametext.all vcmp.doforall - 2 -
        timer 1 3 vcmp.gametext.all vcmp.doforall - 1 -
        timer 1 4 vcmp.gametext.all vcmp.doforall Fight!
        timer 1 5 vcmp.setcon vcmp.doforall 1
      }
    }

the vcmp.setcon vcmp.doforall was something I added in as a test to try and do it, but it failed. Ideally I would like it to loop round the SnipeHashTable and restore all controls to ppl that are on there..

Any ideas?

Cheers,
Title: Re: Snipers Mini - Game
Post by: Force on July 01, 2008, 05:41:29 pm
Resolved the issue, all I had to do was make an alias:

Code: [Select]
alias vcmp.setcon.all vcmp.doforall vcmp.setcon $$1 $$2-


And it was sorted :)