So das were mein filterscript aber irgend wie klapt das net PLS HELP
[b]#define COLOR_LIGHTGREEN 0x86FF59FF
#define COLOR_RED 0xFF0000FF
#define COLOR_GREEN 0x00CA00FF
public OnFilterScriptInit()
{
objectname = CreateObject(971, 1623.2069091797, 562.5, 2, 0, 0, 0);
forward checkparea(playerid);
forward closegate();
forward PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z);
CreateObject(971, 1632.0999755859, 562.5, 2, 0, 0, 0);
AddStaticVehicle(596,2748.3394,-2444.2598,13.3679,269.6985,0,1); // spawnpunkt
return 1;
}
public PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z)
{
if(IsPlayerConnected(playerid))
{
new Float:oldposx, Float:oldposy, Float:oldposz;
new Float:tempposx, Float:tempposy, Float:tempposz;
GetPlayerPos(playerid, oldposx, oldposy, oldposz);
tempposx = (oldposx -x);
tempposy = (oldposy -y);
tempposz = (oldposz -z);
//printf("DEBUG: X:%f Y:%f Z:%f",posx,posy,posz);
if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
{
return 1;
}
}
return 0;
}
public OnPlayerSpawn()
{
SetTimer("checkparea", 1500, 1);
}
public checkparea(playerid)
{
if(PlayerToPoint(10.0, playerid, Pos1, Pos2, Pos3)) // 10.0 ist der Radius
{
MoveObject(971, 2000.0999755859, 562.5, 2, 0, 0, 0, 2.5); // 2.5 ist glaub ich die Geschwindigkeit
SetTimer("closegate", 5000, 0);
}
return 1;
}
Errors
error 017: undefined symbol "objectname"
error 029: invalid expression, assumed zero
error 017: undefined symbol "playerid"
error 029: invalid expression, assumed zero
error 017: undefined symbol "closegate"
error 029: invalid expression, assumed zero error 017: undefined symbol "radi"
warning 235: public function lacks forward declaration (symbol "PlayerToPoint")
warning 235: public function lacks forward declaration (symbol "checkparea")
error 017: undefined symbol "Pos1"
warning 202: number of arguments does not match definition
warning 202: number of arguments does not match definition
warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
8 Errors.
irgendwie haut das net hin KA was ich da flasch mache bin halt nen Anfäger scripter ;(