Jump to content

The GameDaysPassed variable is messed up, looking for a way to fix it.


jimnms

Recommended Posts

In my current game, my hardcore needs stopped updating in real time. I did some searching and found a couple of mods that claimed to fix them, but they didn't work. I then found this post where the last post by Waren_AlKar mentions that the GameDaysPassed variable stops working when it reaches a value of 64, and that is indeed part of the problem. The hardcore needs increase based on this variable.

 

I did some testing and found that there is more to it than it just stopping at 64. The game starts off with this variable set at 5, so I set GameDaysPassed to 5, then waited 10 game minutes and checked the GameDaysPassed variable again. I did this several times and I found that GameDaysPassed is increasing about 1.5x the actual game time. After each 10 game minute wait, the GameDaysPassed variable increased by 15 minutes. The hardcore needs also began updating since GameDaysPassed was now increasing in real-time, and they were increasing faster than they should because of this.

 

That's not the worst part though. I tested GameDaysPassed at other values, and as the value increases, it accumulates at a slower rate until it stops around 64. By the time it reaches a value of 60, it is only accumulating at 8 seconds per game minute. This causes the hardcore needs to increase slower the the longer the game lasts until they stop when GameDaysPassed reaches ~64.

 

Somewhere the game is still keeping track of things because although it doesn't update in real time anymore past a value of 64, it still increases when you sleep, rest or fast travel, which causes the hardcore needs to increase as well when you perform either of those actions. It is also being saved with the game, so when you load a save the GameDaysPassed variable is updated, which is why you might notice your needs have increased from what they were when you made the save.

 

When looking at the variable on the console or what is returned when being read by scripts calling the variable, it only returns a value out to 4 decimal places. My guess is that due to rounding the value up and down to 4 decimal places, as the value increases, it's causing it to increase more slowly the higher it goes until it reaches a certain value where it doesn't round up or takes a very long time to pass before it rounds up by that fraction.

 

My game has already passed 64 GameDaysPassed, so i threw together a quick fix, but I'm trying to think of a more permanent fix. I have briefly explored the GECK looking for what controls the needs to see if it can be separated from the GameDaysPassed variable, but I can't find it. Right now my only idea is to set GameDaysPassed to a high number (64 or higher) at the start of the game and use a script to increase it. This seems like it would be very inefficient though and there has to be a better way.

 

Does anyone know what controls the hardcore needs and is it something that can be edited in the GECK or is it hard coded? I'm looking for ideas on a way to make a fix that will work from the start of the game rather than waiting for it to break.

Link to comment
Share on other sites

Tested the issue a bit with the following in a 1-second quest script:

	let fSome := GetSecondsPassed
	if iStage > 5
		let iStage := 0
		let GameDaysPassed += 5
	endif
	printc "GDP %.8f, GSP %.6f" GameDaysPassed fSome
	let iStage += 1

Results are in the spoiler, and I took a few samples to indicate the differences. For me, it never stopped increasing, but the average value by which it increased did seem to become higher passing the 64 mark.

 

 

  Reveal hidden contents

 

Edited by DoctaSax
Link to comment
Share on other sites

Time scale affects the rates too.

 

64 days is interesting... have you checked the gameday/month ? Sometimes they roll over into illegal values.

 

64 seems to be a recurring number, the game famously has the bethesda 64hz refresh rate bug.

Link to comment
Share on other sites

Possibly related issue I have with the game is that after many days have passed, possibly at that same 64-day mark, the stores begin restocking more rarely. I recently noticed that the actual reason this happens seems to be that the game for some reason has trouble advancing the day of the week at midnight after enough time has passed. Waiting or sleeping past midnight helps with this, but not 100% of the time.

Edited by Crowley9
Link to comment
Share on other sites

  On 7/8/2017 at 4:59 PM, DoctaSax said:

Tested the issue a bit with the following in a 1-second quest script:
	let fSome := GetSecondsPassed
	if iStage > 5
		let iStage := 0
		let GameDaysPassed += 5
	endif
	printc "GDP %.8f, GSP %.6f" GameDaysPassed fSome
	let iStage += 1

Results are in the spoiler, and I took a few samples to indicate the differences. For me, it never stopped increasing, but the average value by which it increased did seem to become higher passing the 64 mark.

 

Where were you when you did your test? When I did my initial testing, I just used the console and wrote down the values reported from there. I did the tests where I was in the game at the time, which was at the radio station northeast of Bitter Springs (Bravo I think).

 

When I was making the script to fix it, I used NVSE's PrintF function to output to a log so I could keep an eye on what was going on and make sure nothing was messing up. I made a few changes to its output format, then I did some more tests last night and things got weirder. I started by setting GameDaysPassed to 20, let it run for a minute then incremented it by 10 up to 100.

 

I'm currently in the Lucky 38 suite, so that's where I ran my test. The GameDaysPassed variable accumulated correctly (well slightly fast) until somewhere between 60 and 70 where it drastically slowed down. It was still accumulating, even at 100, so I just bumped it to 150 and there it completely stopped.

 

That was totally different than what I got from my previous test, but like I said, I was outside when I did that test. I went outside and ran it again. I got about the same results as my initial test It was accumulating about 1.25x faster than it should until it slowed way down at 40 and stopping completely at 70.

 

I dumped the logs to Google Spreadsheets. Here is the indoor test and here is the outdoor test.

Link to comment
Share on other sites

  • 2 months later...

Update: The mod "Timescale Pacemaker" by Asterra was developed specifically to address this issue. See the comments for one on 14 Sep 2017 by DoctaSax which explains the source of the problem (single-precision math using double-precision values).

 

Added 'Issue: GLOB variable 'GameDaysPassed' doesn't advance or suddenly jumps' to "Misc." section in the wiki "Fallout NV Mod Conflict Troubleshooting" guide.

 

-Dubious-

Link to comment
Share on other sites

Thanks dubiousintent, I'll take a look at that. My temporary fix is working for me and I was too busy playing the game to work on a permanent fix. As Red Green said, "this is only temporary, unless it works."

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...