My menu is crashing my server :'( - 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: My menu is crashing my server :'( (
/showthread.php?tid=92075)
My menu is crashing my server :'( -
[mad]MLK - 18.08.2009
ok so basicaly i was getting the problem were when people come onto my server with a admins previous id they got there admin level too so i intergreated serif admin into my gamemode and everything works perfect now but my nrg menu crashes the server but before the server crashes i get the menu apearing then crash heres the ment code:
Код:
public OnPlayerSelectedMenuRow(playerid, row)
{
new Menu:CurrentMenu = GetPlayerMenu(playerid);
if(CurrentMenu == NRGSTUNTS)
{
switch(row)
{
case 0: //Groove nrg
{
SetPlayerPos(playerid, 2493.9133, -1682.3986, 13.3382);
SetPlayerInterior(playerid, 0);
SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to NRG-Stunt 1 by Linx");
}
case 1: //Neer river nrg
{
SetPlayerPos(playerid, 1901.6283,-539.0392,21.5788);
SetPlayerInterior(playerid, 0);
SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to NRG-Stunt 2 by Linx");
}
case 2: //Wheel Arch Angels
{
SetPlayerPos(playerid, -2705.5503, 206.1621, 4.1797);
SetPlayerInterior(playerid, 0);
SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the NRG-Stunt 3 by");
}
}
}
return 1;
}
Any ideas ?
Код:
NRGSTUNTS = CreateMenu("Nrg Stunts", 2, 200.0, 100.0, 150.0, 150.0);
AddMenuItem(NRGSTUNTS, 0, "NRG STUNT 1");
AddMenuItem(NRGSTUNTS, 0, "NRG STUNT 2");
AddMenuItem(NRGSTUNTS, 0, "NRG STUNT 3");
<thats the on gamemode innit part and heres the top of the code the new parts :
Re: My menu is crashing my server :'( -
dice7 - 18.08.2009
try
pawn Код:
NRGSTUNTS = CreateMenu("Nrg Stunts", 1, 200.0, 100.0, 150.0, 150.0);
since you're only using one row
Re: My menu is crashing my server :'( -
Luca Dimonte - 18.08.2009
Your menu shows one column, not two, so I would change to this
NRGSTUNTS = CreateMenu("Nrg Stunts", 1, 200.0, 100.0, 150.0, 150.0);
Another thing I would add is to hide the menu first and then teleport the player.
Re: My menu is crashing my server :'( -
[mad]MLK - 18.08.2009
THANKS

worked a treat, added both you're forum names to the /credits cmd
Re: My menu is crashing my server :'( -
[mad]MLK - 20.08.2009
now its only showing one option its only showing nrg stunt one? :O