/weater - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: /weater (
/showthread.php?tid=149780)
/weater -
W00Z - 23.05.2010
Hi! I have a code on the command / weather? Then show me a dialog box in which I enter ID weather.
Re: /weater -
Hiddos - 23.05.2010
Use ShowPlayerDialog with style 1.
Re: /weater -
TKZ227 - 23.05.2010
I'll create one real fast.
Код:
if(strcmp(cmd, "/weather", true) == 0)
{
if(IsPlayerAdmin(playerid))
{
ShowPlayerDialog(playerid, DIALOG_STYLE_INPUT, "Change Weather", "Type the weather ID below!", "Change", "Cancel");
}
}
I'm still a nooby scripter, sorry if I made a mistake :S
Re: /weater -
Hiddos - 23.05.2010
Quote:
Originally Posted by TKZ227
I'll create one real fast.
Код:
if(strcmp(cmd, "/weather", true) == 0)
{
if(IsPlayerAdmin(playerid))
{
ShowPlayerDialog(playerid, DIALOG_STYLE_INPUT, "Change Weather", "Type the weather ID below!", "Change", "Cancel");
}
}
I'm still a nooby scripter, sorry if I made a mistake :S
|
Should work, you only forgot the dialog id..
pawn Код:
public OnPlayerDialogResponse(blablablablablaspam)//Recommended not to copy this
{
if(dialogid == weatherid)//change that to your own
{
SetWeather(strval(inputtext));
}
return 1;
}