Car Ownership -
MichiCZ - 21.11.2012
Hi, this is my first Include.
Introduction:
This include allows you to buy and manage your own vehicle.
Procedure:
1. Copy pastebin save as "PCar.inc"
2. The .inc file copy to folder "includes"
3. Now open our GM/FS and paste
#include <PCar>
a) PCar_DialogResponse(playerid,dialogid,response,lis titem); to public OnDialogResponse
b) PCar_PlayerConnect(playerid); to public OnPlayerConnect
c) PCar_PlayerDisconnect(playerid); to public OnPlayerDisconnect
d) PCar_VehicleDeath(vehicleid); to public OnVehicleDeath
e) PCar_OnPlayerCommandText(playerid, cmdtext); to public OnPlayerCommandText
Create folder "PCars" in "scriptfiles" folder
The pastebin is a sample script usage
Another approach can be found in the video!
Commands:
/vehicles - Show list of your vehicles
/park - Park vehicle at its current position
Video: http://www.youtube.com/watch?v=2oLGG...ature=*********
Download: http://pastebin.com/fNTfaZwG
Rate & Comments please
I'm from Czech republic, excuse my English
Re: Car Ownership -
[NWD]Jim._.Carrey - 22.11.2012
Very good!
Re: Car Ownership -
TheArcher - 23.11.2012
Did you think if the ID 123 on dialogs is already used? The value is too low and often its already used on gamemodes.
Re: Car Ownership -
MichiCZ - 24.11.2012
Dialog ID 123 I used just to test, feel free to change it
// Video Uploaded
Re: Car Ownership -
matiasmunk - 26.11.2012
Okay I edited the script and such, now I finally got it to work.
But /Park, doesn't change the spawnX,Y,Z, & A for the vehicle. It comes back to where I bought it.
Any ideas?
Re: Car Ownership -
MichiCZ - 26.11.2012
Change coords:
BuyCarForPlayer(playerid,vehiclemodelid,SpawnX,Spa wnY,SpawnZ,SpawnFacingAngle,Cost);
Re: Car Ownership -
matiasmunk - 27.11.2012
Yeah, that's not really what I meant.
I meant, when you type /park, it says that the position is saved.
But when I restart the server, it's back at bought spawn.
Re: Car Ownership -
matiasmunk - 08.12.2012
Any help?