SA-MP Forums Archive
GetPlayerLocation - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: GetPlayerLocation (/showthread.php?tid=147012)



GetPlayerLocation - TaMeD - 10.05.2010

I searched the forums and the wiki, but I can't find one!

Does anyone have a function to get someone's location? E.g. "Tierra Robada"

Thanks in advance


Re: GetPlayerLocation - Grim_ - 10.05.2010

There's a zone script out there that has the names of the different zones, and displays them. It may have that function with it. Search "Zone Script"


Re: GetPlayerLocation - TaMeD - 11.05.2010

Wasn't helpful at all.. Looked, couldn't find any.

Anyone else?


Re: GetPlayerLocation - ViruZZzZ_ChiLLL - 11.05.2010

Like /whereis [ID/Player name]
and then it will say [Playername] is in Tierra Robada in an Infernus.
Like that?


Re: GetPlayerLocation - TaMeD - 11.05.2010

Quote:
Originally Posted by ViruZZzZ_ChiLLL
Like /whereis [ID/Player name]
and then it will say [Playername] is in Tierra Robada in an Infernus.
Like that?
Yeah

(I was looking for a GetVehicleName function too.. So if you know about both that'd be superb)


Re: GetPlayerLocation - Dark_Kostas - 11.05.2010

Quote:
Originally Posted by TaMeD
(I was looking for a GetVehicleName function too.. So if you know about both that'd be superb)
pawn Код:
new vNames[][] =
{
  "Landstalker", "Bravura", "Buffalo", "Linerunner", "Perrenial", "Sentinel", "Dumper", "Firetruck", "Trashmaster",
  "Stretch", "Manana", "Infernus", "Voodoo", "Pony", "Mule", "Cheetah", "Ambulance", "Leviathan", "Moonbeam",
  "Esperanto", "Taxi", "Washington", "Bobcat", "Whoopee", "BF Injection", "Hunter", "Premier", "Enforcer",
  "Securicar", "Banshee", "Predator", "Bus", "Rhino", "Barracks", "Hotknife", "Trailer", "Previon", "Coach",
  "Cabbie", "Stallion", "Rumpo", "RC Bandit", "Romero", "Packer", "Monster", "Admiral", "Squalo", "Seasparrow",
  "Pizzaboy", "Tram", "Trailer", "Turismo", "Speeder", "Reefer", "Tropic", "Flatbed", "Yankee", "Caddy", "Solair",
  "Berkley's RC Van", "Skimmer", "PCJ-600", "Faggio", "Freeway", "RC Baron", "RC Raider", "Glendale", "Oceanic",
  "Sanchez", "Sparrow", "Patriot", "Quad", "Coastguard", "Dinghy", "Hermes", "Sabre", "Rustler", "ZR-350", "Walton",
  "Regina", "Comet", "BMX", "Burrito", "Camper", "Marquis", "Baggage", "Dozer", "Maverick", "News Chopper", "Rancher",
  "FBI Rancher", "Virgo", "Greenwood", "Jetmax", "Hotring", "Sandking", "Blista Compact", "Police Maverick",
  "Boxvillde", "Benson", "Mesa", "RC Goblin", "Hotring Racer A", "Hotring Racer B", "Bloodring Banger", "Rancher",
  "Super GT", "Elegant", "Journey", "Bike", "Mountain Bike", "Beagle", "Cropduster", "Stunt", "Tanker", "Roadtrain",
  "Nebula", "Majestic", "Buccaneer", "Shamal", "Hydra", "FCR-900", "NRG-500", "HPV1000", "Cement Truck", "Tow Truck",
  "Fortune", "Cadrona", "FBI Truck", "Willard", "Forklift", "Tractor", "Combine", "Feltzer", "Remington", "Slamvan",
  "Blade", "Freight", "Streak", "Vortex", "Vincent", "Bullet", "Clover", "Sadler", "Firetruck", "Hustler", "Intruder",
  "Primo", "Cargobob", "Tampa", "Sunrise", "Merit", "Utility", "Nevada", "Yosemite", "Windsor", "Monster", "Monster",
  "Uranus", "Jester", "Sultan", "Stratum", "Elegy", "Raindance", "RC Tiger", "Flash", "Tahoma", "Savanna", "Bandito",
  "Freight Flat", "Streak Carriage", "Kart", "Mower", "Dune", "Sweeper", "Broadway", "Tornado", "AT-400", "DFT-30",
  "Huntley", "Stafford", "BF-400", "News Van", "Tug", "Trailer", "Emperor", "Wayfarer", "Euros", "Hotdog", "Club",
  "Freight Box", "Trailer", "Andromada", "Dodo", "RC Cam", "Launch", "Police Car", "Police Car", "Police Car",
  "Police Ranger", "Picador", "S.W.A.T", "Alpha", "Phoenix", "Glendale", "Sadler", "Luggage", "Luggage", "Stairs",
  "Boxville", "Tiller", "Utility Trailer"
};

GetVehicleName(modelid)
{
       return vNames[GetVehicleModel(modelid)-400];
}
You can use this like this "GetVehicleName(GetPlayerVehicleID(playerid))"


Re: GetPlayerLocation - ViruZZzZ_ChiLLL - 11.05.2010

Quote:
Originally Posted by TaMeD
Quote:
Originally Posted by ViruZZzZ_ChiLLL
Like /whereis [ID/Player name]
and then it will say [Playername] is in Tierra Robada in an Infernus.
Like that?
Yeah

(I was looking for a GetVehicleName function too.. So if you know about both that'd be superb)
Uhhh... Nope sorry I can't help you Because I forgot how to


Re: GetPlayerLocation - TaMeD - 24.05.2010

Bump. Does anyone know how to do this?


Re: GetPlayerLocation - OKStyle - 10.02.2011

https://sampforum.blast.hk/showthread.php?tid=166545