• Welcome to Vice City Multiplayer.
 

WSV License ...

Started by Punjabi, October 04, 2008, 02:01:40 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Punjabi

Not working even license or Vehicleenter..

elseif ($3 == getlicense) {
  if (Sunshine isin $WSV.loco($2)) {
    if ($WSV.money($1) >= 2000) {
      hdec WSV.money $WSV.name($2) 2000
      WSV.setcash $2 $WSV.money($2)
      set %license. [ $+ [ $WSV.name($2) ] ] Yes
      WSV.msg $2 You can now drive vehicles...
      WSV.announce $2 ~o~Got a License!
    }
    else WSV.msg $2 You need at least [2000] to buy your license..
  }
  else WSV.msg $2 You need to be at Sunshine Autos!
}


on *:SIGNAL:WSV.vehicleenter: {
  var %car = $hget(WSV.Config.Cars,$3) ( $+ $3 $+ )
  if ([ %license. [ $+ [ $WSV.name($2) ] ] ]) {
    WSV.msg $2 You do not have a license!
    .timer 1 3 WSV.setlocation $2 $WSV.location($2)
  }
  elseif ($5 == 18) WSV.msg $2 You have started to drive a %car $+ .
  elseif ($5 == 17) {
    var %a = 0
    while (%a <= %maxplayers) {
      if ($WSV.vehicle(%a) == $3) && ($WSV.vehicle(%a) != 0) && (%a != $2) var %b = $WSV.getname(%a)
      inc %a
    }
    WSV.msg $2 You got onto %b $+ ' $+ s %car $+ .
    set % [ $+ [ passenger $+ . $+ [ $WSV.getname($2) ] ] ] $3
  }
}


Cya
Punjabi_goli
GOD BLESS ALL..<<Founder of PUN Clan.....Born to fight and Kill..>>

Windlord

elseif ($3 == getlicense) {
  if (Sunshine isin $WSV.loco($2)) {
    if ($WSV.money($2) >= 2000) {
      hdec WSV.money $WSV.name($2) 2000
      WSV.setcash $2 $WSV.money($2)
      set %license. [ $+ [ $WSV.name($2) ] ] Yes
      WSV.msg $2 You can now drive vehicles...
      WSV.announce $2 ~o~Got a License!
    }
    else WSV.msg $2 You need at least [2000] to buy your license..
  }
  else WSV.msg $2 You need to be at Sunshine Autos!
}


on *:SIGNAL:WSV.vehicleenter: {
  var %car = $hget(WSV.Config.Cars,$3) ( $+ $3 $+ )
  if (! [ $+ [ %license. [ $+ [ $WSV.name($2) ] ] ] ]) {
    WSV.msg $2 You do not have a license!
    .timer 1 3 WSV.setlocation $2 $WSV.location($2)
  }
  elseif ($5 == 18) WSV.msg $2 You have started to drive a %car $+ .
  elseif ($5 == 17) {
    var %a = 0
    while (%a <= %maxplayers) {
      if ($WSV.vehicle(%a) == $3) && ($WSV.vehicle(%a) != 0) && (%a != $2) var %b = $WSV.getname(%a)
      inc %a
    }
    WSV.msg $2 You got onto %b $+ ' $+ s %car $+ .
    set % [ $+ [ passenger $+ . $+ [ $WSV.getname($2) ] ] ] $3
  }
}

Punjabi

Great it works but problem arises even i get license i cant able to sit in car......
any problem?? :-[
GOD BLESS ALL..<<Founder of PUN Clan.....Born to fight and Kill..>>