Major Problem
#1

In my gamemode, there are commands with text. I now have a major error.

I have a /help command, and everytime I type another command, it shows the text that /help sends.

Any ideas of what could be causing this?
Reply
#2

Nope, not unless you post maybe your help command and if thats not enough the whole 'OnPlayerCommand' thing.
Reply
#3

Here:

pawn Код:
if(strcmp(cmd, "/help", true) == 0) {
        SendClientMessage(playerid, COLOR_GREEN, "BlackBlood's freeroam: Created by [TLA]BlackBlood.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /genhelp for general help.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /moneyhelp for information about earning money.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /languagehelp for information about languages.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /adminhelp for information about the admins and becoming one.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /cmds for the commands.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /rules for this server's rules.");
  return 1;
  }
Reply
#4

BUMP: Help me. I'm desperate.
Reply
#5

Uhhh.. I kinda don't get your problem :/
kindly clearly explain it again
Reply
#6

Well everytime I type in a command, the text that is supposed to be sent went /help is typed appears.
Reply
#7

Does anybody get it? I don't understand his english
Reply
#8

Quote:
Originally Posted by reallifescript
Does anybody get it? I don't understand his english
Ugh...

Look, the command seems to be bugged. When I type something like /cmds, it shows /help.
Reply
#9

Quote:
Originally Posted by BlackBlood1337
Quote:
Originally Posted by reallifescript
Does anybody get it? I don't understand his english
Ugh...

Look, the command seems to be bugged. When I type something like /cmds, it shows /help.
I understand what you mean. I don't see why people are having such a hard time getting it

Paste your ENTIRE OnPlayerCommandText callback in pastebin.com and post the link here. I think I know whats wrong, but I need to see the entire thing in order to confirm it.
Reply
#10

Here you go:
Код:
if(!strcmp(cmd, "/help", true,5))
{
SendClientMessage(playerid, COLOR_GREEN, "BlackBlood's freeroam: Created by [TLA]BlackBlood.");
SendClientMessage(playerid, COLOR_YELLOW, "Type: /genhelp for general help.");
SendClientMessage(playerid, COLOR_YELLOW, "Type: /moneyhelp for information about earning money.");
SendClientMessage(playerid, COLOR_YELLOW, "Type: /languagehelp for information about languages.");
SendClientMessage(playerid, COLOR_YELLOW, "Type: /adminhelp for information about the admins and becoming one.");
SendClientMessage(playerid, COLOR_YELLOW, "Type: /cmds for the commands.");
SendClientMessage(playerid, COLOR_YELLOW, "Type: /rules for this server's rules.");
  return 1;
}
Use this "strcmp format" for all your commands.
Reply
#11

try this:

pawn Код:
if(strcmp(cmd, "/help", true) == 0) {
        SendClientMessage(playerid, COLOR_GREEN, "BlackBlood's freeroam: Created by [TLA]BlackBlood.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /genhelp for general help.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /moneyhelp for information about earning money.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /languagehelp for information about languages.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /adminhelp for information about the admins and becoming one.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /cmds for the commands.");
        SendClientMessage(playerid, COLOR_YELLOW, "Type: /rules for this server's rules.");
}
return 1;
Reply
#12

Quote:
Originally Posted by kaisersouse
I understand what you mean. I don't see why people are having such a hard time getting it

Paste your ENTIRE OnPlayerCommandText callback in pastebin.com and post the link here. I think I know whats wrong, but I need to see the entire thing in order to confirm it.
Link:

http://pastebin.com/LrCLk7rr
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)