error 035: argument type mismatch (argument 2)
#1

I searched the forum i didn't find my error please help..
CODE Where the error is :-
Код:
CMD:ncmds(playerid, params[])
{
  SendClientMessage(playerid,"THE NEW CMDS ARE /waterdm");
  return 1;
ITS ON SendClientMessage line

I am actually making a cmd script using zcmd .. HELP ME ..
Reply
#2

mayby because you didn't close brackets "{}" ?

pawn Код:
CMD:ncmds(playerid, params[])
{
  SendClientMessage(playerid,"THE NEW CMDS ARE /waterdm");
  return 1;
}
Reply
#3

You are missing one parameter .

pawn Код:
SendClientMessage(playerid,COLOR_RED, "THE NEW CMDS ARE /waterdm");
On top add this
pawn Код:
#define COLOR_RED 0xFF0000FF
and add } closing bracket.

So here's your full command:-
pawn Код:
CMD:ncmds(playerid, params[])
{
  SendClientMessage(playerid,COLOR_RED, "THE NEW CMDS ARE /waterdm");
  return 1;
}
Reply
#4

https://sampwiki.blast.hk/wiki/SendClientMessage - itțs SendClientMessage(playerid, color, message); - add a color...
Then close the bracket.
Reply
#5

I have another prob ..
how do i make this cmd only for army ?
Код:
CMD:drop(playerid, params[])
SendClientMessage(playerid, COLOR_GHOSTWHITE,"YOU HAVE SUCCESSFULLY DROPPED OVER TERRORIST BASE");
SetPlayerPos(playerid, MY POSITION)
Reply
#6

please help needed +rep For who helps
Reply
#7

You could try make yourself insted of 'Make this for rep!!' (Not that you can even give meaningful rep)

Never the less..

pawn Код:
CMD:drop(playerid, params[])
{
    if(GetPlayerTeam(playerid) == TEAM_NAME) //Obviously change 'TEAM_NAME' to your team name/number
    {
        SendClientMessage(playerid,COLOR_RED, "You dropped in to the base!"); //Success!
    }
    else SendClientMessage(playerid,COLOR_RED, "You're not on the right team!"); //If their team doesn't equal TEAM_NAME
    return 1;
}
Reply
#8

thank you sorry for that rep thing
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)