Whoo Posted December 24, 2011 Mappers in TNT 2 noticed that chocorenderlimits wasn't counting the number of active platforms, but rather the total number activated. So I went into the source and fixed it. The problem was located in p_plats.c, in the P_RemoveActivePlat function. The P_AddActivePlat function was adding to the total number of platforms, but P_RemoveActivePlat wasn't removing the active ones. Here is the modified p_plats.c file. 0 Share this post Link to post
Enjay Posted December 30, 2011 Hmmm... when I try to run it I get: The Event log says: Activation context generation failed for "C:\Doom\Chocorenderlimits\chocorenderlimits_platfix.exe". Dependent Assembly Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8" could not be found. I'm not sure how to run sxstrace.exe to get meaningful output so that's everything that I have. 0 Share this post Link to post
Graf Zahl Posted December 30, 2011 People should stop assuming that the VC runtime DLLs are available on their target systems. Microsoft sure made it extremely inconvenient to use those at all... :( 0 Share this post Link to post
Quasar Posted December 30, 2011 God that's the worst error message since the THORAC-25 fried some people to death while printing out random numbers. Why the fuck can't they at least print the goddamn file name in there. Jesus Christ on a corndog stick. Anyway, as Graf says this is a runtime problem (msvcr90.dll probably). However, if you look closely, it is wanting the DebugCRT and that only comes with Visual Studio AFAIK. Only release builds should be distributed to non-programmer users. 0 Share this post Link to post
chungy Posted December 30, 2011 I've just rebuilt it with mingw32 instead, no MSVC runtime dependencies. http://dl.dropbox.com/u/13513277/chocorenderlimits_platfix.zip 0 Share this post Link to post
Enjay Posted December 31, 2011 Yup, that seems to work. Thank you kindly. :) 0 Share this post Link to post
The Green Herring Posted December 31, 2011 It might be just me, but it seems you can't use visplane bordering, sneak mode, or the color change function for the HOM detector anymore. All I get are the Save Game menu, the message toggle function, and the "Quit Game?" prompt, respectively. This was using chungy's build. That one wasn't based on an older version, was it? 0 Share this post Link to post
Whoo Posted December 31, 2011 Graf Zahl said:People should stop assuming that the VC runtime DLLs are available on their target systems. Microsoft sure made it extremely inconvenient to use those at all... :( Yeah I forgot about the incompatibility problems and I never got around to rebuilding it with Qt or another multi-platform compiler. chungy said:I've just rebuilt it with mingw32 instead, no MSVC runtime dependencies. http://dl.dropbox.com/u/13513277/chocorenderlimits_platfix.zip Thanks for building it with a more friendly compiler! The Green Herring said:It might be just me, but it seems you can't use visplane bordering, sneak mode, or the color change function for the HOM detector anymore. All I get are the Save Game menu, the message toggle function, and the "Quit Game?" prompt, respectively. This was using chungy's build. That one wasn't based on an older version, was it? It looks like chungy and I both used source code from the SVN then, and according to the ChangeLog the SVN hasn't been updated since January. I (or chungy) will have to rebuild it with the patch file from ReMood's site. 0 Share this post Link to post
chungy Posted December 31, 2011 Indeed; I made the build rather quickly without noticing that Ghostly had a patch of further changes than what is in Subversion. I've just updated the same Zip file with the later changes and Whoo's combined. 0 Share this post Link to post
RestlessRodent Posted December 31, 2011 The SVN has not been updated because I switch to mercurial! Also Fraggle has stopped bothering patching his copy. So if fraggle is reading this, you could potentially delete that branch and just tell everyone to go to this URL instead, perhaps with a single file in it. https://bitbucket.org/GhostlyDeath/chocorenderlimits/overview The actual repo is: https://bitbucket.org/GhostlyDeath/chocorenderlimits EDIT: If you give me an ACTUAL patch and not an individual file, I will gladly apply it so it would work in a future version of Chocorenderlimits. 0 Share this post Link to post
chungy Posted December 31, 2011 It's a one-line change, really, nothing complicated. (Though you've apparently re-indented the source on bitbucket to your own preferences (I must say, tabs, yuck), so simply diffing his big file would have been difficult) diff -r 45dcb675005c src/p_plats.c --- a/src/p_plats.c Wed Oct 05 13:17:02 2011 -0400 +++ b/src/p_plats.c Fri Dec 30 21:13:38 2011 -0800 @@ -297,6 +297,7 @@ P_RemoveThinker(&(activeplats[i])->thinker); activeplats[i] = NULL; + numplats--; return; } I_Error("P_RemoveActivePlat: can't find plat!"); 0 Share this post Link to post
Graf Zahl Posted December 31, 2011 Whoo said:Yeah I forgot about the incompatibility problems and I never got around to rebuilding it with Qt or another multi-platform compiler. The compiler isn't the problem. Just the settings for the runtime library. For simple applications setting it to 'static' is absolutely recommended. 0 Share this post Link to post
RestlessRodent Posted December 31, 2011 The latest code now contains the fix. 0 Share this post Link to post