31.05.2012, 08:31
ok For Example here is the gangzone
And here is the checkpoint
these are teams + colors
now i want if some one comes in checkpoint and stays 30 secs and caps and and get 5 score + 5000 money and gangzone color =his team
pawn Code:
new gangzone;
public OnGameModeInit()
{
gangzone = GangZoneCreate(1248.011, 2072.804, 1439.348, 2204.319);
return 1;
}
public OnPlayerSpawn(playerid)
{
if(IsPlayerAdmin(playerid)) GangZoneShowForAll(gangzone,COLOR_RED);
return 1;
}
pawn Code:
public OnPlayerSpawn(playerid)
{
SetPlayerCheckpoint(playerid, 1982.6150, -220.6680, -0.2432, 3.0);
return 1;
}
public OnPlayerEnterCheckpoint(playerid)
{
GivePlayerMoney(playerid, 5000);
DisablePlayerCheckpoint(playerid);
return 1;
}
pawn Code:
#define TEAM_USA 1
#define TEAM_COLOR_USA COLOR_BLUE
#define TEAM_JAPAN 2
#define TEAM_COLOR_JAPAN COLOR_WHITE
#define TEAM_GERMANY 3
#define TEAM_COLOR_GERMANY COLOR_BROWN
#define TEAM_RUSSIA 4
#define TEAM_COLOR_RUSSIA COLOR_RED
#define TEAM_ENGLAND 5
#define TEAM_COLOR_ENGLAND COLOR_PLUM
#define TEAM_MEXICO 6
#define TEAM_COLOR_MEXICO COLOR_LIMEGREEN
#define TEAM_INDIA 7
#define TEAM_COLOR_INDIA COLOR_CORAL
#define TEAM_BRAZIL 8
#define TEAM_COLOR_BRAZIL COLOR_AQUA
#define TEAM_FRANCE 9
#define TEAM_COLOR_FRANCE COLOR_INDIGO
#define TEAM_INDONESIA 10
#define TEAM_COLOR_INDONESIA COLOR_BISQUE