Sari la conținut
Daviid

Advanced vehicle

Recommended Posts

 Features

 

  • Dynamic vehicles - add/edit in-game
  • Ownable vehicles - tune, park, sell to other players, edit license plate
  • Dynamic vehicle dealerships - add/edit in-game
  • Fuel system
  • Dynamic fuel stations - add/edit in-game
  • User-friendly dialogs
  • Full vehicle control - engine, lights, lock, alarm, trunk
  • Vehicle trunk - store weapons (5 slots)
  • Vehicle dashboard - including GPS, health, fuel, engine/alarm/lock status, speedometer (kph or mph)
  • Vehicle mods/paintjob saves
  • Vehicle tracking system - see where your vehicle is on your minimap
Commands

/avshelp - access all the commands available

Player commands:
Code:
/v /vlock /fix /flip /tow /eject /ejectall
/valarm /fuel /trunk /kph /mph /clearmods /sellv /givecarkeys /trackcar
Admin commands:
Code:
/addv /editv /setfuel /rac (respawnallcars) /rtc (respawnthiscar)
/adddealership /deletedealership /movedealership /gotodealership
/addfuelstation /deletefuelstation /movefuelstation /gotofuelstation
Installing

1. Download avs.amx file and put it to your server filterscripts folder
2. Add it to server.cfg

Code:
filterscripts avs
3. Create these folders to scriptfiles

Code:
<server>\scriptfiles\AVS\Vehicles\
<server>\scriptfiles\AVS\Dealerships\
<server>\scriptfiles\AVS\FuelStations\
4. Change the settings in the avs.pwn script (if you want)

pawn Code:
//=========================SETTINGS=========================

#undef MAX_PLAYERS
#define MAX_PLAYERS 100

#define MAX_DVEHICLES 200
#define MAX_DEALERSHIPS 10
#define MAX_FUEL_STATIONS 10

#define VEHICLE_FILE_PATH "AVS/Vehicles/"
#define DEALERSHIP_FILE_PATH "AVS/Dealerships/"
#define FUEL_STATION_FILE_PATH "AVS/FuelStations/"

#define MAX_PLAYER_VEHICLES 3
#define FUEL_PRICE 5
#define GAS_CAN_PRICE 500
#define ALARM_TIME 10000  // alarm duration in milliseconds (1 second = 1000 milliseconds)
#define DEFAULT_NUMBER_PLATE "123 ABC"

//==========================================================

5. Link this FS with your admin system (if you want)

Just add this function to the admin script

pawn Code:
public GetPlayerAVSAdmin(playerid)
{
    return PlayerInfo[playerid][pAdmin];
}


You must use YOUR admin system variable. PlayerInfo[playerid][pAdmin] is just EXAMPLE.
Common Problems

P: Nothing happens when I click a button in dialog.
S: This is most likely caused by ANOTHER filterscript. Quick fix for it is to remove all other filterscripts from server.cfg and try then. If you want to keep them, you must EDIT OTHER FILTERSCRIPTS and make sure the LAST return in OnDialogResponse is 0.

P: I can drive with engine off.
S: Use ManualVehicleEngineAndLights in your GAMEMODE script - 

You don't have permission to view this hidden content


P: I can drive with a dealership vehicle.
S: Admins can drive them, so if you are admin, there is nothing wrong.

P: Server shuts down after adding a vehicle, dealership or fuel station.
S: Make sure you have created the AVS folder inside scriptfiles and also another 3 folders inside AVS (shown above in Installing section step 3)

P: Money doesn't decrease when I buy a vehicle.
S: You are probably using a server-side money for anti-cheat purposes. There is no simple fix for it. You need some scripting knowledge to hook AVS money functions with server-side script.

Credits

Y_Less - sscanf
ZeeX - zcmd

Screenshots
You don't have permission to view this hidden content

 
You don't have permission to view this hidden content
 
You don't have permission to view this hidden content

Download

You don't have permission to view this hidden content

 


 

 

Partajează acest post


Link spre post
Distribuie pe alte site-uri
Vizitator
Acest topic este acum închis pentru alte răspunsuri.

  • Navigare recentă   0 membri

    Nici un utilizator înregistrat nu vede această pagină.

×