feat(factions): no raids made only of allies, and allies spare the whole base
A raid whose every spawn is at peace with the player's race is struck from the list the client sends as possibleEvents, and from the server's valid event points when raids are world-based. The structure veto covered only 20 m from the creature, but FindClosestStaticPriorityTarget searches the whole view range. It now holds while any allied player is within 100 m, and reads the per-race lists too.
This commit is contained in:
parent
5807e562ad
commit
df9c768f92
5 changed files with 291 additions and 107 deletions
|
|
@ -39,7 +39,8 @@ namespace RacesOfValheim
|
|||
// get the truce back.
|
||||
HostilityEnabled = config.Bind(factions, "Faction truce", true,
|
||||
new ConfigDescription("Mobs your race is at peace with leave you alone - they will not open a fight, " +
|
||||
"hunt you during events, or smash structures near you. Turn this off and every " +
|
||||
"hunt you during events, or smash structures while you are nearby, and raids made only " +
|
||||
"of them are not sent at you. Turn this off and every " +
|
||||
"creature treats you exactly as vanilla would. Covers BOTH halves, because both " +
|
||||
"answer the same BaseAI.IsEnemy and a switch over only one of them changes " +
|
||||
"nothing for most races: the faction rules in FactionHostilityPatch, and the " +
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue