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

PreResolveValidation #81

Closed
zond opened this issue May 16, 2020 · 2 comments
Closed

PreResolveValidation #81

zond opened this issue May 16, 2020 · 2 comments

Comments

@zond
Copy link
Owner

zond commented May 16, 2020

It should be possible to pre-resolve validate orders, which would output warnings only for orders that didn't make sense in the context of that particular nation.

E.g. support orders for their own units that did something not matching the support, or convoy orders for units that didn't match the convoy.

@zond
Copy link
Owner Author

zond commented May 16, 2020

Also, "all units have orders" and "all build/disband orders are provided".

@zond
Copy link
Owner Author

zond commented May 16, 2020

Plan:

State has ValidateNext(godip.Nation) that calls the lates phase's Validate(godip.Validator, godip.Nation) that checks whatever the phase wants to check (enough build/disband orders, all units have orders, whatnot) and then calls ValidatePhase(godip.Validator, godip.Nation) for each order.
The orders will check that there isn't a support for a unit of the same nation that doesn't do the matching thing, and likewise for convoys.

@zond zond closed this as completed in 8c4d323 May 17, 2020
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

No branches or pull requests

1 participant