Added support for mod configurations

This commit is contained in:
Pijus Kamandulis
2022-01-28 19:07:49 +02:00
parent ea46b13a17
commit 8db034560c
17 changed files with 17381 additions and 6 deletions

View File

@@ -0,0 +1,183 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Conditionals example - NOTE: Still WIP and all features may not work properly.
{} - To evaluate and return result within.
&lt; - Less than
&gt; - Greater than
&amp; - AND
e.g. {week=1?{weekDay<3?1:{weekDay}}:{week}}
becomes
If Week = 1:
SubValue = 0
If WeekDay < 3:
SubValue = 1
Else:
SubValue = WeekDay
Return SubValue
Else:
Return Week
Conditional variables
week - Current in-game week.
weekDay - Current day in the week (1-7).
totalDay - Current day in the game (1-1000+). -->
<!-- Define horde enemies for Improved Hordes. -->
<hordes>
<horde type="wandering">
<hordegroup name="ZombieDogs" prefWeekDay="3,6,7" maxWeeklyOccurrences="2">
<gs min="5" countIncPerGS="0.1">
<entity name="animalZombieDog" minCount="1" maxCount="20"/>
</gs>
</hordegroup>
<hordegroup name="Wolfs" weight="0.5" prefWeekDay="1,2,3,6" maxWeeklyOccurrences="1">
<gs min="10" countIncPerGS="0.033">
<entity biomes="desert,snow" name="animalCoyote" minCount="1" maxCount="6"/>
<entity biomes="pine_forest,burnt_forest" name="animalWolf" minCount="2" maxCount="6"/>
</gs>
<gs min="50" countIncPerGS="0.025">
<entity biomes="pine_forest,desert,wasteland,burnt_forest" name="animalDireWolf" minCount="1" maxCount="3"/>
<entity biomes="snow" name="animalMountainLion" minCount="1" maxCount="3"/>
</gs>
</hordegroup>
<hordegroup name="Bears" weight="0.5" prefWeekDay="1,2,3" maxWeeklyOccurrences="1">
<gs min="50" countIncPerGS="0.02">
<entity biomes="pine_forest,snow" name="animalBear" minCount="1" maxCount="6"/>
</gs>
<gs min="100" countIncPerGS="0.02">
<entity biomes="wasteland,burnt_forest" name="animalZombieBear" minCount="1" maxCount="7"/>
</gs>
</hordegroup>
<hordegroup name="Deserted" weight="0.1" prefWeekDay="4,5" maxWeeklyOccurrences="1">
<gs min="20" countIncPerGS="0.03">
<entity biomes="desert,burnt_forest,wasteland" name="animalZombieVulture" minCount="1" maxCount="4"/>
<entity biomes="desert,pine_forest" name="animalSnake" minCount="1" maxCount="3"/>
</gs>
<gs min="100" countIncPerGS="0.025">
<entity biomes="wasteland" name="animalZombieVultureRadiated" minCount="1" maxCount="4"/>
</gs>
</hordegroup>
<hordegroup name="Zombies">
<!-- Standard Zombies -->
<gs max="100" countIncPerGS="0.417" countDecGS="48" countDecPerPostGS="0.417">
<gs min="15" max="75">
<entity name="zombieScreamer" chance="0.1" minCount="1" maxCount="1"/>
</gs>
<entity group="ZombiesAll" minCount="3" maxCount="20"/>
</gs>
<!-- Example of GS
Start spawning at GS100 and increase count by 0.02 per GS from there,
at GS400 start decreasing spawn count by 0.1 per GS after 400,
then cease any remaining spawns at GS700.-->
<!-- Feral Zombies -->
<gs min="50" max="375" countIncPerGS="0.18" countDecGS="160" countDecPerPostGS="0.18">
<gs min="75" max="250">
<entity name="zombieScreamerFeral" chance="0.2" minCount="1" maxCount="1"/>
</gs>
<entity group="IHZombiesAllFeral" minCount="1" maxCount="20"/>
</gs>
<!-- Radiated Zombies -->
<gs min="166" countIncPerGS="0.18">
<gs min="250">
<entity name="zombieScreamerRadiated" chance="0.25" minCount="1" maxCount="1"/>
</gs>
<entity group="IHZombiesAllRadiated" minCount="1" maxCount="40"/>
</gs>
</hordegroup>
<hordegroup name="Stags" weight="0.75" parent="Farm" maxWeeklyOccurrences="1">
<entity biomes="pine_forest,snow" name="animalStag" minCount="1" maxCount="2"/>
<entity biomes="pine_forest,snow" name="animalDoe" minCount="1" maxCount="1"/>
</hordegroup>
<hordegroup name="Boars" weight="0.75" parent="Farm" maxWeeklyOccurrences="1">
<entity biomes="pine_forest" name="animalBoar" minCount="1" maxCount="2"/>
</hordegroup>
<hordegroup name="Farm" weight="0.5" maxWeeklyOccurrences="1">
<entity horde="wandering" group="Stags" maxCount="2"/>
<entity horde="wandering" group="Boars" maxCount="2"/>
<entity name="animalChicken" minCount="2" maxCount="3"/>
<entity name="animalRabbit" minCount="1" maxCount="2"/>
</hordegroup>
</horde>
<!-- Scouts -->
<horde type="scouts">
<hordegroup name="ScreamerScout" weight="0.75">
<!-- Standard Screamer -->
<gs min="25" max="75">
<entity name="zombieScreamer" minCount="1" maxCount="1"/>
</gs>
<!-- Feral Screamer Scout -->
<gs min="76" max="250">
<entity name="zombieScreamerFeral" minCount="1" maxCount="1"/>
</gs>
<!-- Radiated Screamer Scout -->
<gs min="251">
<entity name="zombieScreamerRadiated" minCount="1" maxCount="1"/>
</gs>
</hordegroup>
<!-- Classic spider zombie trio -->
<hordegroup name="SpiderScouts" weight="0.25">
<gs min="25" max="100" countIncPerGS="0.042">
<entity name="zombieSpider" minCount="1" maxCount="3"/>
</gs>
<gs min="101" max="250" countIncPerGS="0.035">
<entity name="zombieSpiderFeral" minCount="1" maxCount="3"/>
</gs>
<gs min="251" countIncPerGS="0.03">
<entity name="zombieSpiderRadiated" minCount="1" maxCount="3"/>
</gs>
</hordegroup>
</horde>
<!-- Scout horde spawned by scouts -->
<horde type="scout">
<hordegroup name="Zombies">
<gs min="25" max="200" countIncPerGS="0.075" countDecGS="151" countDecPerPostGS="0.075">
<gs min="50">
<entity horde="scouts" chance="0.1"/> <!-- Entity types allow you to integrate other hordes into different hordes -->
</gs>
<entity group="ZombiesAll" minCount="2" maxCount="8"/>
</gs>
<gs min="151" max="400" countIncPerGS="0.075" countDecGS="301" countDecPerPostGS="0.075">
<gs min="175">
<entity horde="scouts" chance="0.25"/>
</gs>
<entity group="IHZombiesAllFeral" minCount="2" maxCount="8"/>
</gs>
<gs min="301" countIncPerGS="0.075">
<gs min="301">
<entity horde="scouts" chance="0.5"/>
</gs>
<entity group="IHZombiesAllRadiated" minCount="1" maxCount="10"/>
</gs>
</hordegroup>
</horde>
</hordes>

View File

@@ -0,0 +1,24 @@
<improved_hordes>
<max_alive_per_horde_player>8</max_alive_per_horde_player> <!-- -1 to disable. -->
<wandering_horde>
<horde_player_group_dist>400</horde_player_group_dist> <!-- All players within 400m will be grouped together to calculate spawned horde gamestages. -->
<schedule>
<days_per_wandering_week>7</days_per_wandering_week>
<hrs_in_week_to_first_occurrence>0</hrs_in_week_to_first_occurrence>
<hrs_in_week_for_last_occurrence_max>156</hrs_in_week_for_last_occurrence_max> <!-- 6 * 24 + 12 or Day 7 12:00 pm -->
<min_hrs_between_occurrences>6</min_hrs_between_occurrences>
<min_occurrences>6</min_occurrences>
<max_occurrences>8</max_occurrences>
<feral_horde_chance>0.5</feral_horde_chance> <!-- 0.5 means 50% chance, range from 0.0 to 1.0 -->
</schedule>
</wandering_horde>
<scout_horde>
<chunk_radius>4</chunk_radius> <!-- Notify scouts near these certain chunks, and group players for difficulty by distance using chunk_radius * 16 (chunk size) -->
<feral_horde_chance_multiplier>1.0</feral_horde_chance_multiplier> <!-- 1.0 for default difficulty scaling from 0 to 75% chance at gamestage 540 -->
</scout_horde>
</improved_hordes>

