here is some code to give you a hand....
Code:
//init
register_clmd("say", "cmdPM")
public cmdPM(id)
{
if(!get_pcvar_num(toggle_pcvar) )
return PLUGIN_CONTINUE
new args[200]; read_args(args, charsmax(args) )
remove_quotes(args) // take the raw string
if(args[0] == '/') // make sure it starts with a /
{
// This will get the player index from the defined name
new player = cmd_target(id, args[1], CMDTARGET_NO_BOTS)
(!player) ? client_print(id, print_chat, "%L", id, "INVALID_PLAYER", target[1]) : displayInfo(player, id)
}
return PLUGIN_HANDLED_MAIN
}
This will print that it is a command, the user's ID, and the user's name. I'm still working on it....but that's what i have so far. (its going into one of my plugins as well) it should work fine for you.
EDIT: i edited above's code to be better looking, and working for your use. I C/P'd from my code (which includes ML tag- you can remove that) You'll have to define
displayInfo(target, id) yourself to include what you want to display to the caller (id) about the person they want to know (target). It works beautifully, i must say.
__________________