[FS] Zones Script -
mabako - 11.08.2006
it hasnt that much functions, it just shows the name of the zone you're in. you can integrate this script into game modes and add more functions if you want. you can get it here:
http://mabako.net/samp/0.1/zonesscript/
just load it as filterscript and it is ready for use
update to 0.2: you can now use it with other filterscripts, e.g. with my admin script, just place it in a line like "filterscripts zones admin". thx to littlewhitey for finding this bug out
i made it coz so many ppl. were requesting some script like this
Re: [FS] Zones Script | 0.1 -
metalpenguin - 11.08.2006
Good script
, may use it
Re: [FS] Zones Script | 0.1 -
mabako - 11.08.2006
i accidently put a (dont know where i found these) version online, changed to the correct version now
Re: [FS] Zones Script | 0.1 -
oTTo - 11.08.2006
very good script thx mabako...
Re: [FS] Zones Script | 0.2 -
Kfgus3 - 13.08.2006
good one but is it possible to do a "GetPlayerZone" somehow?
Re: [FS] Zones Script | 0.2 -
mabako - 13.08.2006
i changed it a bit and now you can use
pawn Code:
public GetPlayerZone(playerid) {
new line[10];
format(line,10,"p%dzone",playerid);
new zoneid = strval(PropertyGet(line));
return zoneid;
}
(you need dprop, which can be found via search or alternativly
here)
Re: [FS] Zones Script | 0.2 -
Kfgus3 - 13.08.2006
thx alot now i can trace player's locations
Re: [FS] Zones Script | 0.2 -
pdmods - 13.08.2006
what the function of this script??
i'm dutch
Re: [FS] Zones Script | 0.2 -
Red_Queen - 13.08.2006
Yo Very good man, love it
Re: [FS] Zones Script | 0.2 -
mabako - 13.08.2006
Quote:
Originally Posted by pdmods
what the function of this script??
i'm dutch
|
it shows your current zone in the bottom right corner, e.g. "Ganton" or "Idlewood"
Re: [FS] Zones Script | 0.2 -
elevator13 - 13.08.2006
Great job again Mabako
Re: [FS] Zones Script | 0.2 -
Sheepeeshaun - 14.08.2006
I don't mean to be picky but how would I change the location names colour?
I've got:
pawn Code:
#define COLOR_GREEN 0x33AA33FF
stuck at the top but can't work out where to stick the:
any help appreciated!!
(I've tried sticking COLOR_GREEN, in a few places already - I aint lazy)
Re: [FS] Zones Script | 0.2 -
DeC.dual - 14.08.2006
Quote:
Originally Posted by Sheepeeshaun
I don't mean to be picky but how would I change the location names colour?
I've got:
pawn Code:
#define COLOR_GREEN 0x33AA33FF
stuck at the top but can't work out where to stick the:
any help appreciated!!
(I've tried sticking COLOR_GREEN, in a few places already - I aint lazy)
|
pawn Code:
{ "~w~Avispa Country Club", -2470.00, -355.40, 0.00, -2270.00, -318.40, 46.10},
{ "~g~Avispa Country Club", -2550.00, -355.40, 0.00, -2470.00, -318.40, 39.70},
{ "~r~Back o Beyond", -1166.90, -2641.10, 0.00, -321.70, -1856.00, 200.00},
{ "~p~Battery Point", -2741.00, 1268.40, -4.50, -2533.00, 1490.40, 200.00},
{ "~y~Bayside", -2741.00, 2175.10, 0.00, -2353.10, 2722.70, 200.00},
{ "~b~Bayside Marina", -2353.10, 2275.70, 0.00, -2153.10, 2475.70, 200.00},
Just add ~<color letter>~ where you need it to be.
Re: [FS] Zones Script | 0.2 -
Sheepeeshaun - 14.08.2006
Quote:
Originally Posted by sXd
pawn Code:
{ "~w~Avispa Country Club", -2470.00, -355.40, 0.00, -2270.00, -318.40, 46.10}, { "~g~Avispa Country Club", -2550.00, -355.40, 0.00, -2470.00, -318.40, 39.70}, { "~r~Back o Beyond", -1166.90, -2641.10, 0.00, -321.70, -1856.00, 200.00}, { "~p~Battery Point", -2741.00, 1268.40, -4.50, -2533.00, 1490.40, 200.00}, { "~y~Bayside", -2741.00, 2175.10, 0.00, -2353.10, 2722.70, 200.00}, { "~b~Bayside Marina", -2353.10, 2275.70, 0.00, -2153.10, 2475.70, 200.00},
Just add ~<color letter>~ where you need it to be.
|
Thanks for that, just in case anyone else tries this you'll have to change the
27 in this:
pawn Code:
// ZONES
enum zoneinfo {
zone_name[27],
Float:zone_minx,
Float:zone_miny,
Float:zone_minz,
to
30 for it to compile properly (the ~g~ adds 3 chars to the biggest placename)
As a side note you may want to use pawno's replace feature to put in all the ~<colour>~'s
Re: [FS] Zones Script | 0.2 -
Kfgus3 - 14.08.2006
can u copy the stuff in .inc file out to the gamemode and use it without #include?
Re: [FS] Zones Script | 0.2 -
mabako - 14.08.2006
you actually shouldnt be able to use it with include
(for sheep & sXd) anyway, i suggest you use this
instead of
pawn Code:
if(player_zone_before == -1) GameTextForPlayer(i,zones[j][zone_name],1500,1);
else if(strcmp(zones[j][zone_name],zones[player_zone_before][zone_name],true) != 0) GameTextForPlayer(i,zones[j][zone_name],1500,1);
;
pawn Code:
new string[30];
format(string,30,"~g~%s",zones[j][zone_name]);
if(player_zone_before == -1) GameTextForPlayer(i,string,1500,1);
else if(strcmp(zones[j][zone_name],zones[player_zone_before][zone_name],true) != 0) GameTextForPlayer(i,string,1500,1);
;
which is less work and shows the text in green too
Re: [FS] Zones Script | 0.2 -
Kfgus3 - 20.08.2006
pawn Code:
blah=GetPlayerZone(playerid);
format(huh, sizeof(huh), "Location: %s", blah);
SendClientMessage(playerid, xxxx, huh);
it gives me this
maybe not [] but it's a square
------------------------------------------------
screw the ones above
how can i make GetPlayerZone returns the zone name instead of the id?
Re: [FS] Zones Script | 0.2 -
Iain.Gilbert - 20.08.2006
hey, this script sounds realy very usefull for tracking where player is. Can i use this script with gamemodes i create and distribute it with them? Giving credit to you of course.
Re: [FS] Zones Script | 0.2 -
Kfgus3 - 22.08.2006
-_-
again..
but i tried to make 1 myself using existing codes
but i couldn't do it
so, how do you get a player's location name? not id?
Re: [FS] Zones Script | 0.2 -
mabako - 24.08.2006
put all the script in your code, and then use
[nobbc]zones[xx][zone_name][/nobbc]
to get the zone name of the zone no. xx
@Iain.Gilbert: sure