Hallo liebes Breadfish Forum...
ich habe hier eine SaveBox und wollte diese in ein Filterscript einbauen...
nun hab ich das problemm es kommen diese Errors wenn ich Compile:
ZitatAlles anzeigenD:\Users\ShoXx\Desktop\SaveBox.pwn(31) : error 017: undefined symbol "cmd"
D:\Users\ShoXx\Desktop\SaveBox.pwn(33) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(35) : error 017: undefined symbol "PlayerToPoint"
D:\Users\ShoXx\Desktop\SaveBox.pwn(3) : error 017: undefined symbol "strtok"
D:\Users\ShoXx\Desktop\SaveBox.pwn(3) : error 033: array must be indexed (variable "x_nr")
D:\Users\ShoXx\Desktop\SaveBox.pwn(40) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(41) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(42) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(43) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(4) : error 017: undefined symbol "tmp"
D:\Users\ShoXx\Desktop\SaveBox.pwn(4) : error 017: undefined symbol "strtok"
D:\Users\ShoXx\Desktop\SaveBox.pwn(49) : error 017: undefined symbol "tmp"
D:\Users\ShoXx\Desktop\SaveBox.pwn(51) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(52) : error 017: undefined symbol "string"
D:\Users\ShoXx\Desktop\SaveBox.pwn(52) : error 017: undefined symbol "string"
D:\Users\ShoXx\Desktop\SaveBox.pwn(52) : error 017: undefined symbol "playerid"
D:\Users\ShoXx\Desktop\SaveBox.pwn(52) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
17 Errors.
Und das hier ist das Filterscript:
#include <a_samp>
#define FILTERSCRIPT
#if defined FILTERSCRIPT
//==============================================================================
public OnFilterScriptInit()
{
print("\n========================================");
print(" FILTERSCRIPT - SaveBox");
print("========================================\n");
//============================ SaveBox ===============================//
if(strcmp(cmd,"/put",true)==0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerToPoint(10.0,playerid,2133.82666016,-1787.04248047,12.52786732) || PlayerToPoint(10.0,playerid,2805.2058,-1418.9055,16.2500) || PlayerToPoint(10.0,playerid,836.9014,-1853.4141,6.4093))
{
new x_nr[256];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr)) {
SendClientMessage(playerid, COLOR_WHITE, "|__________________ Put __________________|");
SendClientMessage(playerid, COLOR_WHITE, "Benutzung: /put [NAME]");
SendClientMessage(playerid, COLOR_GREY, "Verfügbare Namen: Mats, Drogen");
SendClientMessage(playerid, COLOR_WHITE, "|____________________________________________|");
return 1;
}
if(strcmp(x_nr,"Mats",true) == 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutze: /put mats [Menge]");
format(string, sizeof(string), " Du hast %d Mats bei dir.", PlayerInfo[playerid][pMats]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
new matss;
matss = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutze: /put mats [Menge]");
format(string, sizeof(string), " Du hast %d Materialien bei dir.", PlayerInfo[playerid][pMats]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
if(matss > PlayerInfo[playerid][pMats])
{
SendClientMessage(playerid, COLOR_GRAD2, " So viele Materialien hast du nicht!");
return 1;
}
PlayerInfo[playerid][pMats] -= matss;
PlayerInfo[playerid][pBoxMats] += matss;
format(string, sizeof(string), " %d Materialien in die Savebox gelegt!", matss);
SendClientMessage(playerid, COLOR_GRAD4, string);
return 1;
}
else if(strcmp(x_nr,"Drogen",true) == 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutzung: /put drogen [Menge]");
format(string, sizeof(string), " Du hast %d Drogen bei dir.", PlayerInfo[playerid][pDrugs]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
new drugss;
drugss = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutzung: /put drogen [Menge]");
format(string, sizeof(string), " Du hast %d Drogen bei dir.", PlayerInfo[playerid][pDrugs]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
if(drugss > PlayerInfo[playerid][pDrugs])
{
SendClientMessage(playerid, COLOR_GRAD2, " So viele Drogen hast du nicht!");
return 1;
}
PlayerInfo[playerid][pDrugs] -= drugss;
PlayerInfo[playerid][pBoxDrugs] += drugss;
format(string, sizeof(string), " %d Drogen in die Savebox gelegt!", drugss);
SendClientMessage(playerid, COLOR_GRAD4, string);
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, " Du bist an keiner Savebox!");
return 1;
}
}
return 1;
}
if(strcmp(cmd,"/stake",true)==0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerToPoint(10.0,playerid,-363.85308838,-1430.48315430,24.72656250) || PlayerToPoint(10.0,playerid,2133.82666016,-1787.04248047,12.52786732) || PlayerToPoint(10.0,playerid,2805.2058,-1418.9055,16.2500) || PlayerToPoint(10.0, playerid, 836.9014,-1853.4141,6.4093))
{
new x_nr[256];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr)) {
SendClientMessage(playerid, COLOR_WHITE, "|__________________ sTake __________________|");
SendClientMessage(playerid, COLOR_WHITE, "Benutzung: /stake [NAME]");
SendClientMessage(playerid, COLOR_GREY, "Verfügbare Namen: Mats, Drogen");
SendClientMessage(playerid, COLOR_WHITE, "|____________________________________________|");
return 1;
}
if(strcmp(x_nr,"Mats",true) == 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutzung: /stake mats [Menge]");
format(string, sizeof(string), " Du hast %d Materialien in deiner Savebox.", PlayerInfo[playerid][pBoxMats]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
new matss;
matss = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutzung: /stake Mats [Menge]");
format(string, sizeof(string), " Du hast %d Materialien in der Savebox.", PlayerInfo[playerid][pBoxMats]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
if(matss > PlayerInfo[playerid][pBoxMats])
{
SendClientMessage(playerid, COLOR_GRAD2, " So viele Materialien hast du nicht!");
return 1;
}
PlayerInfo[playerid][pBoxMats] -= matss;
PlayerInfo[playerid][pMats] += matss;
format(string, sizeof(string), " %d Materialien genommen!", matss);
SendClientMessage(playerid, COLOR_GRAD4, string);
return 1;
}
else if(strcmp(x_nr,"Drogen",true) == 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutzung: /stake drogen [Menge]");
format(string, sizeof(string), " Du hast %d Drogen in deiner Savebox.", PlayerInfo[playerid][pBoxDrugs]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
new drugss;
drugss = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutzung: /stake drogen [Menge]");
format(string, sizeof(string), " Du hast %d Drogen in der Savebox.", PlayerInfo[playerid][pBoxDrugs]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
if(drugss > PlayerInfo[playerid][pBoxDrugs])
{
SendClientMessage(playerid, COLOR_GRAD2, " So viele Drogen hast du nicht!");
return 1;
}
PlayerInfo[playerid][pBoxDrugs] -= drugss;
PlayerInfo[playerid][pDrugs] += drugss;
format(string, sizeof(string), " %d Drogen aus der Savebox genommen", drugss);
SendClientMessage(playerid, COLOR_GRAD4, string);
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Du bist an keiner Savebox!");
return 1;
}
}
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
#endif
Ich finde den fehler oder die 17 errors nicht evntl...
könnt ihr mir ja helfen..
würde mich sehr freuen...
mfg: RaZ3r