Balvin[]
-
Posts
4 -
Joined
-
Last visited
Content Type
Profiles
Forums
News
Documentation
Posts posted by Balvin[]
-
-
Da am include-ul. Da unde trebuie pusa ? daca nu in public?
-
Problema intalnita (descriere):Am trecut comanda /quitjob pe zcmd dar imi da niste erori si nu inteleg de ce!
Ero(area / rile) / warning-(ul / urile):4 erorisi un warning:error 029: invalid expression, assumed zero de 2 ori,error 017: undefined symbol "cmd_quitjob",fatal error 107: too many error messages on one line,warning 217: loose indentation
Liniile de cod / sursa / script-ul(obligatoriu):CMD:quitjob(playerid, params[])
{
new quitjob;
SendClientMessage(playerid, COLOR_WHITE, "You have quit your job.");
playerVariables[playerid][pJob] = 0;
PlayerIsSweeping[playerid] = 0;
DisablePlayerCheckpoint(playerid);
DisablePlayerRaceCheckpoint(playerid);
playerVariables[playerid][pCheckpoint] = 0;
playerVariables[playerid][pBackup] = -1;
PlayerFind[playerid] = 999;
CP[playerid] = 0;
CPR[playerid] = 0;
SendClientMessage(playerid, COLOR_WHITE,"Checkpoint disabled.");
return 1;
}
Imagini / Video (optional):http://imgur.com/a/3nhWQ
Ati incercat sa rezolvati singur?: Da, dar daca modific ceva da si mai multe erori. -
Am comanda asta si doresc sa o trec pe zcmd am include tot dar cum o fac.
if(strcmp(cmd, "/quitjob", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(gPlayerLogged[playerid] != 0)
{
if(PlayerInfo[playerid][pJob] > 0)
{
if(PlayerInfo[playerid][pDonateRank] > 0)
{
if(PlayerInfo[playerid][pContractTime] >= 0)
{
SendClientMessage(playerid, -1, "* You already forfilled your 1 hour Contract, and quited your Job.");
PlayerInfo[playerid][pJob] = 0;
PlayerInfo[playerid][pChar] = 0;
PlayerInfo[playerid][pContractTime] = 0;
}
else
{
new chours = 2 - PlayerInfo[playerid][pContractTime];
format(string, sizeof(string), "* You still have %d hours left to forfill and end your Contract.", chours / 2);
SendClientMessage(playerid, -1, string);
}
}
else
{
if(PlayerInfo[playerid][pContractTime] >= 10)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You already forfilled your 5 hour Contract, and quited your Job.");
PlayerInfo[playerid][pJob] = 0;
PlayerInfo[playerid][pChar] = 0;
PlayerInfo[playerid][pContractTime] = 0;
}
else
{
new chours = 10 - PlayerInfo[playerid][pContractTime];
format(string, sizeof(string), "* You still have %d hours left to forfill and end your Contract.", chours / 2);
SendClientMessage(playerid, -1, string);
}
}
}
else
{
SendClientMessage(playerid, -1, ""ALBASTRU2"Nu ai nici un job !");
return 1;
}
}
else
{
SendClientMessage(playerid, -1, ""ALBASTRU2"Nu esti conectat !");
return 1;
}
}
return 1;
}Si vreau cand dai /quitjob sa nu mai ramana 5 ore pana sa imi expire ca nu gasesc orele alea 5. Multumesc
Comanda /quitjob
in Arhivă probleme
Posted
Ero(area / rile) / warning-(ul / urile):Nu am erori/warning-uri
Liniile de cod / sursa / script-ul(obligatoriu):
Imagini / Video (optional):
/*==============================================================================
Comanda: /quitjob
==============================================================================*/
if(strcmp(cmd, "/quitjob", true) == 0)
Ati incercat sa rezolvati singur?:Da{
if(IsPlayerConnected(playerid))
{
if(gPlayerLogged[playerid] != 0)
{
if(PlayerInfo[playerid][pJob] > 0)
{
if(PlayerInfo[playerid][pDonateRank] > 0)
{
if(PlayerInfo[playerid][pContractTime] >= 2)
{
SendClientMessage(playerid, -1, "* You already forfilled your 1 hour Contract, and quited your Job.");
PlayerInfo[playerid][pJob] = 0;
PlayerInfo[playerid][pChar] = 0;
PlayerInfo[playerid][pContractTime] = 0;
}
else
{
new chours = 2 - PlayerInfo[playerid][pContractTime];
format(string, sizeof(string), "* You still have %d hours left to forfill and end your Contract.", chours / 2);
SendClientMessage(playerid, -1, string);
}
}
else
{
if(PlayerInfo[playerid][pContractTime] >= 10)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You already forfilled your 5 hour Contract, and quited your Job.");
PlayerInfo[playerid][pJob] = 0;
PlayerInfo[playerid][pChar] = 0;
PlayerInfo[playerid][pContractTime] = 0;
}
else
{
new chours = 10 - PlayerInfo[playerid][pContractTime];
format(string, sizeof(string), "* You still have %d hours left to forfill and end your Contract.", chours / 2);
SendClientMessage(playerid, -1, string);
}
}
}
else
{
SendClientMessage(playerid, -1, ""ALBASTRU2"Nu ai nici un job !");
return 1;
}
}
else
{
SendClientMessage(playerid, -1, ""ALBASTRU2"Nu esti conectat !");
return 1;
}
}
return 1;
}