12.07.2011, 01:00
How could i do an Automatic command? Like the System types the Command not you?
I want it to automatically type /chooseclass
I want it to automatically type /chooseclass
forward Function(any params here);
public Function(same params)
{
stuff to do;
}
if(strcmp("/ChooseClass", cmdtext, true, 10) == 0)
{
ShowPlayerDialog(playerid,699,DIALOG_STYLE_LIST,"Choose Class","Sniper Class\nAssualt Class\nRocket Class ($150)\nPilot Class ($200)\n","Accept", "Exit");
return 1;
}
OnPlayerCommandText(playerid, "/chooseclass");
//top of script
forward chooseclass{};
//somewhere, could be bottom, idc
public chooseclass{}
{
for(new i = 0; i <= MAX_PLAYERS; i++)
{
ShowPlayerDialog(i,699,DIALOG_STYLE_LIST,"Choose Class","Sniper Class\nAssualt Class\nRocket Class ($150)\nPilot Class ($200)\n","Accept", "Exit");
}
return 1;
}