an error while compiling...
#1

i get this error while compiling please help hw to fix it?
Код:
D:\XtreameGaming Gamemode\gamemodes\lvdm2.pwn(947) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")
D:\XtreameGaming Gamemode\gamemodes\lvdm2.pwn(1918) : warning 235: public function lacks forward declaration (symbol "OnPlayerInfoChange")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Warnings.
Reply
#2

Post your code...
Reply
#3

Quote:
Originally Posted by maziar_gholipour
Посмотреть сообщение
i get this error while compiling please help hw to fix it?
Код:
D:\XtreameGaming Gamemode\gamemodes\lvdm2.pwn(947) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")
D:\XtreameGaming Gamemode\gamemodes\lvdm2.pwn(1918) : warning 235: public function lacks forward declaration (symbol "OnPlayerInfoChange")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Warnings.
Add on the top of your script
pawn Код:
forward OnPlayerPrivmsg(playerid);
forward OnPlayerInfoChange(playerid);
Reply
#4

onplayerprivmsg
Warning: This callback was removed in SA-MP 0.3. See below how to create a /pm command.

if u have new versions...this wont work
Reply
#5

Lines ?
And you need to forward the public declarations.
Reply
#6

they are old functions!
both of them removed
for
the 1st function check this post -> https://sampwiki.blast.hk/wiki/OnPlayerPrivmsg
and
the 2nd function check this post -> https://sampforum.blast.hk/showthread.php?tid=152262
Reply
#7

you mean i cant use this gamemode?cause it have old functions?! -.-
Reply
#8

You can use it, but these 2 functions won't work.
Reply
#9

delete them and they wont give more errors
Reply
#10

Quote:

Warning: This callback was removed in SA-MP 0.3. See below how to create a /pm command.

If you wanna use /pm just use this

PHP код:
if(!strcmp("/pm"cmdtexttrue))
{
    
tmp strtok(cmdtext,idx);
    if(!
strlen(tmp)) return SendClientMessage(playerid,0xFF0000FF,"USAGE: /PM (id) (message)");
    new 
id strval(tmp);
    
gMessage strrest(cmdtext,idx);
    if(!
strlen(gMessage)) return SendClientMessage(playerid,0xFF0000FF,"Usage: /pm (id) (message)");        
    if(!
IsPlayerConnected(id)) return SendClientMessage(playerid,0xFF0000FF,"/pm :Invalid ID");    
    
GetPlayerName(id,iName,sizeof(iName));
    
GetPlayerName(playerid,pName,sizeof(pName));
    
format(Message,sizeof(Message),">> %s(%i): %s",iName,id,gMessage);
    
SendClientMessage(playerid,0xFFD720FF,Message);
    
format(Message,sizeof(Message),"** %s(%i): %s",pName,playerid,gMessage);
    
SendClientMessage(id,0xFFD720FF,Message);
    
PlayerPlaySound(id,1085,0.0,0.0,0.0);
    return 
1;

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)