AI analyzing your entity.lua file suggests this is a code defect as well:
The issue where uranium and enriched uranium walls damage you upon being hit with a nuke explosion wave could be related to the attack_reaction behavior defined for the Tier 4 walls (walls with mk_level == 4). Here's a breakdown of potential issues in the provided code:
Key Observations:
Attack Reaction Behavior:
The attack_reaction includes a nested series of target_effects that deal damage of various types (poison, electric, fire, laser, acid, explosion, physical, and impact).
The reaction_modifier is 0.25, which means the reaction is triggered with a 25% probability when the wall is attacked.
Damage Types and Ranges:
The damage range is quite extensive (range = 1000), meaning the reaction can affect entities over a large area.
While the damage values are modified by reflect_modif, they could potentially still apply to the player or other friendly entities if not properly filtered.
Lack of Filtering for Targets:
The attack_reaction does not include any filtering for the target of the reaction. If the player or friendly entities are within the range of the reaction, they might inadvertently take damage.
Explosion Damage:
type = "explosion" might interact unexpectedly with the nuke explosion, causing unintended effects.