Gate Help please!
#1

Can some one help me do a gang gate for Faction id 5 these are the object co.ordinates : please help me:

Closed:CreateObject(987, 1820.9423828125, -2007.2276611328, 12.554395675659, 0.000000, 0.000000, 0.000000); //

Open: CreateObject(987, 1820.8729248047, -2007.3715820313, 16.642910003662, 0.000000, 0.000000, 0.000000); //
Reply
#2

pawn Код:
forward Faction5GateCheck();

new Faction5Gate;
new Faction5GateStatus;
pawn Код:
//OnGameModeInit
Faction5Gate = CreateObject(987, 1820.9423828125, -2007.2276611328, 12.554395675659, 0.000000, 0.000000, 0.000000);
SetTimer("Faction5GateCheck", 1000, true);
pawn Код:
public Faction5GateCheck()
{
for(new i; i<MAX_PLAYERS; i++) {
if(IsPlayerConnected(i)) {
//if(GetPlayerTeam(i) == 5) { /*Uncomment this line if you want to use this gate for team 5 only*/
if(IsPlayerInRangeOfPoint(i, 10.0, 1820.9423828125, -2007.2276611328, 12.554395675659)) {
Faction5GateStatus = 1;
} else if(!IsPlayerInRangeOfPoint(i, 10.0, 1820.9423828125, -2007.2276611328, 12.554395675659)) {
Faction5GateStatus = 0;
}
//} /*Uncomment this line if you want to use this gate for team 5 only*/
}
}
if(Faction5GateStatus == 0) MoveObject(Faction5Gate, 1820.9423828125, -2007.2276611328, 12.554395675659, 5.0);
if(Faction5GateStatus == 1) MoveObject(Faction5Gate, 1820.8729248047, -2007.3715820313, 16.642910003662, 5.0);
return 1;
}
Reply
#3

Код:
public Faction5GateCheck()
{
for(new i; i<MAX_PLAYERS; i++) {
if(IsPlayerConnected(i)) {
//if(GetPlayerTeam(i) == 5) { /*Uncomment this line if you want to use this gate for team 5 only*/
if(IsPlayerInRangeOfPoint(i, 10.0, 1820.9423828125, -2007.2276611328, 12.554395675659)) {
Faction5GateStatus = 1;
} else if(!IsPlayerInRangeOfPoint(i, 10.0, 1820.9423828125, -2007.2276611328, 12.554395675659)) {
Faction5GateStatus = 0;
}
//} /*Uncomment this line if you want to use this gate for team 5 only*/ 
}

Where should i put that [[srry i am a new scripter]]
}
if(Faction5GateStatus == 0) MoveObject(Faction5Gate, 1820.9423828125, -2007.2276611328, 12.554395675659, 5.0);
if(Faction5GateStatus == 1) MoveObject(Faction5Gate, 1820.8729248047, -2007.3715820313, 16.642910003662, 5.0);
return 1;
}
Where should i put this!! help


Okay compiled but what is the command dude?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)