CAlles anzeigenstock IsPlayerInWater(playerid) { new Float:X,Float:Y,Float:Z,an = GetPlayerAnimationIndex(playerid); GetPlayerPos(playerid,X,Y,Z); if((1544 >= an >= 1538 || an == 1062 || an == 1250) && (Z <= 0 || (Z <= 41.0 && IsPlayerInZone(playerid, -1387,-473, 2025,2824))) || (1544 >= an >= 1538 || an == 1062 || an == 1250) && (Z <= 2 || (Z <= 39.0 && IsPlayerInZone(playerid, -1387,-473,2025,2824)))) //45518 { return 1; } return 0; }
Cstock Float:GetDistanceBetweenPoints(Float:x1, Float:y1, Float:z1, Float:x2, Float:y2, Float:z2) //45508 { return floatadd(floatadd(floatsqroot(floatpower(floatsub(x1, x2), 2)), floatsqroot(floatpower(floatsub(y1, y2), 2))), floatsqroot(floatpower(floatsub(z1, z2), 2))); }
Cpublic BurningTimer(playerid) { if(PlayerOnFire[playerid] == 1) { SetPlayerHealth(playerid, GetPlayerHealth(playerid)-1); //45277 return 1; } return KillTimer(PlayerOnFireTimer[playerid]), KillTimer(PlayerOnFireTimer2[playerid]); }
C:\Users\User\Desktop\Script\gamemodes\German.pwn(45508) : warning 208: function with tag result used before definition, forcing reparseC:\Users\User\Desktop\ Script\gamemodes\German.pwn(45277) : warning 202: number of arguments does not match definitionC:\Users\User\Desktop\ Script\gamemodes\German.pwn(45518) : error 035: argument type mismatch (argument 2)
Hey,
Ich finde den fehler nicht kann mir einer sagen woran es liegt?
if((1544 >= an >= 1538 || an == 1062 || an == 1250) && (Z <= 0 || (Z <= 41.0 && IsPlayerInZone(playerid, -1387.0,-473.0, 2025.0,2824.0))) ||
(1544 >= an >= 1538 || an == 1062 || an == 1250) && (Z <= 2 || (Z <= 39.0 && IsPlayerInZone(playerid, -1387.0,-473.0,2025.0,2824.0))))
Hier hast du der funktion IsPlayerInZone Intergers anstatt Floats gegeben.
SetPlayerHealth(playerid, GetPlayerHealth(playerid)-1); //45277
Hier nutzt du GetPlayerHealth falsch.
new Float:Health;
GetPlayerHealth(playerid, Health);
SetPlayerHealth(playerid, Health -1.0);
Und die funktion Float:GetDistanceBetweenPoints kannst du entweder forwarden (oben im Skript) oder nach oben schieben