Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Armament not working properly with value 0 in BurstDelays #20675

Merged
merged 2 commits into from Sep 23, 2023

Conversation

PunkPun
Copy link
Member

@PunkPun PunkPun commented Feb 18, 2023

Supersedes: #20601

This allows us to simplify yaml definitions, as I've done in all non-d2k mods.
It will also make it easier for the encyclopedia to read armament definitions when we get to it.

@dnqbob
Copy link
Contributor

dnqbob commented Feb 18, 2023

This allows us to simplify yaml definitions, as I've done in all non-d2k mods.
It will also make it easier for the encyclopedia to read armament definitions when we get to it.

Add: by using this properly instead of massing armaments we can also get performance improve, since the armaments are traversed every time when AutoTarget check target and Attackbase fire at target.

@michaeldgg2
Copy link
Contributor

michaeldgg2 commented Feb 24, 2023

I tested this change on OpenE2140 and it works fine. Here are the weapon and armament definition:

ucs_vehicles_tiger_assault:
	ReloadDelay: 40
	Report: 5.smp
	ValidTargets: Ground
	Burst: 8
	BurstDelays: 0, 10, 0, 10, 0, 10, 0
Armament@PRIMARY:
	Weapon: ucs_vehicles_tiger_assault
	Recoil: 64
	RecoilRecovery: 38
	LocalOffset: 100,-410,0, 100,410,0
	LocalYaw: 0, 0

It does not look as concise as the BurstPerFire (from superseded PR), but it does the job.

@Mailaender Mailaender merged commit d77fd5c into OpenRA:bleed Sep 23, 2023
3 checks passed
@Mailaender
Copy link
Member

Changelog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants