Skip to content

MapConditionExtension

juanosarg edited this page May 30, 2026 · 2 revisions

<- Back

MapConditionExtension is a def extension that adds a few custom behaviours for map conditions. At the moment, it is mostly used by Vanilla Furniture Expanded - Power

    //This value only affects VE Furniture - Power
    public float tideStrengthMultiplier = 1;

    //This value affects VE Furniture - Power and base game watermill generators
    public float watermillStrengthMultiplier = 1;

How do I use this code?

This Def Extension is added to the GameConditionDef of the condition you want to add them to.

If you aren't sure if the GameConditionDef ALREADY has an extension (for example, if you think another mod will add their own), always use XPATH (xml patching) to add an extension, as there is already a PatchOperationAddModExtension to ensure they don't collide.

For example:

<modExtensions>
	<li Class="VEF.Maps.MapConditionExtension">
		<tideStrengthMultiplier>0.5</tideStrengthMultiplier>
		<watermillStrengthMultiplier>0.5</watermillStrengthMultiplier>
	</li>
</modExtensions>

Clone this wiki locally