weapon menu using mselection inc - 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)
+--- Thread: weapon menu using mselection inc (
/showthread.php?tid=419632)
weapon menu using mselection inc -
absolute - 01.03.2013
hey everybody...
i wanna create a weapon menu using mselection inc . it compiles successfully but it shows skins pictures instead of weapon one ... and when i choose one of them , it gives the player weapon id 1 only...
how to fix that?
Код:
if(listid == weaplist)
{
if(response)
{
GivePlayerWeapon(playerid, modelid, 99999);
}
else
{
return 0;
}
}
Re: weapon menu using mselection inc -
absolute - 01.03.2013
any help?
Re: weapon menu using mselection inc -
absolute - 01.03.2013
Nobody?!
Re: weapon menu using mselection inc -
Weirdosport - 01.03.2013
The fragment of code you have given is nowhere near substantial enough for anyone to debug your problem. You need to give more code/context.
Re: weapon menu using mselection inc -
absolute - 01.03.2013
oh okay
Код:
//at the top
new weaplist = mS_INVALID_LISTID;
//OnGameModeInIt
weaplist = LoadModelSelectionMenu("weap.txt");
//command
CMD:w(playerid, params[])
{
ShowModelSelectionMenu(playerid, weaplist, "Select Weapon");
return 1;
}
//OnPlayerModelSelection
if(listid == weaplist)
{
if(response)
{
GivePlayerWeapon(playerid, modelid, 99999);
}
else
{
return 0;
}
}
Re: weapon menu using mselection inc -
Weirdosport - 01.03.2013
What is in "weap.txt"?
Re: weapon menu using mselection inc -
absolute - 01.03.2013
the ids of weapons
i use mselection include
Re: weapon menu using mselection inc -
Weirdosport - 01.03.2013
I suggest you take this to the mSelection thread then, as it doesn't appear to be a scripting issue.
Re: weapon menu using mselection inc -
absolute - 01.03.2013
hmm ok