Closed DeckerMMIV closed 10 years ago
I assume he's talking about fertilizer, liquidManure and manure, as those are the only three that are both in my mod and in SoilMod.
The problem will obviously lie in the load and execution order of the 2 mods. SoilMod updates the fillTypes in loadMapFinished()
, meaning at the end of loadMap01Finished()
. My mod updates the fillTypes in loadMap()
, which I assume happens before loadMapFinished()
. So that's probably the reason your mod overwrites my overlays.
The question for me is, do you actually need to overwrite existing overlays? If there are already overlays for specific fillTypes, the user apparently installed them through a different mod/method, meaning he wants them there. So in my opinion, you could change it so your overlays are only installed for non-existing ones:
if g_currentMission.fillTypeOverlays[fillTypeDesc.index] == nil and fillTypeDesc.hudOverlayFilename ~= nil and fillTypeDesc.hudOverlayFilename ~= "" then
g_currentMission:addFillTypeOverlay(fillTypeDesc.index, fillTypeDesc.hudOverlayFilename);
end;
Of course, I could say the same about my mod, where I delete existing ones as well. But that's because I overwrite the Giants default ones, while you overwrite ones that are never default but always custom ones.
I came to the same conclusion.
However, since I want the fertilizer
fill-type to use the fertiilzer1.dds
icon (i.e. the one with "A"), when running SoilMod in advanced mode, to be able to distinguish between the 3 types.
How I solved it, including not overwriting all the existing overlays, is in @eb22b24c673cdbf06b7c73cf8e3acb3c11e078c5
User 'mngrazy' send the following bug-report: