[FilterScript] [E.V.O] Elite Vehicle Ownership [V1.0] [Dynamic Vehicle System]
#1

Introduction

I've been working on a Vehicle System for a month now, and after a lot of frustration and help, it's finally done. This is a vehicle system completely scripted from scratch, and I'm happy to share it with you all. By making this script, I've learned a lot of things about programming. I hope you guys enjoy it.

Script

Version: 1.0
Last Update: N/A
Created By: DarkSkull

Features
  • Dynamic creation and removal of vehicles in-game.
  • Saving and loading vehicles.
  • Saves colours, paintjobs and mods.
  • Ability to sell a vehicle to specific player.
  • Ability to change plate.
  • Vehicle calling system.
Commands



Configuration

PHP Code:
#define USERS_PATH "/EVO/users/%s.ini"
#define VEHICLES_PATH "/EVO/vehicles/%d.ini"
#define MAX_OWNABLE_VEHICLES 5
#define DEFAULT_OWNER "Server"
#define DEFAULT_PLATE "ABC123"
#define DEFAULT_PRICE 50000
#define RESPAWN_TIME 5 
#define TELEPORT_TIME 3 
Installation

You will need Zeex compiler patches to compile this script properly without any errors.

See here for download and installation: https://sampforum.blast.hk/showthread.php?pid=2768123#pid2768123

Installation for Includes:

Y_INI: http://forum.sa-mp.com/showpost.php?...99&postcount=2
sscanf2: https://sampforum.blast.hk/showthread.php?tid=570927
ZCMD: https://sampforum.blast.hk/showthread.php?tid=91354


Installation for script:
  1. Download the .rar file.
  2. Extract it in your server folder.
  3. Open your script and adjust the configuration.
  4. Open up your server.cfg and add the following lines.
  5. PHP Code:
    filterscripts EVO 
  6. Done.
Bugs

No bugs have been reported till now.

Please Comment or PM me if you find any.

Notes

1. Do not use CreateVehicle or DestroyVehicle anywhere in this script. It will bug the script like crazy. If you use any car spawner, Use CreateTempVehicle and DestroyVehicleEx to create and remove vehicle.
PHP Code:
CreateTempVehicle(modelFloat:xFloat:yFloat:zFloat:anglecolor1color2respawntime)
DestroyVehicleEx(vehicleid
2. Define MAX_OWNABLE_VEHICLE first and then compile you script. Then only you should join the server.
3. You should create all the vehicles before using CreateTempVehicle.
4. I'm not a professional scripter and there might a lot of inefficiency in this script. Comment or PM me any suggestion that might improve the script. It'll really help me out.

Download

Dropbox

Pastebin

Credits

SA:MP Wiki
****** for Y_INI and sscanf2.
Zeex for ZCMD and Pawn Compiler Patches.
Konstantinos, Misiur, AndySedeyn & ThePhenix for helping me fix bugs.
DarkSkull for this script.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)