Jump to content
simmaster07

SC4Fix: third-party patches for SC4

82 posts in this topic Last Reply

Highlighted Posts

Posted:
Last Online:  
 

I'll certainly be testing this out in the coming days. I know other CTDs exist, but this is the only problem I still experience. Every now and again I'm forgetful with the save function and miss a TE lot and it crashes, so it would be great to know that may be solved.

Better still is the prospect of somehow injecting code into the game, the possibilities that brings would be immense. Great work here.

  • Like 1

Head over to my Lot and Mod Shack to keep abreast of my latest developments.

Do you like custom textures, but don't like all the work involved creating them?, take a look at the Texture Automation options here. Change the look and feel of your transit networks, with the minimum of effort, for example customised versions of my Sidewalk NAM (SWN) and Terrain Grass NAM (TGN) mods, and much more besides.

New to the NAM? Check out my tutorials on YouTube. Latest upload: How to: RHW - MHO Roundabout Interchanges. (Nov 25).

p.s. - I'm MGB over on SC4D and a member of the NAM team.

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

I think there are things that modders have dreamed of doing with DLLs that are impossible beyond mere bugfixes (not to say that the TE-lot/Puzzle-Piece CTD is in any way an insignificant bug to fix).

This seems like it opens up whole new possibilities to modders, if the code can be properly written. Very incredible find! Thanks for the hard work.


My MD on SC4Devotion (updated first)
And Here on Simtropolis
NAM Associate

"My mother always told me, 'Elwood, you can be two things in this world...you can either be Oh So Smart, or Oh So Pleasant.'

Well, for years I was smart. I recommend pleasant."
-Elwood P. Dowd, Harvey

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Good news. This magical mod should probably be bundled with future NAM releases.

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Wow, this is a revolutionary achievement for SimCity 4, and it doesn't even modify the game's internal files. After all these years of modding, to achieve what you've done is a remarkable breakthrough. Genius! :thumb:

Can't wait to see what further possibilities this may open.

I smell a Trixie already...

  • Like 9

Quick Links

“SimCity 4 is not just a game, but a tool driven by our own imagination and creativity.”

Buy me a coffee

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

There is something more amazing- placing transit enabled lots right together facing the same direction. This means incredible new possibilities for TE lots. A limitation has always been that one tile gap.

  • Like 5

Dear sir/madam/whoever will read this!

This profile is now defunct.

Computer problems and issues with accessing my Imageshack account meant My SC4 CJ Scrapbook was lost and utterly irretrievable. This setback put me off SC4 for many months.

Apologies for the inconvenience and for the lost pictures.

But that SC4 itch did not go away and it had to be scratched! I have started afresh with a new account here- The British Sausage

The URS is a spiritual successor to the SC4 CJ Scrapbook.

With this update this will be the last time I visit my original Simtropolis account- admin/mods feel free to remove it or do whatever you need to do. I have no further use for the Ln X (BLANKBLANK) account.

 

With regards, Miles Saunders-Priem aka. Ln X aka. The British Sausage

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

You are truly remarkable, Simmaster!  :thumb:  CTDs have always been my top problem with SC4 as far as gameplay goes,  and although I can't speak for everyone, I would hazard a guess that this particular issue contributes to a big part of CTDs across the SC4 community.  Seeing the puzzle piece/TE lot CTD put to bed would be sweet!

  • Like 1

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Congratulations, you've buried the last great barrier to modding SC4. Enjoy being a legend.

This fix works for the GOG version, as expected.

  • Like 1

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

This is amazing! I ought to try this out!! I didn't think it would be possible to fix the "puzzle piece over transit-enabled lot" bug.

 

EDIT: Just tried it out, and it is awesome!!!!! Yaaaay, no more crashes when I hover a puzzle piece over a transit-enabled lot. I have had this happen with hovering a puzzle piece over a railyard located right next to an RHW and it sucked.

  • Like 1

Check out my roadgeek CJ, United States of Simerica! Last updated: March 5th, 2017

NAM Associate

Cofounder of the United SimNations

Share this post


