Jump to content

How to fix new vegas from crashing more than a drunk driver


gir489

Recommended Posts

So, I've had problems with New Vegas crashing ever since I can remember and no patch to date has ever come close to fixing it. I noticed the problem exacerbated the longer I played the game and the more rooms I went to and that the crashes always happened during loading.


I eventually got tired of the issue and decided to play masters of the universe and actually try and fix the issue myself.


The first issue I noticed was that when loading bald people, it was getting a reference to the hair mesh that didn't exist. I found a fix to this already called Mission Mojave: http://newvegas.nexusmods.com/mods/45104 So, that saved me a bunch of time. Also fixes a bunch of in-game bugs, none of which really bothered me, but it's worth installing just for the crash fix.


Then when I'd get to the loading screen freezes, I didn't really have much to go on, other than what was on the stack prior to EIP stopping.


While I can't track down the true culprit of the freeze, I can find out what's the end result. I found that the player structure is being destructed and recreated each time you're "fast traveling." I noticed that if you have an inherited weapon such as the Proton Axe or a modded weapon, it tends to have old pointers with the new structure and doesn't really create a perfect table. I found this out when one of the modifications in my .44 was pointing to 0xCFCFCFCF. To fix this, before you fast travel, make sure you have your fists out. The fists are the root weapon, and all weapons inherit from this weapon. It doesn't do it all the time, only when the game doesn't create the new structure properly.


Next up on my list-o-crashes was flying monsters. Basically, when the moon is aligned with Jupiter, some NPCs will be spawned after loading with a massive amount of velocity. This is a problem with Fallout not talking to Havok properly and this issue I could not fix without changing the FalloutNV.exe. While I do have a patch for it, I'd probably get sued by Bethesda if I released it, so, sorry, you're SOL on that one. If you're interested in how to fix it, find the area where the engine creates the Havok interface and add a line to create a max velocity of something like 1000. Since there's no driving in the game, there really shouldn't be anything going faster than 1000 units per second. The game's max velocity is like 100,000 units per second, which I think is faster than the speed of sound if you actually translated it to real measurements.


Next up I had improper cell buffer references. This was mainly caused by a plugin that would call PurgeCellBuffers every 10 minutes. DO NOT DO THIS! Purging the cell buffers is great if you have 2K of RAM. The game will destruct cell references when it feels it to be necessary.


Another crash I seen commonly complained about is if you ALT+TAB out of the game, it causes the game to be unstable. The main reason I saw for it was this in the WinMain function.




if ( GetActiveWindow() == v90
|| sub_451530(dword_11DEA10)
|| unknown_libname_14(&unk_11DEB30, v36)
|| *(_BYTE *)sub_408D60(&unk_11DEED8) )
{
v37 = sub_43C4B0();
v38 = sub_4DC020(v37);
v75 = (*(int (__stdcall **)(int))(*(_DWORD *)v38 + 12))(v38);
if ( v75 >= 0 )
{
sub_86E650(dword_11DEA0C);
}
else
{
v39 = sub_43C4B0();
sub_86BA10((void *)v39);
v40 = sub_43C4B0();
sub_86BA90((void *)v40);
Sleep(0x32u);
}
if ( v96 )
{
v96 = 0;
v41 = sub_453A70();
sub_AD8740(v41);
sub_830660();
sub_832AD0(0);
sub_453A70();
sub_AD7740(1u);
if ( (unsigned __int8)sub_446E10() )
{
X = 0;
v71 = 0;
v72 = sub_4DC1F0();
Y = sub_4DC200();
dwStyle = 0;
dwStyle = GetWindowLongA(v93, -16);
AdjustWindowRectEx((LPRECT)&X, dwStyle, 0, 0);
SetWindowPos(v93, 0, X, Y, v72 - X, v71 - Y, 0);
}
}
if ( !v96 && *(_BYTE *)dword_11DEA0C && v75 >= 0 )
{
sub_78D020();
*(_BYTE *)dword_11DEA0C = 0;
}
}
else
{
if ( !v96 )
{
v96 = 1;
if ( !(unsigned __int8)sub_86BDF0() )
{
v42 = GetCurrentThreadId();
if ( v42 == unknown_libname_4(dword_11DEA0C) )
{
sub_78CFC0();
*(_BYTE *)dword_11DEA0C = 1;
}
}
v43 = sub_453A70();
sub_AD8700(v43);
sub_830640();
sub_832AD0(0);
sub_453A70();
sub_AD7740(1u);
v44 = (void *)sub_4E2190(dword_11DEA0C);
sub_B63620(v44);
v45 = (void *)sub_49FEF0();
sub_4A4340(v45);
v46 = (void *)sub_705910();
sub_8026B0(v46);
if ( (unsigned __int8)sub_446E10() )
{
v65 = 0;
v66 = 0;
v67 = sub_4DC1F0();
v68 = sub_4DC200();
v69 = 0;
v69 = GetWindowLongA(v93, -16);
AdjustWindowRectEx((LPRECT)&v65, v69, 0, 0);
SetWindowPos(v93, 0, v65, v68, v67 - v65, v66 - v68, 0);
}
}
Sleep(0x32u);
}



Basically it translates to: If I'm in the game, keep the D3D window active. If I'm not, resize it to 50x50 and pause rendering.


tl;dr don't ALT+TAB. It's bad, m'kay.


Next up isn't really a crash problem, but a problem with Fallout's input system. I've seen tons of people complain that their global hotkeys didn't work for WinAMP or foobar2k. They work for me, but that's probably because I pull up the Steam in-game menu before pressing them. Basically, the only key combination Fallout sends to the OS is CTRL+ALT+DEL, ALT+TAB and ALT+F4. Anything else is sent to the input handling system. You can also fix this yourself by making it send anything that's CTRL+ALT to the OS. This requires a patched exe, sued by Bethesda, yady yady yada.

Edited by gir489
Link to comment
Share on other sites

  • Recently Browsing   0 members

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