Ghost Car / Race against yourself

Rate:
Downloads: 5
Views: 617
Comments: 0
Category: Scripts
Upload by: ikt

Description

Ghost Car



Want to race... yourself?



The Ghost Car script records your driving and plays it back again, much like the ghost car feature found in many racing games.



Features



- Saves position, rotation and various car tidbits, including tuning.

- Works on any track or location, you just need to place the start and finish lines.

- Automatically saves, loads and replays your fastest lap.

- Stores unsaved laps so you can save them yourself.

- Supports images for tracks, so you know which track you're picking.

- Compatible with tracks from ARS and loads them automatically.

- Useful search function for tracks and replays, so you can find that perfect "Nürburgring GP Endurance Short Loop" run in your "911 GT3RS" that you started a week ago on "Dec 10 21:59:13"



Requirements/Installation

Grand Theft Auto V (1.0.1868.0 or newer)

ScriptHookV

Microsoft Visual C++ 2015-2019 Redistributable (x64)

Extract GhostReplay.asi and the GhostReplay folder to your GTA V folder.



How it works

1. Open the menu using the ghost cheat. (Open the cheat console with the tilde (~) key)

2. Select a track.

3. Select a ghost.

4. Start driving. The ghost will spawn as soon as you cross the start line.

5. Reach the finish. If your lap is faster than the previous ghost, it's automatically saved and loaded again. Repeat from 4 until you get the perfect track time.



From the menu, you can also create tracks (their start and finish lines), remove tracks, remove ghosts, and add unsaved ghosts.



Sharing replays: The files are stored in (GTA V folder)\GhostReplay\Replays and (GTA V folder)\GhostReplay\Tracks. When sharing a replay, make sure to include the track it was made on.



Ghost saving system: When the option to automatically save ghosts is enabled (it is by default), the script will save a ghost replay to disk, and automatically load it for the new replay, when you make a faster lap than the ghost.



When the option is not enabled, or your lap was slower than the ghosts' lap, it will be temporarily stored, but won't be accessible to replay. The temporary recordings will disappear when the game is restarted. You can save these manually in the "Unsaved runs" menu.



Track preview

To get the menu to show a preview image of your track, place a .jpg or .png image file in the Tracks folder. The file should have the same name as the track Name. For example:

Track file: MyTrack23.json

Track name in the json file: My Awesome Track

Correct image name: My Awesome Track.jpg



Track layout: Point-to-point and circuit tracks both work, but there are a few things you should do when creating these:

The start and finish lines need to be made from left to right, from the perspective of the racing direction. This makes sure the lap is only registered if you cross the finish line in the correct direction.

For creating a circuit track, the finish line should come before the start line.



Performance: By default, the script saves points as quickly as possible, which is every frame. If this impacts performance negatively, or you wish to reduce the recordings' size, the Recording timestep can be increased, so the script only takes a sample every x milliseconds. This does decrease accuracy of the recorded play, so don't make it too big.

The ghost replay system smoothens the transition of the ghost, so it won't be jumpy when replayed on a higher frame rate.



Issues

Script causes crashes, doesn't seem to do anything, forgets laps, etc?



In your report, be sure to include the following:



1. GhostReplay.log - found in the GhostReplay folder.

1a. There's no GhostReplay.log? ScriptHookV.log and asiloader.log.

1b. Make sure you have installed the VC2015-2019 redists.

2. A CLEAR AND CONCISE description of:

2a. What actions you were doing - saving a ghost, finishing a race, creating a track, etc.

2b. What the problem is - selected ghost didn't start, selected track doesn't show, car doesn't spawn, etc.

3. The track and replay definition, if available.



Otherwise I will be unable to help you in any way or form.



Source

¯\_(ツ)_/¯

Please do not abuse the Issues for feature requests.



Changelog

1.1.0

Add suspension compression to replay data

Add an option to show a blip for a replay vehicle

Add an option to show a blip for a track

Fix a replay/record issue when crossing both finish and start in the same frame

Fix a duplicate track selection issue when ARS and non-ARS tracks have the same name

Fix a replay selection issue when ARS and non-ARS tracks have the same name (this will invalidate replays made on ARS tracks. Prefix the replay name on ARS tracks with "[ARS] " to get the script to see them again)



1.0.1

Fix physics being applied to replayed ghost, replays are now as accurate as the recording is. Thank you LeeC2202 for pointing this out :)



1.0.0

Initial release
Show Full Description

Rating

0
5
4
3
2
1
Your rate

Write comment:

Please enter review or comment.
Please choose a name.
Email invalid.