30.07.2013, 15:05
Hi.
When i try compile my filterscript i got this errors:
My filterscript to teleport to other player:
Can someone improve that?
When i try compile my filterscript i got this errors:
Код:
C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(12) : error 035: argument type mismatch (argument 1) C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(13) : error 035: argument type mismatch (argument 1) C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(14) : error 035: argument type mismatch (argument 1) C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(16) : error 035: argument type mismatch (argument 1) C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(21) : error 025: function heading differs from prototype C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(23) : error 035: argument type mismatch (argument 1) C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(28) : error 028: invalid subscript (not an array or too many subscripts): "cmdtext" C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(28) : warning 215: expression has no effect C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(28) : error 001: expected token: ";", but found "]" C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(28) : error 029: invalid expression, assumed zero C:\Users\dewu\Downloads\includes\Easy DeAMX\Easy DeAMX\randka.pwn(28) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 10 Errors.
pawn Код:
#include <a_samp>
#include <core>
#include <float>
new glob0;
new glob4;
public OnGameModeInit()
{
glob0 = funcidx(8) != -1;
glob4 = funcidx(104) != -1;
if(-1 != funcidx(204))
{
return CallLocalFunction(284, 364);
}
return 1;
}
public OnPlayerCommandText(playerid, cmdtext)
{
if(glob0 && !CallLocalFunction(368, 464, playerid, cmdtext))
{
return 1;
}
new var0 = 0, var1[32];
while(cmdtext[++var0] > 32)
{
var1[var0 - 1] = tolower(cmdtext[var0]);
}
format(var1, 32, "cmd_%s", var1);
while(cmdtext[var0] == 32)
{
var0++;
}
if(!cmdtext[var0])
{
if(glob4)
{
return CallLocalFunction(504, 604, playerid, cmdtext);
}
return CallLocalFunction(var1, 640, playerid, 652);
}
if(glob4)
{
return CallLocalFunction(660, 760, playerid, cmdtext);
}
return CallLocalFunction(var1, 788, playerid, cmdtext);
}
public cmd_randka(playerid, arg1)
{
new var0 = 0;
if(!arg1 || (arg1 == 1 && !(arg1 + 4)))
{
return SendClientMessage(playerid, 0xFFFFFFFF, "/randka [id gracza]");
}
var0 = strval(arg1);
if(!IsPlayerConnected(var0))
{
return SendClientMessage(playerid, 0xFFFFFFFF, "Nieprawidlowe ID gracza!");
}
new var1[128], var2[19];
GetPlayerName(playerid, var2, 19);
format(var1, 128, "{FF6347}(id: {FFFFFF}%d){FF6347} %s {FFFFFF}chce sie z Tobą umуwić na randkę.\nCzy zgadzasz sie na to?", playerid, var2);
ShowPlayerDialog(var0, 2045, 0, 1368, var1, 1436, 1472);
SetPVarInt(var0, 1500, playerid);
return 1;
}
public OnDialogResponse(playerid, arg1, arg2)
{
if(arg1 == 2045)
{
if(arg2)
{
new Float:var0 = 0.0, Float:var1 = 0.0, Float:var2 = 0.0;
GetPlayerPos(playerid, var0, var1, var2);
SetPlayerPos(GetPVarInt(playerid, 1520), var0, var1, var2 + 2);
}
else
{
SendClientMessage(GetPVarInt(playerid, 1540), 0xFFFFFFFF, "Gracz{FF6347} dał Ci kosza!");
}
return 1;
}
return 0;
}