Hey,
Ich hab jetzt im meinem Script ein Fehler, undzwar geht ein tor ned mehr,
Code:
if(strcmp(cmd,"/ptor",true) == 0)
{
new pName[MAX_PLAYER_NAME];
GetPlayerName(playerid,pName,sizeof pName);
if(PlayerInfo[playerid][pMember] == 7 || PlayerInfo[playerid][pLeader] == 7 || IsACop(playerid) || IsPlayerInFrac(playerid, 22))
{
if(IsPlayerInRangeOfPoint(playerid, 20.0, 1426.56945801,-1901.34228516,12.76267624) || IsPlayerInRangeOfPoint(playerid, 20.0, 1426.33483887,-1901.32604980,12.75741196))
{
MoveObject(leo2,1426.33483887,-1901.32604980,2.75741196,3.0);
MoveObject(leo1,1426.56945801,-1901.34228516,2.76267624,3.0);
SendClientMessage(playerid, COLOR_GREEN, "Du hast das Tor geöffent, es schließt in 10 Sekunden.");
PlaySoundForPlayer(playerid,1035);
SetTimerEx("PlaySoundForPlayer",2000,0,"id",playerid,1036);
SetTimer("leozu1",10000,0);
SetTimer("leozu2",10000,0);
}
else if(IsPlayerInRangeOfPoint(playerid, 20.0, 1285.7044677734, -2056.2905273438, 60.493286132813))
{
if(TorP == false)
{
MoveObject(PTor, 1285.7044677734, -2056.2905273438, 54.938991546631, 3.0);
SendClientMessage(playerid, COLOR_GREEN, "Tor geöffnet");
TorP = true;
}
else if(TorP == true)
{
MoveObject(PTor, 1285.7044677734, -2056.2905273438, 60.493286132813, 3.0);
SendClientMessage(playerid, COLOR_RED, "Tor geschlossen");
TorP = false;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Du bist zu weit vom Tor entfernt!");
}
}
else SendClientMessage(playerid,COLOR_RED,"Du bist kein Mitglied der Regierung!");
return 1;
}
Das tor bewegt sich ned mehr
Hoffe ihr könnt mir helfen
PS: es is das untere tor
MFG Electro