[HELP] Ganzone car or kill help
#1

Hello everyone,

I have a question how you can ensure that they can kill time in this pace area but 3 and that them then gekickt become or that they are possible no cars spawnen by means of my /cars command.
This is script which I have now:
Код:
//At The Top Of The Script:
new savezone;

//Under OnGameModeInit
savezone = GangZoneCreate(1815.991333, 1272.023803, 2071.991210, 1456.023803);

//Under OnPlayerConnect:
GangZoneShowForPlayer(playerid, savezone, 65477);
In advance super thanks!
Snabbo
Reply
#2

Well I don't realy understand were you are talking about, But I think you mean, That if a player entered that zone something happend?
You can use this fuction:

Past this somewere in your script:

Код:
public IsPlayerInArea(playerid, Float:minx, Float:maxx, Float:miny, 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;
}
Create a timer. And but this in your timer:

Код:
		
if(IsPlayerInArea(playerid,1815.991333, 2071.991210, 1272.023803, 1456.023803) == 1)
		{
// What happends when a player entered the zone
}
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)