Link to post
Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    Thanks for the support, everyone! I've uploaded prerelease 3 to the STEX since I think this is ready for a wider release in its current state judging from my own testing and the positive feedback so far. Until I get the chance to analyze some more CTDs or find any lingering issues with this DLL, I'm mostly going to be using this project to do some experimenting with SC4's internals and trying to identify useful functions in the game.

    If you have any suggestions for bugs to fix and know how to replicate them somewhat consistently, do let me know so I can investigate.

    • Like 6

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    I did some brief testing on the GoG digital version.

    A number of situations where CTDs would previously be caused are no longer happening, so I'm pretty sure it's working.

    I did find a replicatable CTD when hovering the Rail Viaduct tool over the HSRP Transit Hub included in the NAM.

    As for other CTDs, most of these are solvable by setting SC4 up correctly and installing all the patches. Thought the obvious one for me would be the CTD when multiple cores are active. I had a brief but noticeable improvement with multi-core active, but it's not worth it whilst the regular as clockwork CTDs occur.

    • Like 2

    Head over to my Lot and Mod Shack to keep abreast of my latest developments.

    Do you like custom textures, but don't like all the work involved creating them?, take a look at the Texture Automation options here. Change the look and feel of your transit networks, with the minimum of effort, for example customised versions of my Sidewalk NAM (SWN) and Terrain Grass NAM (TGN) mods, and much more besides.

    New to the NAM? Check out my tutorials on YouTube. Latest upload: How to: RHW - MHO Roundabout Interchanges. (Nov 25).

    p.s. - I'm MGB over on SC4D and a member of the NAM team.

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    Hey @rsc204, I tried to replicate the rail viaduct crash but didn't have any luck. This is what I tried doing, maybe you're doing something differently?

    Pardon the random voice in the audio, I was streaming the Chaos Communication Conference.

    • Like 6

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    Sorry, I tested the first release and somehow I didn't pick up on the instructions to move the DLLs location from Apps to the Plugins folder for the newer releases.

    I had thought it was working, since I tested a spot where I had previously had a CTD a few weeks back. In the end it turns out I was using the wrong piece. Having now got it in the right place I'm no longer having any troubles.

    I've been trying out every TE lot I have with an array of Puzzle Pieces since I got it setup correctly and so far no issues whatsoever.

    • Like 2

    Head over to my Lot and Mod Shack to keep abreast of my latest developments.

    Do you like custom textures, but don't like all the work involved creating them?, take a look at the Texture Automation options here. Change the look and feel of your transit networks, with the minimum of effort, for example customised versions of my Sidewalk NAM (SWN) and Terrain Grass NAM (TGN) mods, and much more besides.

    New to the NAM? Check out my tutorials on YouTube. Latest upload: How to: RHW - MHO Roundabout Interchanges. (Nov 25).

    p.s. - I'm MGB over on SC4D and a member of the NAM team.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    I came to check the forums, and stumble on this...

     

    WHOA!!!

     

    Maybe I will even get back making my mod (I had sort of given up because I had some issues with it that were unsolvable without this kind of modding)

    • Like 3

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    Since at least a couple of people brought up the idea of packaging this with the NAM, I'd say it's worth noting that this mod is MIT licensed, so anyone is free to redistribute it anywhere and do as they please with the code.

    I'd wager that the only real issue is what happens when multiple copies of this DLL are installed since that could cause conflicts. That's also something I'm working toward fixing, though. New versions going forward can report conflicts to players. The one thing that needs to be added is detecting versions without this feature, which shouldn't be difficult.

    • Like 5

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    This is awesome news!

    I would personally be most appreciative of something that could fix the multi-core issues - as a Mac user running the Amazon/GOG version under WINE (i.e. I can load DLLs), the CPUCount tag doesn't work and I have to manually throttle the whole PC down to 1 CPU which is something of a PITA requiring reboots before and after playing.  (I can run under a virtual machine as well but it doesn't run as well and in fact crashes with my very large region.)  Not sure if that's in the cards though and I'm certainly not going to expect it.

    Do you suppose there could ever be modding potential with this; say for instance the hard-coded nuisances with tunnels or even additional networks?  Obviously speculative at this point, but maybe something worth shooting for?

    • Like 1

    Correlation doesn't imply causation, but it does waggle its eyebrows suggestively and gesture furtively while mouthing 'look over there'. - xkcd.com

    Visit my SC4 City Journal, Leicester County | Index | Street Map
    Buffalo and Upstate New York BATs

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    It'd likely take exponentially more effort to deal with hardcoded game issues since it'd require reverse engineering large blocks of game code. That's not to say it's impossible, it's just that it'd probably be another few years at the least before we could reach a point where we could perform that kind of modding. Then again, I've yet to look too far into it anyway.

    As far as the multi-CPU issue goes, that might be an issue with Wine. What SC4 does internally with the CPUCount flag is literally the same as if you'd set the processor affinity in the task manager, which is probably unimplemented in Wine. I'm curious as to what exactly is going on with the multi-CPU crash, though. It could be a race condition but I don't know why or for what purpose SC4 would spawn threads dealing with the same bits of memory.

    • Like 5

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     
    On 26/12/2015 at 9:24 PM, Tarkus said:

    I've just had a chance to test this briefly on my 1.1.640 disc copy, and my mind is completely blown.  Getting the DLLs to stay in memory has been the holy grail--to finally see it happen and for it to fix one of the most notorious bugs is one of the most amazing things I've been able to witness in my 10 years in this community.

    simmaster07, you are officially awesome.

    -Tarkus

    ditto.

    I've had a very quick/brief look at the source code & yeah, I'm gobsmacked. Very impressed.  :ducky:x:ducky:^:ducky: for your efforts.

    • Like 4

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    Which portion? The inability to launch in 32-bit color depth in exclusive mode, or the color banding? The latter can be explained by the Intel chipset doing dithering...

    • Like 1

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    58 minutes ago, Mister Giggles said:

    Which portion? The inability to launch in 32-bit color depth in exclusive mode, or the color banding? The latter can be explained by the Intel chipset doing dithering...

    Neither; the game launches in 32-bit color depth in exclusive mode, and if I force 16-bit it seems like my integrated graphics are doing dithering.

    • Like 2

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    I bet that's only on Windows 10.

    It's quite clear that something about Windows 10 improves compatibility of Intel's integrated graphics with SC4. On Windows 7/8 you'll be lucky if you can even use DirectX or OpenGL rendering.

    @simmaster07 If you are really itching for something else to fix, I'm not sure if CTD's are really worthwhile.

    There are many reports from those with problems running SC4, but honestly every one can be solved with a little effort. The problem is many users lack the technical ability or will to do anything about it and just complain SC4 is a buggy mess (it's not). The PP over TE lot was the only one that couldn't be fixed, until you came along ;).

    Two situations where consistent CTDs will always occur:

    • Switching tree controllers when flora from the old one remains in a city. (Widely known, every one I've seen has a warning, people fail to read it).
    • Loading the game with textures larger than 256x256 installed using OpenGL or Software rendering.

    If you fixed those CTDs, it wouldn't change the fact you couldn't do those things. The CTD itself is harmless enough.

    Multiple cores being used will consistently cause CTDs (some report otherwise, but honestly I'm not sure). If fixed from what I've seen and heard, maybe we'd get 10% improvement in CPU performance. Sure I'd take that 10% and I'm sure others would too, provided it was proven to be stable. The code still isn't multi-core optimised though, so perhaps it's a moot point?

    All other CTDs I can think of right now are going to be much harder to track because they can't easily be triggered.

    • Like 2

    Head over to my Lot and Mod Shack to keep abreast of my latest developments.

    Do you like custom textures, but don't like all the work involved creating them?, take a look at the Texture Automation options here. Change the look and feel of your transit networks, with the minimum of effort, for example customised versions of my Sidewalk NAM (SWN) and Terrain Grass NAM (TGN) mods, and much more besides.

    New to the NAM? Check out my tutorials on YouTube. Latest upload: How to: RHW - MHO Roundabout Interchanges. (Nov 25).

    p.s. - I'm MGB over on SC4D and a member of the NAM team.

    Share this post


    Link to post
    Share on other sites

    Sign In or register to comment...

    To comment in reply, you must be a community member

    Sign In  

    Already have an account? Sign in here.

    Sign In Now

    Create an Account  

    Sign up to join our friendly community. It's easy!  

    Register a New Account


    ×

    Thank You for the Continued Support!

    Simtropolis depends on donations to fund site maintenance costs.
    Without your support, we just would not be in our 24th year online!  You really help make this a great community. *:thumb:

    But we still need your support to stay online. If you're able to, please consider a donation to help us stay up and running. This helps sustain a platform where we can share our community creations for years to come.

    Make a Donation, Get a Gift!

    Expand your city with the best from the Simtropolis Exchange.
    Make a Donation and get one or all three discs today!

    STEX Collections

    By way of a "Thank You" gift, we'd like to send you our STEX Collector's DVD. It's some of the best buildings, lots, maps and mods collected for you over the years. Check out the STEX Collections for more info.

    Each donation helps keep Simtropolis online, open and free!

    Thank you for reading and enjoy the site!

    More About STEX Collections