Vehicle menu help :P
#1

Hi, i have the script for my own vehicle menu, its just i dont know how to get the vehicle to spawn and how to make it put the player in it at the players location! i will change the commands from teleports to vehicle spawn when i know how to :P

Here is the code, pls help:

Код:
#include <a_samp>

new Menu:OffroadVehicles;

#define FILTERSCRIPT

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
	print("\n----------------------");
	print(" Cameron`s Vehicle menu!");
	print("----------------------\n");
	return 1;
}

public OnFilterScriptExit()
{
	return 1;
}

#else

main()
{
	print("\n----------------------------------");
	print(" Cameron`s Vehicle menu!");
	print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{
	OffroadVehicles = CreateMenu("Offroad Vehicles", 1,270,140,220,0);
	AddMenuItem(VehicleMenu1, 0, "Bandito");
	AddMenuItem(VehicleMenu1, 0, "BF Injection");
	AddMenuItem(VehicleMenu1, 0, "Dune");
	AddMenuItem(VehicleMenu1, 0, "Huntley");
	AddMenuItem(VehicleMenu1, 0, "Landstalker");
	AddMenuItem(VehicleMenu1, 0, "Mesa");
	AddMenuItem(VehicleMenu1, 0, "Monster");
	AddMenuItem(VehicleMenu1, 0, "Sandking");
	AddMenuItem(VehicleMenu1, 0, "Monster A");
	AddMenuItem(VehicleMenu1, 0, "Monster B");
	AddMenuItem(VehicleMenu1, 0, "Rancher");
	AddMenuItem(VehicleMenu1, 0, "Patriot");
	return 1;
}


public OnPlayerCommandText(playerid, cmdtext[])
{
	if(strcmp(cmdtext, "/menu1", true) == 0)
{
	  ShowMenuForPlayer(OffroadVehicles,playerid);
	  return 1;
}
	return 0;
}

if(CurrentMenu == OffroadVehicles)
{
  switch(row)
  {
    case 0: //Bandito
    {
      AddStaticVehicleEx()
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to Grove Street");
    }
    case 1: //BF Injection
    {
      SetPlayerPos(playerid, 1541.2833, -1362.4741, 329.6457);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the top of Starfish Tower");
    }
    case 2: //Dune
    {
      SetPlayerPos(playerid, -2705.5503, 206.1621, 4.1797);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Wheel Arch Angels tuning-shop");
    }
    case 3: //Huntley
    {
      SetPlayerPos(playerid, -2617.5156, 1390.6353, 7.1105);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to Jizzy's Nightclub!");
    }
    case 4: //Landstalker
    {
      SetPlayerPos(playerid, 2028.5538, 1008.3543, 10.8203);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Four Dragons Casino");
    }
    case 5: //Mesa
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 6: //Monster
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 7: //Sandking
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 8: //Sandking
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 9: //Monster A
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 10: //Monster B
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 11: //Rancher
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
    case 12: //Patriot
    {
      SetPlayerPos(playerid, 2169.1838, 1122.5426, 12.6107);
      SetPlayerInterior(playerid, 0);
      SendClientMessage(playerid, 0xFFFFFFFF, "Welcome to the Come-a-Lot casino!");
    }
  }
Reply


Messages In This Thread
Vehicle menu help :P - by CAMERON_BANFIELD - 30.03.2009, 16:50
Re: Vehicle menu help :P - by Dujma - 30.03.2009, 16:54
Re: Vehicle menu help :P - by SaW_[VrTx] - 30.03.2009, 16:59
Re: Vehicle menu help :P - by Dujma - 30.03.2009, 16:59
Re: Vehicle menu help :P - by CAMERON_BANFIELD - 30.03.2009, 17:14
Re: Vehicle menu help :P - by illay - 30.03.2009, 18:26
Re: Vehicle menu help :P - by CAMERON_BANFIELD - 30.03.2009, 18:26

Forum Jump:


Users browsing this thread: 1 Guest(s)