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

Add cloning AI Triggers for Easier Difficulties #195

Conversation

Shushishtok
Copy link
Contributor

@Shushishtok Shushishtok commented Sep 19, 2024

This PR is a QoL for handling AI Triggers, which can be cumbersome when handling multiple (usually 3) difficulty levels, as they require manually creating TaskForces, TeamTypes and AI Triggers for each difficulty. This aims to assist by introducing a script that can be selected to automate this process, cloning a single AI Trigger for Hard difficulty to three identical AI Triggers, each with their own duplicated TeamTypes and TaskForces.

This draws inspiration from the same script in Triggers, adjusted to work with AI Triggers instead.

  • Supports both Primary and Secondary Team Types.
  • Supports cases where duplicated Team Types already exist, usually due to another AI Trigger using them (in which case it will not try to duplicate them, but instead set them automatically)
  • Supports cases where an AI Trigger doesn't have a Team Type assigned.

Additionally, introduces some helpers to refer to difficulty levels without having to manually write or declare them.

Copy link
Member

@Rampastring Rampastring left a comment

Choose a reason for hiding this comment

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

Looks good aside from a couple of stylistic nitpicks.

src/TSMapEditor/Helpers.cs Outdated Show resolved Hide resolved
src/TSMapEditor/Helpers.cs Outdated Show resolved Hide resolved
src/TSMapEditor/Helpers.cs Outdated Show resolved Hide resolved
@Rampastring Rampastring merged commit a1491e7 into CnCNet:master Sep 23, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants