-
Notifications
You must be signed in to change notification settings - Fork 250
annotate orders.lua #6558
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
base: develop
Are you sure you want to change the base?
annotate orders.lua #6558
Conversation
|
It appears that #6557 was merged in with an invalid snippet format. It states |
|
Yoink. Not totally clean, but I'll fix it in this PR instead of making a new one? |
|
@clyfordv Is it okay with you if I rebase and force push this branch? It will make reviewing it easier for me since it will get rid of the commits you branched off from. |
23c6f7b to
e30b8fa
Compare
lL1l1
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@clyfordv I went through the PR and wrote suggestions for the PR in clyfordv#2 since they covered quite some details. If you could review the suggestions over there and merge it in then I can approve this one.
| ---@class UserUnit: InternalObject | ||
| ---@field ThreadUnpause? thread | ||
| ---@field ThreadUnpauseCandidates? table<EntityId, boolean> | ||
| ---@field Dead boolean |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This value only exists for the Sim Unit. The references to it in orders.lua are from a large engine-call refactor in 63e81c4, which caught the User version of IsDead.
| ---@field Dead boolean |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in the PR with the suggestions*
|
|
||
| --- Creates a sim callback to set the priorities of the selected units | ||
| ---@param prioritiesString string A string of categories | ||
| ---@param prioritiesString string | number A string of categories |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I address this more extensively in #6680, but it suffices to fix the warnings in order.lua.
| ---@param variable string | ||
| ---@param value string | ||
| local function IsToggleMode(unitList, variable, value) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is too ambiguous so I fixed it.
The return value was also missing, and I fixed that too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in the PR with the suggestions*
Description of the proposed changes
Annotates functions and squashes errors in orders.lua w/ small changes to related files.
Branched from: #6557