mirror of
https://github.com/FalloutCollaborationProject/FCP-Tools.git
synced 2026-07-27 16:59:37 -07:00
Add hostile-animal behavior and AI: new MentalState_HostileAnimal, JobGiver_HostileAnimal and HediffComp_HostileAnimal (with properties) to force hostile mental states and target selection for animals. Introduce weighted hatcher support: add WeightedHatchEntry and CompProperties_HatcherCustom.weightedPawns, plus CompHatcherCustom.PickKind() and simplified Hatch() that picks a PawnKindDef by weight/secondary fallback. Adjust Enlist code: remove guest/world-pawn pass in ProvisionsInfo pawn generation and improve WorldObjectCompEnlist settlement selection with a non-hostile fallback if no same-faction destinations exist. Add a new soundCast entry to Abilities_Core.xml and update compiled assemblies accordingly.
24 lines
538 B
C#
24 lines
538 B
C#
using System.Collections.Generic;
|
|
|
|
namespace FCP.Core;
|
|
|
|
public class CompProperties_HatcherCustom : CompProperties
|
|
{
|
|
public float hatcherDaystoHatch = 1f;
|
|
|
|
public PawnKindDef hatcherPawn;
|
|
public float secondaryOverrideChance = 0f;
|
|
public PawnKindDef secondaryPawn;
|
|
public List<WeightedHatchEntry> weightedPawns;
|
|
|
|
public CompProperties_HatcherCustom()
|
|
{
|
|
compClass = typeof(CompHatcherCustom);
|
|
}
|
|
}
|
|
|
|
public class WeightedHatchEntry
|
|
{
|
|
public PawnKindDef pawnKind;
|
|
public float weight = 1f;
|
|
} |