Log in to reply
 

Vehicle Turbo Modifier



  • Sorry If I missed this if it has been answered in an existing thread.

    I have having issues with modifying vehicle handling right now. I have everything where I want it in regards to the base handling values in the handling.meta, but the issue I am seeing is when a turbo is applied to the vehicle it is causing to much boost and power to be added. I know how to modify the engine, gearbox and braking in the carcols.meta but for the life of me I can not find anywhere to modify the turbo values or if it is possible.

    Any help would be appreciated!
    Thanks!



  • Paging @ikt as he's into things like these.



  • @Rstein is @ikt here? Probably better luck with @a63nt-5m1th I think.

    @CerberusWolfy
    Until you get a better answer, I can share what the code says, and right or wrong, it seems to say this is just a toggle. State on, State off. Modkit component 18.

    If there is a meta file it's well hidden. There are mods for turbo, so I guess those authors have figured out how to tune it.

    https://www.gta5-mods.com/scripts/turbofix-2

    Probably simulated turbo like this? vehicle34.EngineTorqueMultiplier = 3f; or EnginePowerMultiplier

    Menyoo handles it like this:

    if (ms_turbo_toggle) {
    	if (IS_TOGGLE_MOD_ON(Static_12, 18)) TOGGLE_VEHICLE_MOD(Static_12, 18, 0);
    	else TOGGLE_VEHICLE_MOD(Static_12, 18, 1);
    	return;
    		}
    
    

    Anyway that's all I could find from a script point of view (multipliers for torque and horsepower), could not find any references to turbo in OpenIV.



  • @CerberusWolfy
    I haven't seen any values in the game files to edit the turbo value. Like @JohnFromGWN & the TurboFix mod author say, I think it's just a toggle that adds ~10% etc. Not sure what value it adds that +10% to.

    How much power do you reckon the turbo is adding to your vehicle? Does it feel somewhat like other vehicles, but just a bit too powerful for that exact car, or is it adding really high amounts of power for that one car? If really high amounts added, would seem to me there is something funny going on with that car.

    Maybe play with the 'handling.meta' values as a test & see if you can figure what value the turbo changes. Also, make sure your '<statMods>' in carcols for 'VMT_ENGINE' look somewhat like this (ie make sure the '<modifier value=' isn't set above 100 in any of them, as I've seen funky things happen in the past with 100+ values). If so, test the values below & see if that makes any difference.

    Example:

          <statMods>
            <Item>
              <identifier/>
              <modifier value="25"/>
              <audioApply value="1.00000000"/>
              <weight value="20"/>
              <type>VMT_ENGINE</type>
            </Item>
            <Item>
              <identifier/>
              <modifier value="50"/>
              <audioApply value="1.00000000"/>
              <weight value="20"/>
              <type>VMT_ENGINE</type>
            </Item>
            <Item>
              <identifier/>
              <modifier value="75"/>
              <audioApply value="1.00000000"/>
              <weight value="20"/>
              <type>VMT_ENGINE</type>
            </Item>
            <Item>
              <identifier/>
              <modifier value="100"/>
              <audioApply value="1.00000000"/>
              <weight value="20"/>
              <type>VMT_ENGINE</type>
            </Item>
    

  • MODERATOR

    At full boost, the turbo adds 10% of the current drive force. So if your engine upgrades have added 50%, the turbo applies another 10% on top of that. So if your driveForce was 1.0, the engine mod makes it 1.5, then full boost would be 1.65.

    I don't know where it pulls the 10% from, but the overall way the boost builds is highly unrealistic, so you're better off going NA or if you do want to use a turbo for your handling, consider using TurboFix (which changes how boost builds, and allows changing max boost).

    Also note that the torque "curve" is perfectly flat until 80% of the redline RPM, so that will cause too much torque on the low end, making the car accelerate a bit too fast.



  • @ikt
    This script mod claims to unlock the 10% but I'm guessing it's just simulated?

    Mod is an asi unfortunately.

    https://www.gta5-mods.com/scripts/turbofix-2


  • MODERATOR

    @JohnFromGWN
    At 1.0 "boost", it adds 10% driveforce. The script changes how the "boost" builds and allows it to exceed 1.0 (aka unlock the thing), so you can achieve any amount of added power.



  • @ikt yes, but which native functions are used?


  • MODERATOR

    @JohnFromGWN
    It doesn't use natives for this.



  • @ikt so it would be custom code that interacts with the engine/game asssets?


  • MODERATOR

    @JohnFromGWN
    what even is that question?

    everything is "custom" code



  • @ikt sorry for lack of clarity.

    I know of two ways to interact with the game, through metafiles for configuration and through native functions for RAGE and just about everything else.

    Since native functions and metafiles aren't involved here, I'm guessing that scripting (what I misleadingly referred to as custom code) is used to manipulate engine physics, properties, or methods, independently of the natives.

    I'm also assuming this asi isn't modifying meta files at launch because AFAIK only OpenIV can modify files within encrypted rpfs.

    So I was just curious how this was accomplished. As a non programmer my experience, outside of native functions or SHVDN, is limited to basic C# for reading and writing text files, displaying images, and playing music or sounds with Windows assets like the soundplayer.


  • MODERATOR

    It disables the code from the game that sets the turbo boost value for all vehicles, and then writes to that turbo value itself with the values I want.


Log in to reply
 

Looks like your connection to GTA5-Mods.com Forums was lost, please wait while we try to reconnect.