VOGONS


First post, by V15UAL K3YS

User metadata
Rank Newbie
Rank
Newbie

Hey,

I've been taking advantage of the awesome fact that dgVoodoo 2 now has DirectX 9.0 support for DirectX 9 games, and have been using it to see if I could successfully run it on The Sims 2. The game is originally plagued with many issues when running it on modern PCs, and my current issue I had with it was because of the infamous "flashing pink" issue; no matter what fixes I applied and no matter what I tried (which was literally everything I could find) nothing worked.

When I had found out about the newly implemented DX9 support I tried to see if I could work around this issue using dgVoodoo 2. The game loads up and runs only when I load up the game using the ATI Radeon 8500 graphics card, which is one of the supported graphics cards in the game. However, I get a "flashing red" issue with the sims and they do the same thing as with the flashing pink issue, except that they flash red instead. If I try using the GeForce4 Ti 4800 it immediately crashes on startup and if I use the FX 5700 it crashes when loading a neighborhood. I have also entered the vendor and device id for my actual graphics card (GeForce GTX 1080Ti) into the dgVoodoo.conf file, ran the game using the Internal 3d Graphics Driver that is built into dgVoodoo 2 and it still crashes upon loading the neighborhood, with an EXCEPTION log created in the Logs folder of The Sims 2. It is having an ACCESS VIOLATION and the module is the user32.dll file. This doesn't happen when I load it up using the ATI Radeon 8500 video card in the dgVoodoo 2 control panel, but as mentioned above, that video card won't work.

I have attached both the exception log and the dgVoodoo config file to check out. I should also note I am using the DVD version of the game and have all the expansion packs, so I am running the game from the Sims2EP9.exe file. Any help would be greatly appreciated 😀

SPECS:
GPU: NVIDIA GeForce GTX 1080Ti
CPU: Intel i7-7700k
RAM: 32GB DDR4 2400MHz
OS: Windows 10 x64

Attachments

  • Filename
    dgVoodoo.conf
    File size
    13.66 KiB
    Downloads
    146 downloads
    File comment
    dgVoodoo Config File
    File license
    Fair use/fair dealing exception
  • Filename
    Sims2Exception 2019.07.31 21.31.15.txt
    File size
    15.02 KiB
    Downloads
    120 downloads
    File comment
    Exception Log
    File license
    Fair use/fair dealing exception

Reply 1 of 17, by Dege

User metadata
Rank l33t
Rank
l33t

Weird. It runs for me.
It can be run in either forced windowed mode (like on the attached screenshot) or in fullscreen with option GeneralExt\EnableGDIHooking enabled.

I can't see a single reason though why this game should be played through dgVoodoo.
Sims2 is completely software rendered. It only uses D3D9 to set the display mode (800x600) and do its vertex shading calculations through D3D9 in software, which literally means multiplying some vectors by a transformation matrix ( 😁 😁) for most cases. No GPU is involved at all.

So, the rendering technique of this game in itself is really weird. No dgVoodoo needed.

Sims2.png

Reply 2 of 17, by V15UAL K3YS

User metadata
Rank Newbie
Rank
Newbie
Dege wrote:
Weird. It runs for me. It can be run in either forced windowed mode (like on the attached screenshot) or in fullscreen with opti […]
Show full quote

Weird. It runs for me.
It can be run in either forced windowed mode (like on the attached screenshot) or in fullscreen with option GeneralExt\EnableGDIHooking enabled.

I can't see a single reason though why this game should be played through dgVoodoo.
Sims2 is completely software rendered. It only uses D3D9 to set the display mode (800x600) and do its vertex shading calculations through D3D9 in software, which literally means multiplying some vectors by a transformation matrix ( 😁 😁) for most cases. No GPU is involved at all.

So, the rendering technique of this game in itself is really weird. No dgVoodoo needed.

I'm sorry but I believe you are mistaken. The game will run in software rendering mode when using the internal 3d graphics card in the dgVooodoo 2 control panel because The Sims 2 doesn't detect that graphics card in the game's database. Therefore, the game assumes that the PC in question doesn't have a GPU and therefore forces the game to run in software rendering mode.

