25.12.2009, 11:12
Hey,
i have made a 2nd Menu to spawn cars
news
command
GameModeini
Now the the menu...
Errors
warning 225: unreachable code
warning 209: function "OnPlayerSelectedMenuRow" should return a value
error 010: invalid function or declaration
warning
//==========================Bike spawn =========================
// new Menu:Current = GetPlayerMenu(playerid);
// if(Current == autospawn) {
switch(row)
Pls help me....
i have made a 2nd Menu to spawn cars
news
Quote:
new Menu:autospawn; new Menu:bikespawn; |
Quote:
if (strcmp("/bike", cmdtext, true, 10) == 0) { ShowMenuForPlayer(bikespawn, playerid); TogglePlayerControllable(playerid, false); return 1; } |
Quote:
if (strcmp("/auto", cmdtext, true, 10) == 0) { ShowMenuForPlayer(autospawn, playerid); TogglePlayerControllable(playerid, false); return 1; } |
Quote:
autospawn = CreateMenu("~r~Auto Auswahl", 2, 400.0, 100.0, 150.0, 150.0); AddMenuItem(autospawn, 0, "Infernus"); AddMenuItem(autospawn, 0, "Bullet"); AddMenuItem(autospawn, 0, "Sultan"); AddMenuItem(autospawn, 0, "Elegy"); AddMenuItem(autospawn, 0, "Turismo"); ///////////// 2nd menu bikespawn = CreateMenu("~r~Bike Auswahl", 2, 400.0, 100.0, 150.0, 150.0); AddMenuItem(autospawn, 0, "NRG-500"); AddMenuItem(autospawn, 0, "PCJ-600"); AddMenuItem(autospawn, 0, "FCR-900"); AddMenuItem(autospawn, 0, "Sanchez"); AddMenuItem(autospawn, 0, "Freeway"); |
Quote:
[....] [....] [....] case 4: { if(IsPlayerInAnyVehicle(playerid)) { HideMenuForPlayer(bikespawn, playerid); SendClientMessage(playerid,0xffffffff, "Du musst das Auto verlassen, wenn du ein Auto spawnen willst!"); TogglePlayerControllable(playerid, true); } else { new Float:X,Float:Y,Float:Z,Float:Angle, carid; GetPlayerPos(playerid,X,Y,Z); GetPlayerFacingAngle(playerid,Angle); carid = GetPlayerVehicleID(playerid); carid = CreateVehicle(463,X,Y,Z,Angle,-1,-1,600); PutPlayerInVehicle(playerid,carid,0); TogglePlayerControllable(playerid, true); return SendClientMessage(playerid, 0xffffffff, "Bike [Freeway] wurde erfolgreich gespawnt!"); } } } } return 0; } |
warning 225: unreachable code
warning 209: function "OnPlayerSelectedMenuRow" should return a value
error 010: invalid function or declaration
Quote:
Where i get the errors } } } } return 0; } |
//==========================Bike spawn =========================
// new Menu:Current = GetPlayerMenu(playerid);
// if(Current == autospawn) {
switch(row)
Pls help me....