View File

@@ -0,0 +1,29 @@
<ihentities>
<!-- Allows the animal hordes to work properly -->
<remove xpath="/entity_classes/entity_class[@name='animalTemplateTimid']/property[@name='AITask-1']"/>
<remove xpath="/entity_classes/entity_class[@name='animalTemplateTimid']/property[@name='AITask-2']"/>
<remove xpath="/entity_classes/entity_class[@name='animalTemplateTimid']/property[@name='AITask-3']"/>
<remove xpath="/entity_classes/entity_class[@name='animalTemplateTimid']/property[@name='AITask-4']"/>
<append xpath="/entity_classes/entity_class[@name='animalTemplateTimid']">
<property name="AITask-1" value="ApproachSpot"/>
<property name="AITask-2" value="RunawayWhenHurt"/>
<property name="AITask-3" value="RunawayFromEntity" data="class=EntityPlayer,EntityZombie,EntityEnemyAnimal"/>
<property name="AITask-4" value="Look"/>
<property name="AITask-5" value="Wander"/>
</append>
<!-- Same for rabbits -->
<remove xpath="/entity_classes/entity_class[@name='animalRabbit']/property[@name='AITask-1']"/>
<remove xpath="/entity_classes/entity_class[@name='animalRabbit']/property[@name='AITask-2']"/>
<remove xpath="/entity_classes/entity_class[@name='animalRabbit']/property[@name='AITask-3']"/>
<remove xpath="/entity_classes/entity_class[@name='animalRabbit']/property[@name='AITask-4']"/>
<append xpath="/entity_classes/entity_class[@name='animalRabbit']">
<property name="AITask-1" value="ApproachSpot"/>
<property name="AITask-2" value="RunawayWhenHurt"/>
<property name="AITask-3" value="RunawayFromEntity" data="class=EntityPlayer,EntityZombie,EntityEnemyAnimal;safeDistance=20"/>
<property name="AITask-4" value="Look"/>
<property name="AITask-5" value="Wander"/>
</append>
</ihentities>

View File

@@ -0,0 +1,38 @@
<ihhordes>
<append xpath="/entitygroups">
<entitygroup name="IHZombiesAllFeral">
<entity name="zombieSpiderFeral"/>
<entity name="zombieBoeFeral"/>
<entity name="zombieJoeFeral"/>
<entity name="zombieSteveFeral"/>
<entity name="zombieMoeFeral"/>
<entity name="zombieYoFeral"/>
<entity name="zombieBusinessManFeral"/>
<entity name="zombieArleneFeral"/>
<entity name="zombieDarleneFeral"/>
<entity name="zombieMarleneFeral"/>
<entity name="zombieNurseFeral"/>
<entity name="zombieFatHawaiianFeral"/>
<entity name="zombieSteveCrawlerFeral"/>
<entity name="zombieFemaleFatFeral"/>
<entity name="zombieJanitorFeral"/>
<entity name="zombieLabFeral"/>
</entitygroup>
<entitygroup name="IHZombiesAllRadiated">
<entity name="zombieSpiderRadiated"/>
<entity name="zombieBoeRadiated"/>
<entity name="zombieJoeRadiated"/>
<entity name="zombieSteveRadiated"/>
<entity name="zombieMoeRadiated"/>
<entity name="zombieYoRadiated"/>
<entity name="zombieArleneRadiated"/>
<entity name="zombieDarleneRadiated"/>
<entity name="zombieMarleneRadiated"/>
<entity name="zombieSkateboarderRadiated"/>
<entity name="zombieFemaleFatRadiated"/>
<entity name="zombieJanitorRadiated"/>
<entity name="zombieLabRadiated"/>
</entitygroup>
</append>
</ihhordes>