To prove this, I have uploaded a screenshot of me running the Sims 2 in Hardware rendering mode, using the ATI Radeon 8500 graphics card in dgVoodoo 2 (which is a GPU supported by the Sims 2) with all settings maxed out and in 800x600 resolution. With GDI Hooking enabled, I can also run this game at 1440p resolution effortlessly; the only problem that still remains is the graphics glitches that I have mentioned.

This is why I stated that I put the vendor id and device id in the dgVoodoo 2 config file. You have to do this when using the internal 3d graphics card in dgVoodoo 2 so that the game can recognize that there is a graphics card. Not doing this will cause the game to run only in software rendering mode.

This website: https://www.simsnetwork.com/tools/graphics-rules-maker
Has a program called "Graphics Rules Maker" and if you are running a modern system and are trying to play the Sims 2, you have to use this tool; there is a manual way to do it but basically, the program registers your current GPU into The Sims 2 system files so that the game properly detects your graphics card and runs it in hardware rendering mode. This goes back to why I decided to try to use dgVoodoo 2 to run the Sims 2, which in Hardware Rendering mode, has an infamous issue known as "pink flashing" where certain sims, houses, neighborhoods, etc, will flash pink because of shader file issues and GPU memory problems. It's in the game itself. I hope that helps to clarify some things. 😀

Attachments

  • The Sims 2 Hardware Rendering.png
    Filename
    The Sims 2 Hardware Rendering.png
    File size
    1 MiB
    Views
    5794 views
    File comment
    Hardware Rendering Screenshot
    File license
    Fair use/fair dealing exception

Reply 3 of 17, by V15UAL K3YS

User metadata
Rank Newbie
Rank
Newbie

UPDATE!

I have successfully managed to get farther with hardware rendering in the Sims 2, but it was only with dgVoodoo 2.6. The lack of HLSL support in 2.6.1 makes it impossible to properly run The Sims 2 with Hardware Rendering, so I had to revert back to 2.6 to properly run it.

