Symbole Is NEVER USED : [ HELP]
#1

pawn Код:
// This is a comment
// uncomment the line below if you want to write a filterscript
//#define FILTERSCRIPT

#include <a_samp>

#if defined FILTERSCRIPT

new AdminDuty[MAX_PLAYERS];

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Blank Filterscript by your name here");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

#else

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

#endif

public OnGameModeExit()
{
    return 1;
}

public OnPlayerConnect(playerid)
{
    return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
    return 1;
}


enum playerinfo
{
p_level,
}
new Player[MAX_PLAYERS][playerinfo];

CMD:onduty(playerid, params[])
{
if(Player[playerid][p_level] >= 1)
{
if(AdminDuty[playerid] == 0)
{
new string[128];
AdminDuty[playerid] = 1;
format(string, sizeof(string),"Admin %s is now onduty!", GetName(playerid));
SendClientMessageToAll(-1, string);
}
else SendClientMessage(playerid, -1,"You are already on duty.");
}
else SendClientMessage(playerid, -1,"You are not an admin.");
return 1;
}

CMD:offduty(playerid, params[])
{
if(Player[playerid][p_level] >= 1)
{
if(AdminDuty[playerid] == 1)
{
new string[128];
AdminDuty[playerid] = 0;
format(string, sizeof(string),"Admin %s is now offduty!", GetName(playerid));
SendClientMessageToAll(-1, string);
}
else SendClientMessage(playerid, -1,"You are already off duty.");
}
else SendClientMessage(playerid, -1,"You are not an admin.");
return 1;
}

stock GetName(playerid)
{
new pname[24];
GetPlayerName(playerid, pname, sizeof(pname));
return pname;
}
i am using this code to crete admin duty but i got the following error
Код:
C:\Users\Hazaras\Desktop\(FINAL)\filterscripts\test.pwn(98) : warning 203: symbol is never used: "offduty"
C:\Users\Hazaras\Desktop\(FINAL)\filterscripts\test.pwn(98) : warning 203: symbol is never used: "onduty"
Can some one please help me ?
Reply
#2

it means u are just not using it.. not an error. pawno is just reminding u :P
Reply
#3

Quote:
Originally Posted by aNdReSk
Посмотреть сообщение
it means u are just not using it.. not an error. pawno is just reminding u :P
but i cant compile it :P...what to do n how to fix it ?
Reply
#4

It's just a warning. Check for the "test.amx" file.
Reply
#5

Quote:
Originally Posted by freddy smyth
Посмотреть сообщение
It's just a warning. Check for the "test.amx" file.
ok thanks for your help . +1

EDIT : But the command still does'nt work in game becouse it is not compiled !!!
Reply
#6

By that, I'm guessing it worked after all? :3

Glad to help!
Reply
#7

lol you dont have
pawn Код:
#include <zcmd>
Reply
#8

Are you using ZCMD cmd processor or STRCMP? Do you have a coded command?
Reply
#9

Quote:
Originally Posted by Ballu Miaa
Посмотреть сообщение
Are you using ZCMD cmd processor or STRCMP? Do you have a coded command?
yes i have codded it . and i am using zcmd . and For sure i have the zcmd.inc in my pawno > Include folder !
Reply
#10

It seems that it doesnt got noticed, so again

Quote:
Originally Posted by James Coral
Посмотреть сообщение
lol you dont have
pawn Код:
#include <zcmd>
Also something like that
pawn Код:
#include <a_samp>
#include <zcmd>

new AdminDuty[MAX_PLAYERS];

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

// rest of your code after the endif
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)