Handling Replacement (Library) 1.1.0
3,754
52
3,754
52
Handling Replacement is a library/tool for script developers, to manage vehicle handling changes in a non-intrusive way. It clones the handling of a vehicle, and assigns the copy to the vehicle, so only that vehicle is affected by changes to its handling data.
This is useful for scripts that want to continuously vary certain handling parameters, without affecting other instances of that vehicle model.
An example is my variable drive bias, which changes fDriveBiasFront constantly.
Installation
Grand Theft Auto V (b1868+) required.
Extract HandlingReplacement.asi to GTA V's main folder.
Development
Check HandlingReplacement.h on the repository for the three functions. The asi loader should already have loaded and initialized things, so one can just start using it right away.
An usage example can also be found there.
GitHub repository
If you have any questions, hop on my Discord server.
Compatibility
The following list shows scripts currently using this library and what fields they access. Please let me know when you want to use the library, I'll update the list so you know what fields might be affected.
Acknowledgements
FiveM - On some bits on how to properly replace/clone subhandlingdata, and the rage alloc/free.
Changelog
1.1.0
* Compatibility patch for game version v1.0.2845.0 and newer
* Tested on v1.0.3337.0
Remarks:
This is a worse solution than 1.0.0:
* Leaks 1.5kB memory every instance (memory does not deallocate)
* SubHandlingData is NOT replaced anymore, the original instance is active
This is due prior method of re-using FiveM's usage of using GTA V's allocator not being functional anymore (after... 2845), and me having not the slightest clue how to properly do this again. I just need a release out of the door to fix Manual Transmission crashing upon usage of dynamic AWD, and this (sloppily) fixes it.
If you know how GTA V's allocator can be used, I'd be happy to hear it and release a proper update. Check https://github.com/ikt32/GTAVHandlingReplacement for the source code.
1.0.0
Initial release
This is useful for scripts that want to continuously vary certain handling parameters, without affecting other instances of that vehicle model.
An example is my variable drive bias, which changes fDriveBiasFront constantly.
Installation
Grand Theft Auto V (b1868+) required.
Extract HandlingReplacement.asi to GTA V's main folder.
Development
Check HandlingReplacement.h on the repository for the three functions. The asi loader should already have loaded and initialized things, so one can just start using it right away.
An usage example can also be found there.
GitHub repository
If you have any questions, hop on my Discord server.
Compatibility
- Changes made to the original CHandlingData instance activation on a vehicle, will not be applied to that vehicle any more
- Changes made to the CHandlingData from the vehicle instance itself, will apply normally. These changes do not propagate to the original CHandlingData instance.
- As with the default method of directly changing handling data, other scripts can interfere when multiple scripts are setting the same fields.
- No CHandlingData is provided, use your own one.
The following list shows scripts currently using this library and what fields they access. Please let me know when you want to use the library, I'll update the list so you know what fields might be affected.
- Manual Transmission - (5.0.0)
- fDriveBias - constantly written to when variable AWD is enabled
- Real Time Handling Editor - (2.0.1)
- Everything - depending on setting, original or replaced handling may be edited at any time
- (Your script) - (Starting version using it)
- (CHandlingData field) - set constantly, periodically, occasionally
Acknowledgements
FiveM - On some bits on how to properly replace/clone subhandlingdata, and the rage alloc/free.
Changelog
1.1.0
* Compatibility patch for game version v1.0.2845.0 and newer
* Tested on v1.0.3337.0
Remarks:
This is a worse solution than 1.0.0:
* Leaks 1.5kB memory every instance (memory does not deallocate)
* SubHandlingData is NOT replaced anymore, the original instance is active
This is due prior method of re-using FiveM's usage of using GTA V's allocator not being functional anymore (after... 2845), and me having not the slightest clue how to properly do this again. I just need a release out of the door to fix Manual Transmission crashing upon usage of dynamic AWD, and this (sloppily) fixes it.
If you know how GTA V's allocator can be used, I'd be happy to hear it and release a proper update. Check https://github.com/ikt32/GTAVHandlingReplacement for the source code.
1.0.0
Initial release
First Uploaded: August 01, 2020
Last Updated: September 29, 2024
Last Downloaded: 19 hours ago
14 Comments
More mods by ikt:
Handling Replacement is a library/tool for script developers, to manage vehicle handling changes in a non-intrusive way. It clones the handling of a vehicle, and assigns the copy to the vehicle, so only that vehicle is affected by changes to its handling data.
This is useful for scripts that want to continuously vary certain handling parameters, without affecting other instances of that vehicle model.
An example is my variable drive bias, which changes fDriveBiasFront constantly.
Installation
Grand Theft Auto V (b1868+) required.
Extract HandlingReplacement.asi to GTA V's main folder.
Development
Check HandlingReplacement.h on the repository for the three functions. The asi loader should already have loaded and initialized things, so one can just start using it right away.
An usage example can also be found there.
GitHub repository
If you have any questions, hop on my Discord server.
Compatibility
The following list shows scripts currently using this library and what fields they access. Please let me know when you want to use the library, I'll update the list so you know what fields might be affected.
Acknowledgements
FiveM - On some bits on how to properly replace/clone subhandlingdata, and the rage alloc/free.
Changelog
1.1.0
* Compatibility patch for game version v1.0.2845.0 and newer
* Tested on v1.0.3337.0
Remarks:
This is a worse solution than 1.0.0:
* Leaks 1.5kB memory every instance (memory does not deallocate)
* SubHandlingData is NOT replaced anymore, the original instance is active
This is due prior method of re-using FiveM's usage of using GTA V's allocator not being functional anymore (after... 2845), and me having not the slightest clue how to properly do this again. I just need a release out of the door to fix Manual Transmission crashing upon usage of dynamic AWD, and this (sloppily) fixes it.
If you know how GTA V's allocator can be used, I'd be happy to hear it and release a proper update. Check https://github.com/ikt32/GTAVHandlingReplacement for the source code.
1.0.0
Initial release
This is useful for scripts that want to continuously vary certain handling parameters, without affecting other instances of that vehicle model.
An example is my variable drive bias, which changes fDriveBiasFront constantly.
Installation
Grand Theft Auto V (b1868+) required.
Extract HandlingReplacement.asi to GTA V's main folder.
Development
Check HandlingReplacement.h on the repository for the three functions. The asi loader should already have loaded and initialized things, so one can just start using it right away.
An usage example can also be found there.
GitHub repository
If you have any questions, hop on my Discord server.
Compatibility
- Changes made to the original CHandlingData instance activation on a vehicle, will not be applied to that vehicle any more
- Changes made to the CHandlingData from the vehicle instance itself, will apply normally. These changes do not propagate to the original CHandlingData instance.
- As with the default method of directly changing handling data, other scripts can interfere when multiple scripts are setting the same fields.
- No CHandlingData is provided, use your own one.
The following list shows scripts currently using this library and what fields they access. Please let me know when you want to use the library, I'll update the list so you know what fields might be affected.
- Manual Transmission - (5.0.0)
- fDriveBias - constantly written to when variable AWD is enabled
- Real Time Handling Editor - (2.0.1)
- Everything - depending on setting, original or replaced handling may be edited at any time
- (Your script) - (Starting version using it)
- (CHandlingData field) - set constantly, periodically, occasionally
Acknowledgements
FiveM - On some bits on how to properly replace/clone subhandlingdata, and the rage alloc/free.
Changelog
1.1.0
* Compatibility patch for game version v1.0.2845.0 and newer
* Tested on v1.0.3337.0
Remarks:
This is a worse solution than 1.0.0:
* Leaks 1.5kB memory every instance (memory does not deallocate)
* SubHandlingData is NOT replaced anymore, the original instance is active
This is due prior method of re-using FiveM's usage of using GTA V's allocator not being functional anymore (after... 2845), and me having not the slightest clue how to properly do this again. I just need a release out of the door to fix Manual Transmission crashing upon usage of dynamic AWD, and this (sloppily) fixes it.
If you know how GTA V's allocator can be used, I'd be happy to hear it and release a proper update. Check https://github.com/ikt32/GTAVHandlingReplacement for the source code.
1.0.0
Initial release
First Uploaded: August 01, 2020
Last Updated: September 29, 2024
Last Downloaded: 19 hours ago
This file has been approved automatically. If you think this file should not be here for any reason please report it.
Very nice! Thank you
This looks interesting.
We could have a more advanced vehicle modification system for performance parts with this, rather than the dumbed down one GTA has. You could do a whole bunch of engine mods like in Forza, as well as tuning.
@nkjellman
Engine power seems to be one of those things that don't instantly apply.
Suspension though, yes.
@ikt So to make the engine power modifier apply, one would have to exit/enter the car?
@DirtSpray
Either fixing it or just respawning the entire vehicle.
There are other ways to change engine power in real-time.
@ikt Ty for the info, though, I am not smart enough to make this mod work, I have taken a look at the usage example, but still, I do not know how to work it...
@DirtSpray
It's a library and can be used in C/C++/C#
@ikt Oh, so one would need some experience in coding to properly play with this?
@DirtSpray
Hmmm, yeah, that's what the description says:
> Handling Replacement is a library/tool for script developers, to manage vehicle handling changes in non-intrusive way.
So it's for usage in other scripts.
@ikt Oh, ok, still, I think that this has potential to be one hell of an amazing and popular "In-Depth Real-Time Performance tuning" mod in the future whose greatest feature is applying custom handling to one instance of a vehicle! Just an idea... ;)
@ikt hi, please how to do for use it in c# ?
Note:
This will crash the script using it in newer game versions. I recommend to stick to b2372 and not update much beyond it.
Update 1.1.0:
* Compatibility patch for game version v1.0.3095.0 and newer
* Tested on v1.0.3337.0
Remarks:
This is a worse solution than 1.0.0:
* Leaks 1.5kB memory every instance (memory does not deallocate)
* SubHandlingData is NOT replaced anymore, the original instance is active
This is due prior method of re-using FiveM's usage of using GTA V's allocator not being functional anymore (after... 2802?), and me having not the slightest clue how to properly do this again. I just need a release out of the door to fix Manual Transmission crashing upon usage of dynamic AWD, and this (sloppily) fixes it.
If you know how GTA V's allocator can be used, I'd be happy to hear it and release a proper update. Check https://github.com/ikt32/GTAVHandlingReplacement for the source code.