Meine Tore gehen nicht auf , obwohl ich die Koords schon 3 mal überprüft habe.
Hier der Code:
forward CloseFeugate1();
forward CloseFeugate3();
forward CloseFeugate2();
forward CloseFeugate4();
forward CloseFeugate5();
forward CloseFeugate6();]
ocmd:gate(playerid,params[]){
if(!IstSpielerInFraktion(playerid,15) && !IstSpielerInFraktion(playerid,16))return SendClientMessage(playerid,Rot,"Du kannst keinen dieses Tor nicht öffnen!");
{
if(IsPlayerInRangeOfPoint(playerid,35, -1106.41, -1281.81, 126.76))
{
MoveObject(Feugate1,-1106.41, -1281.81, 126.76-10,5);
SetTimer("CloseFeugate1",20000,false);
SendClientMessage(playerid,Gelb,"Das Tor schliesst in 20 sec automatisch.");
return 1;
}
if(IsPlayerInRangeOfPoint(playerid,35,-1060.76, -1282.37, 126.76)) {
MoveObject(Feugate2,-1060.76, -1282.37, 126.76-10,5);
SetTimer("CloseFeugate2",20000,false);
SendClientMessage(playerid,Gelb,"Das Tor schliesst in 20 sec automatisch.");
return 1;
}
if(IsPlayerInRangeOfPoint(playerid,20,-1106.42, -1235.11, 129.78)) {
MoveDynamicObject(Feugate3, -1106.42, -1235.11, 129.78-10,5);
SetTimer("CloseFeugate3",10000,false);
SendClientMessage(playerid,Gelb,"Das Tor schliesst in 10 sec automatisch.");
return 1;
}
if(IsPlayerInRangeOfPoint(playerid,50,-1106.54, -1243.05, 129.76))
{
MoveDynamicObject(Feugate4, -1106.54, -1243.05, 129.76-10,5);
SetTimer("CloseFeugate4",10000,false);
SendClientMessage(playerid,Gelb,"Das Tor schliesst in 10 sec automatisch.");
return 1;
}
if(IsPlayerInRangeOfPoint(playerid,50,-1058.99, -1243.15, 129.83))
{
MoveDynamicObject(Feugate5, -1058.99, -1243.15, 129.83-10,5);
SetTimer("CloseFeugate5",10000,false);
SendClientMessage(playerid,Gelb,"Das Tor schliesst in 10 sec automatisch.");
return 1;
}
if(IsPlayerInRangeOfPoint(playerid,50, -1058.84, -1235.23, 129.85))
{
MoveDynamicObject(Feugate6, -1058.84, -1235.23, 129.85-10,5);
SetTimer("CloseFeugate6",10000,false);
SendClientMessage(playerid,Gelb,"Das Tor schliesst in 10 sec automatisch.");
return 1;
}
}
return 1; }
public CloseFeugate1()
{
MoveObject(Feugate1,-1106.41, -1281.81, 126.76,5);
}
public CloseFeugate2()
{
MoveObject(Feugate2,-1060.76, -1282.37, 126.76,5);
}
public CloseFeugate3()
{
MoveDynamicObject(Feugate3,-1106.42, -1235.11, 129.78,5);
}
public CloseFeugate4()
{
MoveDynamicObject(Feugate4, -1106.54, -1243.05, 129.76,5);
}
public CloseFeugate5()
{
MoveDynamicObject(Feugate5,-1058.99, -1243.15, 129.83,5);
}
public CloseFeugate6()
{
MoveDynamicObject(Feugate6,-1058.84, -1235.23, 129.85,5);
}