Grand Prix 4 No Refueling Patch

Posted by Prblanco 
Grand Prix 4 No Refueling Patch
Date: October 30, 2021 07:53PM
Posted by: Prblanco
Previously exclusive to the 2021 Mod... let me present you the No Refueling Patch:

Surprisingly enough to me, this patch works by changing only 2 bytes of code in GP4.exe. The first one is in regards to fuel at the start of a race. GP4 usually checks for the pit strategy of each car to determine how much fuel to start - if a car is on a 0-stop strategy (which normally happens in 50% distance races or below), then it fills the tank for the whole race. The patch changes a jump instruction to skip the pit strategy check, and go directly to the 0-stop case instead. This only affects starting fuel, and cars will make a stop on the laps specified by the track's magic data. This affects both player and AI.

The second patch is on refueling itself. During a pitstop, GP4 will again check the pit strategy and will determine how much fuel the car needs to leave the pits with. The patch changes a instruction from "update car fuel with calculated fuel" to "update car fuel with existing fuel". This works for AI only since the player can still choose to refuel in the cockpit commands. A side effect is that this makes pits faster - the fuel man will insert the fuel hose and immediately remove it, since there's nothing to be added. On a related note, please check 32BOBO32's No Refuel Animation patch.

What this patch doesn't change: 1) pit strategy, cars will still stop at whatever laps are specified in the magic data, and will change for new sets of tyres. 2) fuel consumption, if magic data for a certain track/mod combination is poorly calibrated, then cars will run out of fuel before the end of a race, and there's no way for the AI to save fuel. 3) tyre changes still take around 5 to 6 seconds.

This is the patch.ini code. You can use this in a CSM mod or with Duffer's Wad Controller, or even change the specified address with an hex editor, to patch your GP4.exe. In the download link here there is also a .cap file for use with CSM.

[Main]
Format=

[V1.00] 
Offset1=0x008806 ; Full tank start (GP4 v1.00)
Code1=0x31
Offset2=0x008BB9 ; Disable pit refuel (AI only) (GP4 v1.00)
Code2=0x56

[V1.02] 
Offset1=0x008833 ; Full tank start (GP4 v1.02)
Code1=0x31
Offset2=0x008BE6 ; Disable pit refuel (AI only) (GP4 v1.02)
Code2=0x56


My unfinished tracks: [www.grandprixgames.org]
Send bug reports and track editing questions to f1virtualblog@gmail.com



Edited 1 time(s). Last edit at 10/30/2021 08:10PM by Prblanco.
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 08:03PM
Posted by: MSchumi24
Thank you Paulo (Y)
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 08:05PM
Posted by: Carl_gpgames
another breakthrough from you! thank you!



GP Files | GP Videos | Discord: Carl_gpgames#2350
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 08:34PM
Posted by: kerleyf1
Thank you Paulo!

------------------------------------------------------------------------------------------------


PLEASE VISIT: Grand Prix Mods Blog
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 08:41PM
Posted by: 32BOBO32
Superb Paulo! Long life elixir for GP4

Samuele
32BOBO32
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 09:38PM
Posted by: superman77m
Prblanco, I take my hat off. It´s FANTASTIC!!! Thank u!

I have a question related to pit stops:

Same as this solution to avoid refueling. Is there a solution to simulate the situation of the 2005 season, to refuel in the race without changing tires?

Thank you a lot for your works.
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 10:31PM
Posted by: quickslick
wow, thank you Paolo for solving another secret of GP4(Y)
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 11:13PM
Posted by: landex
Thank you, Paulo! It makes the mods more realistic. I will test it right now in 1991! Obrigadinho!!:-)
Re: Grand Prix 4 No Refueling Patch
Date: October 30, 2021 11:16PM
Posted by: Öggo
Hats off to you once again Paulo! Absolutely mind-blowing, thank you!

Re: Grand Prix 4 No Refueling Patch
Date: October 31, 2021 12:48AM
Posted by: pauloderpich
Thanks Paulo!
Re: Grand Prix 4 No Refueling Patch
Date: October 31, 2021 02:05AM
Posted by: fongu
Fantastic little tweak that makes a massive difference, for old and newer mods. Thanks Paulo!


Re: Grand Prix 4 No Refueling Patch
Date: October 31, 2021 02:05AM
Posted by: kerleyf1
Thank you Paulo!

------------------------------------------------------------------------------------------------


PLEASE VISIT: Grand Prix Mods Blog
Re: Grand Prix 4 No Refueling Patch
Date: October 31, 2021 06:04AM
Posted by: livejackass
No words to thank. Great work!
Re: Grand Prix 4 No Refueling Patch
Date: October 31, 2021 01:08PM
Posted by: neilcaine
Thanks Paulo, much appreciated
Re: Grand Prix 4 No Refueling Patch
Date: October 31, 2021 03:15PM
Posted by: JRAJ1999
This would be very helpful with mods before 1994.

Awesome work, thank you for keeping this game alive.
Re: Grand Prix 4 No Refueling Patch
Date: November 04, 2021 08:30PM
Posted by: Ali
This is a 'game changer' patch!
I updated the two bytes and the game suddenly had a behaviour like current F1.
Cars start with heavy fuel, full tank and running quite slow. In fact, just before the pit the cars are dramatically slower than after pitting, 3-4 seconds easily in my test at montmelo. Now it's time to fine tune tyre degradation and so on, but now cars are much faster after pit...
Great!
Re: Grand Prix 4 No Refueling Patch
Date: December 16, 2021 11:55PM
Posted by: landex
I must thank Prblanco and 32BOBO32 again.(Y)
After make some races(100%) in the not re-fueling 1986, I must say, its just magnificent. The cars act really different, I had to be careful at the beginning of the race: break earlier, not accelerate to much, be patient...
It tooks some races, now I love it. This feeling its only with race 100% possible. And it shows how Crammond was good! Still waiting for GP5(H)
Thank you, Guys!
Re: Grand Prix 4 No Refueling Patch
Date: December 17, 2021 08:57AM
Posted by: npnc
Thank you very much
Re: Grand Prix 4 No Refueling Patch
Date: December 17, 2021 09:58AM
Posted by: 32BOBO32
landex Scritto:
-------------------------------------------------------
> I must thank Prblanco and 32BOBO32 again.(Y)
> After make some races(100%) in the not re-fueling
> 1986, I must say, its just magnificent. The cars
> act really different, I had to be careful at the
> beginning of the race: break earlier, not
> accelerate to much, be patient...
> It tooks some races, now I love it. This feeling
> its only with race 100% possible. And it shows how
> Crammond was good! Still waiting for GP5(H)
> Thank you, Guys!

Thanks for your feedback mate! Really appreciated!

Samuele
32BOBO32
Re: Grand Prix 4 No Refueling Patch
Date: December 22, 2021 04:52PM
Posted by: Ajayrious
Hi, can someone explain how to use the .cap file with CSM?
Sorry, only registered users may post in this forum.

Click here to login

Maintainer: mortal, stephan | Design: stephan, Lo2k | Moderatoren: mortal, TomMK, Noog, stephan | Downloads: Lo2k | Supported by: Atlassian Experts Berlin | Forum Rules | Policy