SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help > Help Archive

 
 
Thread Tools Display Modes
Old 20/07/2011, 11:59 PM   #1
iGetty
High-roller
 
iGetty's Avatar
 
Join Date: Sep 2010
Location: Falkirk, Scotland
Posts: 1,753
Reputation: 224
Default /help

How can I make a command like this:

pawn Code:
command(help, playerid, params)
{
      Here will be, say you did /help [WORD], and when you chose the word, it shows information, like this:

       /help commands

It would show the commands help, and how could I do it for like, 6 different things?
return 1;
}

Thanks.
iGetty is offline  
Old 21/07/2011, 12:10 AM   #2
[HiC]TheKiller
High-roller
 
Join Date: Mar 2008
Location: New Zealand
Posts: 2,630
Reputation: 409
Default Re: /help

Use the example located HERE
__________________
[HiC]TheKiller is offline  
Old 21/07/2011, 12:12 AM   #3
iGetty
High-roller
 
iGetty's Avatar
 
Join Date: Sep 2010
Location: Falkirk, Scotland
Posts: 1,753
Reputation: 224
Default Re: /help

That explains nothing to do with what I want..
iGetty is offline  
Old 24/07/2011, 08:53 PM   #4
PrawkC
Huge Clucker
 
Join Date: May 2011
Posts: 485
Reputation: 52
Default Re: /help

pawn Code:
CMD:help(playerid, params[])
{
    new option[24];
    if(sscanf(params, "s[24]", option))
    {
        SendClientMessage(playerid, -1, "Syntax: /help option");
        SendClientMessage(playerid, -1, "Options: vehicle, etc, etc ,etc");
        return 1;
    }
    if(!strcmp(option, "vehicle", true))
    {
        SendClientMessage(playerid, -1, "Heres your vehicle help!");
    }
    else return SendClientMessage(playerid, -1, "That option doesn't exist!");
    return 1;
}

Should be straight forward on how to add more


Edit: lol just noticed this was an old topic, hadn't closed this tab! lol.
__________________
Doin' stuff.
PrawkC is offline  
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT. The time now is 08:13 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.