HP Command
#1

Код HTML:
C:\Users\Gigi\Desktop\America Life\gamemodes\tutorial.pwn(99) : error 010: invalid function or declaration
C:\Users\Gigi\Desktop\America Life\gamemodes\tutorial.pwn(102) : error 010: invalid function or declaration
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
have this 2 error .. on this

Код HTML:
if(strcmp("kill", cmdtext, true, 10) == 0)
	{
	    SetPlayerHealth(playerid, 0);
	    return 1;
	}
99 Line Is --- if(strcmp("kill", cmdtext, true, 10) == 0)
102 Line Is --- return 1;
Reply
#2

i know now sryy
Reply
#3

nvm.
Reply
#4

Good afternoon.

The wiki is present for you, replace your code per :

PHP код:
#include <a_samp> // We include <a_samp> for get the functions of samp.
public OnPlayerCommandText(playeridcmdtext[]) // Your callback.
{
    if(
strcmp(cmdtext,"/kill",true,10)==0// If you do the command /kill.
    
{
        
SetPlayerHealth(playerid0); // Set value 0 of health of player. 
        
return 1;
    }
    return 
0// Good, return 0.

Kind regards.
Reply
#5

pawn Код:
if(strcmp("kill", cmdtext, true, 10) == 0) // you must add / before kill : /kill
you can use dcmd or ...
it's better
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)