ZMCD problems
#1

after include ZCMD (#include<ZCMD>) Getting unknown commands
Reply
#2

Quote:
Originally Posted by rober98
View Post
after define ZMCD (#define<ZMCD>) Getting unknown commands
#define <zcmd>

Example:

pawn Code:
CMD:kill(playerid, params[])
{
SetPlayerHealth(playerid, 0.0);
SendClientMessage(playerid, -1, "You Have commited a Suicide");
return 1;
}
Reply
#3

Quote:
Originally Posted by rober98
View Post
after define ZMCD (#define<ZMCD>) Getting unknown commands
pawn Code:
#include <zcmd>
on top.
Reply
#4

CMD:kill(playerid, params[])
{
SetPlayerHealth(playerid, 0.0);
SendClientMessage(playerid, -1, "You Have commited a Suicide");
return 1;
}
C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(500) : error 029: invalid expression, assumed zero
C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(500) : error 017: undefined symbol "cmd_kill"
C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(500) : error 029: invalid expression, assumed zero
C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(500) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#5

pawn Code:
CMD:kill(playerid) // you don't need params[] since you don't use anything with it.
{
  SetPlayerHealth(playerid, 0);
  SendClientMessage(playerid,-1,"You have commited a suicide");
  return 1;
}
Reply
#6

CMD:kill(playerid)
{
SetPlayerHealth(playerid, 0);
SendClientMessage(playerid,-1,"You have commited a suicide");
return 1;
}

C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(499) : error 017: undefined symbol "kill"
C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(505) : warning 225: unreachable code
C:\Users\rober\Desktop\New folder\server\gamemodes\mine.pwn(499) : warning 203: symbol is never used: "CMD"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.
Reply
#7

Place it under onplayercommandtext ....
Reply
#8

Quote:
Originally Posted by denom
View Post
Place it under onplayercommandtext ....
For ZCMD you don't need to put it under OnPlayerCommandText..?
Reply
#9

Quote:
Originally Posted by StuartD
View Post
For ZCMD you don't need to put it under OnPlayerCommandText..?
oh i did forgot that Xd...

Try to redownload zcmd include.. i tried the code and its working on mine.
Reply
#10

Quote:
Originally Posted by denom
View Post
oh i did forgot that Xd...

Try to redownload zcmd include.. i tried the code and its working on mine.
Maybe he puts the CMD: under something like OnPlayerCommandText, or other, that's why it doesn't work for him probably.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)