Skip to content

Conversation

@Fly-Star-him
Copy link
Contributor

@Fly-Star-him Fly-Star-him commented Oct 11, 2025

Players/AI can customize whether to attack non-threatening structures.
玩家/AI可以自定义能否攻击无威胁建筑。

Attack non-threatening structures

  • You can now freely configure whether units can automatically target non-threatening structures.
    • AutoTarget.NoThreatBuildings affects player-controlled units, AutoTargetAI.NoThreatBuildings affects other units.

In rulesmd.ini:

[General]
AutoTarget.NoThreatBuildings=false      ; boolean
AutoTargetAI.NoThreatBuildings=true     ; boolean

Attack non-threatening structures

  • AttackNoThreatBuildings permits shooters to attack non-threatening structures. This setting overrides other configurations.

In rulesmd.ini:

[SOMEWEAPON]                ; WeaponType
AttackNoThreatBuildings=    ; boolean

@github-actions
Copy link

github-actions bot commented Oct 11, 2025

Nightly build for this pull request:

This comment is automatic and is meant to allow guests to get latest nightly builds for this pull request without registering. It is updated on every successful build.

Copy link
Contributor

@CrimRecya CrimRecya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The hooks are duplicated, they can be merged together

@Coronia Coronia requested a review from CrimRecya October 13, 2025 12:26
Copy link
Contributor

@CrimRecya CrimRecya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incorrect logical processing

@Coronia
Copy link
Contributor

Coronia commented Nov 14, 2025

could this be defined on buildings as well? In current game buildings will be auto targeted no matter if Insignificant set to true or false, so it would be better to have a separated tag for this purpose

@Fly-Star-him
Copy link
Contributor Author

could this be defined on buildings as well? In current game buildings will be auto targeted no matter if Insignificant set to true or false, so it would be better to have a separated tag for this purpose

If you need it, i can give it a try.

@TaranDahl
Copy link
Contributor

Remember to write the instructions on the front page of the PR. Some testers are not good at looking through the code.

@KuroNoSeiHai
Copy link

I have tested this PR. Work as expected. But he only affects the enemy, not the neutral.But I think it's right.

@TaranDahl TaranDahl added Tested ⚙️T1 T1 maintainer review is sufficient and removed Needs testing labels Jan 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

⚙️T1 T1 maintainer review is sufficient Tested

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants