need a tip plz :D - 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: need a tip plz :D (
/showthread.php?tid=95274)
need a tip plz :D -
[XST]O_x - 03.09.2009
Hey
![Smiley](images/smilies/smile.png)
i need,someone who knows,to explain me how to put markers ^^
Plz
i meant that kind of markers:
Re: need a tip plz :D -
Calgon - 03.09.2009
pawn Код:
for(new i = 0;i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
SetPlayerMarkerForPlayer(playerid, i, 0xa9c4e4ff);
}
}
If I remember correctly, SetPlayerColor does the same thing with less code, but I honestly can never remember (I think it sets a marker).
Re: need a tip plz :D -
[XST]O_x - 03.09.2009
Quote:
Originally Posted by Calgon
pawn Код:
for(new i = 0;i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { SetPlayerMarkerForPlayer(playerid, i, 0xa9c4e4ff); } }
If I remember correctly, SetPlayerColor does the same thing with less code, but I honestly can never remember (I think it sets a marker).
|
idk what is it mean
![confused](images/smilies/confused.gif)
i meant to the red markers like in sp that you have in missions..
Re: need a tip plz :D -
[XST]O_x - 03.09.2009
Someone?
![Sad](images/smilies/sad.gif)
sorry for bump and double i just need it fast
Re: need a tip plz :D -
Imran.Abbas - 03.09.2009
You mean
Код:
public OnPlayerEnterCheckpoint(playerid)
?
Re: need a tip plz :D -
[XST]O_x - 03.09.2009
Quote:
Originally Posted by Imran.Abbas
You mean
Код:
public OnPlayerEnterCheckpoint(playerid)
?
|
wait ill check
Re: need a tip plz :D -
[XST]O_x - 03.09.2009
Quote:
Originally Posted by Imran.Abbas
You mean
Код:
public OnPlayerEnterCheckpoint(playerid)
?
|
i think yes
Re: need a tip plz :D -
CJ101 - 03.09.2009
you create checkpoints with SetPlayerCheckpoint:
ex:
Код:
SetPlayerCheckpoint(playerid, 1982.6150, -220.6680, -0.2432, 3.0);
Then put your code in OnPlayerEnterCheckpoint(playerid)
if you want to use more than one checkpoint, you need a streamer.
Re: need a tip plz :D -
Imran.Abbas - 03.09.2009
Put this Up
Hmmz ..... ,
Check this
Код:
public OnPlayerEnterCheckpoint(playerid) {
if(czek == 0)
{
SendClientMessageToAll(COLOR_RACE, "*** %s (what you want to Type)",Player(playerid));
czek = 1;
for(new i; i<MAX_PLAYERS; i++) DisablePlayerCheckpoint(i);
}
return 1;
}
on PlayerSpawn
Код:
DisablePlayerCheckpoint(playerid);
This put on under Commands Example : /home <
Код:
for(new i; i<MAX_PLAYERS; i++){
if(IsPlayerInArea(playerid, -2699.4290, 1241.5670, -2661.3909, 1311.5662) && IsPlayerInArea(i, -2699.4290, 1241.5670, -2661.3909, 1311.5662)){
DisablePlayerCheckpoint(i);
SetPlayerCheckpoint(i, -2682.5291,2176.9382,54.9985, 25);
czek = 0;
}
}
}
put this anywhere : P
Код:
IsPlayerInArea(playerID, Float:minx, Float:miny, Float:maxx, Float:maxy)
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerID, X, Y, Z);
if(X >= minx && X <= maxx && Y >= miny && Y <= maxy) {
return 1;
}
return 0;
}
(didnt check lol )
Re: need a tip plz :D -
[XST]O_x - 03.09.2009
thx
Only wanted to put a check point/a marker near a house in my map,and when you get in its teleports you to the interior thx