07.01.2010, 15:56
Hi all
Can you help me with this error?
#include <a_samp>
#include <takejob>
if(strcmp(cmd,"/takejob",true)==0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerToPoint(25.0,playerid,362.4931,173.6018,1 008.382
)
{
new x_nr[256];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr)) {
SendClientMessage(playerid, COLOR_LIGHTGREEN, "|__________________ Jobs __________________|");
SendClientMessage(playerid, COLOR_WHITE, "USAGE: /takejob [name]");
SendClientMessage(playerid, COLOR_WHITE, "Available names: Detective, PizzaBoy, Lawyer, Mechanic, Bodyguard");
SendClientMessage(playerid, COLOR_WHITE, "Available names: BusDriver, Boxer, CarDealer, PaperBoy, Trucker");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "|____________________________________________ |");
return 1;
}
if(strcmp(x_nr,"Detective",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a detective :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 1;
}
}
if(strcmp(x_nr,"PizzaBoy",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Pizza Boy :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 21;
}
}
if(strcmp(x_nr,"Lawyer",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Lawyer :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 2;
}
}
if(strcmp(x_nr,"Mechanic",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Mechanic :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 7;
}
}
if(strcmp(x_nr,"Bodyguard",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Bodyguard :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 8;
}
}
if(strcmp(x_nr,"BusDriver",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Bus Driver :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 14;
}
}
if(strcmp(x_nr,"Boxer",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Boxer :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 12;
}
}
if(strcmp(x_nr,"CarDealer",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Car Dealer :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 10;
}
}
if(strcmp(x_nr,"PaperBoy",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Paper Boy :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 15;
}
}
if(strcmp(x_nr,"Trucker",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Trucker :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 16;
}
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You are not in the City Hall !");
return 1;
}
}//not connected
return 1;
}
C:\Documents and Settings\CiupaNezu\Desktop\job.pwn(2) : fatal error 100: cannot read from file: "takejob"
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
1 Error.
Can you help me with this error?

#include <a_samp>
#include <takejob>
if(strcmp(cmd,"/takejob",true)==0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerToPoint(25.0,playerid,362.4931,173.6018,1 008.382

{
new x_nr[256];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr)) {
SendClientMessage(playerid, COLOR_LIGHTGREEN, "|__________________ Jobs __________________|");
SendClientMessage(playerid, COLOR_WHITE, "USAGE: /takejob [name]");
SendClientMessage(playerid, COLOR_WHITE, "Available names: Detective, PizzaBoy, Lawyer, Mechanic, Bodyguard");
SendClientMessage(playerid, COLOR_WHITE, "Available names: BusDriver, Boxer, CarDealer, PaperBoy, Trucker");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "|____________________________________________ |");
return 1;
}
if(strcmp(x_nr,"Detective",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a detective :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 1;
}
}
if(strcmp(x_nr,"PizzaBoy",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Pizza Boy :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 21;
}
}
if(strcmp(x_nr,"Lawyer",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Lawyer :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 2;
}
}
if(strcmp(x_nr,"Mechanic",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Mechanic :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 7;
}
}
if(strcmp(x_nr,"Bodyguard",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Bodyguard :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 8;
}
}
if(strcmp(x_nr,"BusDriver",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Bus Driver :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 14;
}
}
if(strcmp(x_nr,"Boxer",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Boxer :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 12;
}
}
if(strcmp(x_nr,"CarDealer",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Car Dealer :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 10;
}
}
if(strcmp(x_nr,"PaperBoy",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Paper Boy :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 15;
}
}
if(strcmp(x_nr,"Trucker",true) == 0)
{
if (GetPlayerState(playerid) == 1)
{
SendClientMessage(playerid, 0x83FF46FF, ".: [Congratulations]: You are now a Trucker :.");
PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
PlayerInfo[playerid][pJob] = 16;
}
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You are not in the City Hall !");
return 1;
}
}//not connected
return 1;
}
C:\Documents and Settings\CiupaNezu\Desktop\job.pwn(2) : fatal error 100: cannot read from file: "takejob"
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
1 Error.