In the dgVoodoo.conf file, you have to set ShaderCodeGenerating = 2 and use the d3dcomplier_43 and d3dcomplier_47 in the file where the Sims 2 executable is. Without using this the game has an issue with the DirectX 9 calls being made by dgVoodoo 2 itself and therefore crashes upon loading the neighborhood (the game apparently doesn't like the internal shader code generator). By using this though, I have successfully managed to load the neighborhood with the Internal 3d Virtual Card and thus have gotten farther.

Here is an image of me doing so, running Sims 2 in 1440p with all settings maxed out. Sims-2-1440p.png

However, this leads me to another issue. With ShaderCodeGenerating = 2 (using the internal shader code in any way makes the game unplayable) I can finally load a sim in Create A Sim without the game crashing. However, I do get serious graphical issues and this impairs my ability to play the game. I have uploaded an image of such graphical issues to further clarify. It doesn't look as extreme in the image as it is a still shot but the textures are constantly glitching and the areas where the glitched textures should be are completely invisible. However, I have not yet seen the red-flashing issue I have mentioned earlier and it only appears in the game's thumbnails.

Attachments

  • Sims 2 Graphic Glitches.png
    Filename
    Sims 2 Graphic Glitches.png
    File size
    639.5 KiB
    Views
    5658 views
    File comment
    Sims 2 Graphic Glitches
    File license
    Fair use/fair dealing exception

Reply 7 of 17, by Dege

User metadata
Rank l33t
Rank
l33t

Ok, I found a bug in the code generator that causes the crash and another causing the polygon corruption.

As for the flashing pink issue: when it occurs then the game draws with a vs/ps pair that transform a single position vector and emits a constant color.
I don't know what the appearance of the problem is relying on but it seems, as if some textures or other needed objects couldn't be loaded earlier and the renderer fell back to some very primitive shaders. Or sg like that. According to my observation the game eats up a lot of the address space with "too much" video memory available. And probably can't create all of its objects later.

Anyway, I think I managed to make it work: I selected the GF 5700 Ultra with 128MB. It's a card from 2004 with SM2.x support, contemporary of the game.
I played the game for some time (mainly the tutorial levels) with my limited knowledge and experience and it worked fine, no flashing red/pink polygons appeared (unlike with the internal card with much video memory).
But, it may appears after playing for, say, more than a half an hour, or with some very complex scene. I'm not sure. 😖

Reply 8 of 17, by V15UAL K3YS

User metadata
Rank Newbie
Rank
Newbie
Dege wrote:
Ok, I found a bug in the code generator that causes the crash and another causing the polygon corruption. […]
Show full quote

Ok, I found a bug in the code generator that causes the crash and another causing the polygon corruption.

As for the flashing pink issue: when it occurs then the game draws with a vs/ps pair that transform a single position vector and emits a constant color.
I don't know what the appearance of the problem is relying on but it seems, as if some textures or other needed objects couldn't be loaded earlier and the renderer fell back to some very primitive shaders. Or sg like that. According to my observation the game eats up a lot of the address space with "too much" video memory available. And probably can't create all of its objects later.

Anyway, I think I managed to make it work: I selected the GF 5700 Ultra with 128MB. It's a card from 2004 with SM2.x support, contemporary of the game.
I played the game for some time (mainly the tutorial levels) with my limited knowledge and experience and it worked fine, no flashing red/pink polygons appeared (unlike with the internal card with much video memory).
But, it may appears after playing for, say, more than a half an hour, or with some very complex scene. I'm not sure. 😖

I see. I'm glad that we are making progress! 😎 😁

I downloaded your new WIP build and I gave Sims 2 a go again. I can run the game in 1440p with the new WIP thanks to the bug fixes you implemented no problem. Ran the game at 1440p with all settings maxed out using the internal 3d video card and 2048 MB VRAM. Played the game for over an hour on a lot and had no visible graphics bugs as of yet, no pink flashing either (it strangely appears in thumbnails sometimes but it didn't appear as I was playing a lot with sims). This is the furthest I have ever gotten in this game and it is cool to be able to play it maxed out without any graphical glitches or issues atm.

I think your VRAM issue is also related to the game internally. The game will automatically force the game to run with only 32MB of VRAM because it's in the game's graphics configuration files. If you go to My Documents/EA Games/The Sims 2/Logs/ there is a log file named *your pc name*-config-log.txt and it will log certain events that go on in the game. You can tell if your graphics memory is being limited if you go under "===graphics device info===" and see "Texture memory: 32MB"

This is how to fix that issue.

Go into your main Sims 2 game directory where the game executable folder is (not where the .exe is located but the folder that is outside of that where you see CSBin, TSBin, TSData, and a few other files). Go into this directory "TSData/Res/". You'll see a Config and CSConfig folder. Open the Config folder and you'll see a file called Graphics Rules.sgr

You can open this file with notepad, and you'll see a section that starts with "# Identify gfx device" and another section following it saying "# Configuration override controlled by command line option -cardConfig". Before the latter section and after the "endif" in the "# Identify gfx device" section, add this line:
# GraphicsRulesMaker Tweak: Force memory size
seti textureMemory 2048

That way the game is forced to allocate 2GB of VRAM for loading textures, and the game properly registers it to use 2GB of VRAM as in the dgVoodoo 2 internal gpu, instead of making the game use a sleazy 32MB. Save this graphics rules.sgr file (make a backup of course 🤣) and copy this file over to the other CSConfig folder as well, overwriting that Graphics Rules.sgr too. This way, the game is essentially forced to allocolate that ram and make the game run better.

That is the way to do it manually. You can go onto this website to see other fixes for the Sims 2 to get it to work its best on Windows 10. Hope this helps, (and with your programming knowledge maybe there are things you can find in this Graphics Rules.sgr file that I can't 🤣).
https://pleasantsims.com/sims-2-windows-10/

Reply 10 of 17, by V15UAL K3YS

User metadata
Rank Newbie
Rank
Newbie
Dege wrote:

Thanks, that's an extensive description. Didn't yet try it but I think you have noteworthy knowledge about this game. 😀

With this game, you kind of have to have it 🤣. This game is a pain to properly get running correctly on modern systems.

Reply 11 of 17, by ghost28

User metadata
Rank Newbie
Rank
Newbie

Dege,

is it possible to fool game thinking i'm using 60hz supported screen or 60hz screen? problem is my monitor(it's laptop)120hz only.some games including this one only works when i'm connected to 60hz supported screen.otherwise it gave me "failed to find dx9 supported card" error on this game(others crash normally/not boot).-w works but doesn't recognize my card or dgvoodoo selected card locked at 320 resolution.(and i think performance bad too)is there a way to bypass this? i tried "enumerate refresh rate" didn't work.maybe i selected wrong? what do you think?

Reply 12 of 17, by Dege

User metadata
Rank l33t
Rank
l33t

What if you set the resolution on DX tab to 'unforced, 60'? This way you aren't overriding the resolution coming from the game but forcing the refresh rate(s) to be enumerated to the game as 60Hz ('Enumerate refresh rate' must also be enabled).
Of course any resolution + refresh rate can be combined, so for example 'max, 60' is valid too.

The physical refresh rate will be 120Hz (this is a known issue) but the game should see the enumerated resolutions with 60Hz.

Reply 13 of 17, by ghost28

User metadata
Rank Newbie
Rank
Newbie

i'm using WIP64 and i don't see any unforced 60? Enumerate refresh rate is ticked, ,it only shows standard unforced,max etc.only specific resolutions shows 120hz at its end(1920x1080 120hz) nothing else. as i said before my laptop's quirk is it blocks any refresh rates other than 120hz so i'm forced to use it.(msi model) creating custom refresh rate through nvidia control panel also isn't working.(for this game don't remember much about others.)i remember using gedosato to fool resident evil 4.that one also has same problem.it didn't worked for this unfortunately.

Reply 14 of 17, by Dege

User metadata
Rank l33t
Rank
l33t

Resolution combo box is an editable one, so you can type custom values into it. The CPL parses its content when you 'Apply' the config.
The lists of editable combo boxes contain predefined values for convenient selection.

So, you can type the string "unforced, 60" into the combo box.

Reply 15 of 17, by ghost28

User metadata
Rank Newbie
Rank
Newbie
Dege wrote:

Resolution combo box is an editable one, so you can type custom values into it. The CPL parses its content when you 'Apply' the config.
The lists of editable combo boxes contain predefined values for convenient selection.

So, you can type the string "unforced, 60" into the combo box.

i'm sorry for the late reply time difference,tired... after reading that i hit my head 😀 yeah it worked! Thank you. fullscreen started no error, i selected correct resolution from option. to be sure closed it started again everything works. on dgvoodoo cp it turned into "0x0, 60Hz".(i wrote "unforced, 60") now only thing is why some thumbnail turns red t-posed models. ah also while it was windowed i had to use 4gb patch for the exe otherwise it was crashing after a while maybe because it didn't recognize my card and couldn't select correct memory cpu options? anyway i need to test it without it too now. Thanks again.

Reply 16 of 17, by V15UAL K3YS

User metadata
Rank Newbie
Rank
Newbie

If anyone is having any troubles, I made a video on this issue and what I did in order to fix the game and run it properly on Windows 10. Tested the latest stable release of dgVoodoo 2 (2.62) and it is what is used in this tutorial.

https://www.youtube.com/watch?v=2dCr_gCfN0U

Reply 17 of 17, by Dege

User metadata
Rank l33t
Rank
l33t

Great video, thanks! 😎
One minor thing: you don't have to edit the config file directly for deviceID and such because now all sections are editable through the CPL. Right click somewhere on the CPL dialog and you get a one-item context menu from where you can enable all sections to be shown not just the 3 basic ones.