• Welcome to Vice City Multiplayer.
 

Gus (Markers)

Started by Amenine, December 19, 2008, 08:08:06 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Amenine

Hya Guys,

I have a question..
How can i set markers in GUS script..
Like ..!!
vcmp.setdestination x y z.........? Like this...but where to paste it under spawn signal or what..and i want that markers will be like this..
Money=C
Mailbu Club=M
Sunshine Autos=S

Example=Like in real vicecity....?? :-\

Thanks
Amenine

youlikethaaaat

alias vcmp.destination.addall {
  var %a = 1, %b = 1
  %t = $vcmp.readini(vcmp.destinations.ini,TOTALL,TOTALL)
  while (%a <= %t) {
    if ($vcmp.readini(vcmp.destinations.ini,%a,STATUS) == 1) {
      var %loc =  $vcmp.readini(vcmp.destinations.ini,%a,x) $vcmp.readini(vcmp.destinations.ini,%a,y) $vcmp.readini(vcmp.destinations.ini,%a,z)
      if ($1 == pickups) .timer -m 1 %b vcmp.newpickup 56 %loc
      else .timer -m 1 %b vcmp.setdestination $vcmp.readini(vcmp.destinations.ini,%a,ID) %loc
      %b = %b + 50
    }
    !inc %a
  }
}
from old rm scripts... stored in vcmp.destinations.ini with same syntax as gus vcmp.pickups.ini...

if you call the alias with pickups after... (vcmp.destination.addall pickups) it creates invisable pickups with id 56... so you can detect using scripts....

heres the old detection identifier:
alias vcmp.getdestination {
  var %id = $1
  var %a = 1, %b = 1
  %t = $vcmp.readini(vcmp.destinations.ini,TOTALL,TOTALL)
  while (%a <= %t) {
    if ($vcmp.readini(vcmp.destinations.ini,%a,STATUS) == 1) {
      var %x =  $vcmp.readini(vcmp.destinations.ini,%a,x)
      var %y = $vcmp.readini(vcmp.destinations.ini,%a,y)
      var %z = $vcmp.readini(vcmp.destinations.ini,%a,z)
      if ($inellipse($vcmp.location(%id,x),$vcmp.location(%id,y),$calc(%x - 5),$calc(%y - 5) ,10,10)) return %a
      %b = %b + 50
    }
    !inc %a
  }
  return unknown
}



and you would need to make scripts create the markers when players join...

heres the ini file i used to use: http://grandkillers.uberaaz.com/filez/vcmp.destinations.ini

Amenine

Very much Thanks to u........ ;D