The farm crash bug

I'm not sure if this helps with the fix that whoward69 and PawelS have been experimenting with, but I just realized that we have a lot more control over graphic objects than I previously thought. See my reference: Events are a Two-Way Street. (Perhaps this is old news to some. It was a discovery for me.)

The gist if it is that we should be able to control an improvement's art asset, art style, era or state via Events.SerialEventImprovementCreated (invoking it, not subscribing to it). I haven't tried it specifically for that event, but the approach worked fine for SerialEventCityCreated. It allows you to alter a graphic object on the map "after the fact". I.e., the engine adds a graphic object, your listener code caches that info, then another function comes back and changes it.
 
Just a quick update, I've not given up with this (at least not yet!)

Been testing a few things (a SNAPSHOT handler with Ancient/Industrial buildings only) and a combination SNAPSHOT (for Wheat) and RANDOM handler (using the CCTP resources)

The former lacks a certain degree of "eye candy", while the latter (see thumbnail) I'm still undecided about (and still playing a game to see if it grows on me!)

Unless Firaxis fix this, someone will have to create 8 or 9 new graphics
  • Wheat - under construction
  • Wheat - constructed
  • Wheat - pillaged
  • Generic - under construction
  • Generic - constructed (3 or 4 crop/field/buildings variants)
  • Generic - pillaged

EDIT: Actually it only really needs one re-skinned medieval plantation building - see http://forums.civfanatics.com/showthread.php?t=487406
 

Attachments

  • Arable.jpg
    Arable.jpg
    178.6 KB · Views: 542
It's growing on me (bad pun intended)

Mod attached in case anyone else want's to use/modify it

Edit: "Improvement - Farm replacement" can now be downloaded from my mod web site
 
Hi, wHoward, this sounds like a lovely "fix". Will it play with barebones Civ5 or requires G&K?
 
There's nothing G&K specific (all it's doing is changing the artwork and layout handlers for the Farm improvement) so it should work unmodified for vanilla as well as G&K
 
Thank you very much. It's actually more elegant than I thought now that I peeked at the code. :goodjob:
 
Another win from whohoward! Don't think i've ever had this bug but more variety is always good.
 
Would you predict any trouble if this mod is applied several times in a row? Because I expect it could become standard to include it in any mod that needs to set Reload Landmark System.
 
Im getting regular crashes around 370+ turns in a singleplayer game with G&K unofficial p + GEM. If I enable this farm-fix mod I cant even start the game, getting a DX11 error right after I load a game.
 
As the mod makes some fundamental changes to the ArtDefines table I very much doubt you can enable the mod and then load an in-progress game where the mod was not enabled when the game was started.
 
Guys,

I made a new farm graphic. Its just the built building now (i'll make half-built and pillaged if this works).

Please test it and let me know if it helps resolve the farm bug. It doesn't use the "blanket" like effect of farms its more static but I added a few layers to compensate. Let me know if it helps and if any graphics need to change.

link:
http://forums.civfanatics.com/showpost.php?p=12339146&postcount=197


:
 
It only occurs with a mod (any mod, even a completely empty one) with "Update Landmark System" checked in the mod properties. There weren't that many mods that were updating landmark graphics (i.e. resources, features, and improvements), though I suppose it may have kept more from being made.
 
Sorry, I should of mentioned that was in connection to a mod (Improvement Upgrades). That uses graphics already in the game, but would fall foul of the replacing-a-Farm-with-anything issue. It hasn't cropped up yet, for me, since the last fix, so had just wondered if the issue was still there :)
 
It has been reported as happening "whenever a farm is replaced period" or "when a farm is replaced when using a mod that has Reload Landmark System flag set".

Personally I never experienced the former over more than 2000 hours of playing the game, it wasn't until I added my Airfield mod that I started experiencing it. I put the former down to the fact that the first version of ModBuddy defaulted that flag to true and/or modders not knowing what to choose and just checking everything (usually out of frustration) - it only takes one mod with it set to cause it!

I've not checked if patch 2.44 fixed it, but there is nothing in the release notes to suggest they did
 
I noticed no mention of it with the notes too, but then wondered if they considered it worth mentioning, fixing etc
 
Cancel that idea... Just crashed :-P

Given how much Thal has been jumping up and down to get this fixed I'd have been very, very surprised if it had been fixed and then not mentioned ;)
 
Back
Top Bottom