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

[New Feature] Autoload Command Shortcut #1452

Open
wants to merge 66 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 48 commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
0e604e4
max variety autoload and recursive autoload
psi-cmd Dec 13, 2024
7bc526b
Implement autoload hotkey
psi-cmd Dec 14, 2024
831097e
Implement Autoload Shortcut
psi-cmd Dec 14, 2024
ea03a24
ares tags support
Aephiex Dec 14, 2024
1fba9d4
smarter passenger and vehicle distinction by size
Aephiex Dec 14, 2024
7b5dfad
fix not working
Aephiex Dec 14, 2024
142e751
remove redundant check
Aephiex Dec 14, 2024
bde01c4
comments
Aephiex Dec 14, 2024
caa7a13
mind control support
Aephiex Dec 14, 2024
8f3a38a
mind control support part 2
Aephiex Dec 14, 2024
817147c
prevent CaptureManager null pointer
Aephiex Dec 14, 2024
2e143f0
Merge pull request #1 from Aephiex/autoload
psi-cmd Dec 14, 2024
91f51d2
fix nullptr case not tested
psi-cmd Dec 14, 2024
d57a878
merge with latest develop
psi-cmd Dec 14, 2024
873ff7c
bracket style adjustment
psi-cmd Dec 14, 2024
c17d0b3
Fix transport remaining size calculation
Aephiex Dec 15, 2024
3a6163e
fix comments misleading
Aephiex Dec 15, 2024
01a0c42
Merge pull request #2 from Aephiex/patch-1
psi-cmd Dec 15, 2024
c17f008
code style repair
psi-cmd Dec 15, 2024
6f93c6f
merge fix
psi-cmd Dec 15, 2024
32d0cd7
Add support for bio reactors and tank bunkers
Aephiex Dec 15, 2024
e08b42d
name convention fix after merge
psi-cmd Dec 15, 2024
328ef01
fix no manual enter
Aephiex Dec 15, 2024
ab09055
Update AutoLoad.cpp
Aephiex Dec 15, 2024
0db3a2b
Merge branch 'autoload' into patch-1
Aephiex Dec 15, 2024
219a181
Update AutoLoad.cpp
Aephiex Dec 15, 2024
6cd4cdc
Update Body.h
Aephiex Dec 15, 2024
d9c89a5
Update Body.cpp
Aephiex Dec 15, 2024
3f565c6
Update AutoLoad.cpp
Aephiex Dec 15, 2024
aaff634
by size should be default true
Aephiex Dec 15, 2024
21ec9f3
maybe we should use the "second" as sort of budget value so it is sim…
Aephiex Dec 15, 2024
656121f
oh, one line left
Aephiex Dec 15, 2024
1f121c6
update comment
Aephiex Dec 15, 2024
7a2bd49
larger passengers are loaded first
Aephiex Dec 16, 2024
e495829
Merge pull request #3 from Aephiex/patch-1
psi-cmd Dec 16, 2024
8e40291
solve multiplayer desync
Aephiex Dec 16, 2024
2bc4855
Merge pull request #4 from Aephiex/patch-1
psi-cmd Dec 16, 2024
d062623
Update CREDITS.md
Aephiex Dec 16, 2024
eb1e5e1
Update Whats-New.md
Aephiex Dec 16, 2024
f5dbb3b
Update User-Interface.md
Aephiex Dec 16, 2024
75eb1aa
Merge pull request #5 from Aephiex/patch-1
psi-cmd Dec 16, 2024
b8aed4d
Ignore Force for Clicked Action
psi-cmd Dec 16, 2024
4aa1c0f
get rid of type warning
psi-cmd Dec 16, 2024
bf06f8f
Update User-Interface.md
Aephiex Dec 17, 2024
370fa70
Update Body.cpp
Aephiex Dec 17, 2024
1550d31
Update Body.cpp
Aephiex Dec 17, 2024
836722b
move out from development commands and code clean.
psi-cmd Dec 18, 2024
0f23cca
Merge pull request #6 from Aephiex/patch-1
psi-cmd Dec 18, 2024
f121f60
style fix
psi-cmd Dec 20, 2024
dd403ec
Update CREDITS.md
psi-cmd Dec 20, 2024
36456fd
Update AutoLoad.cpp
Aephiex Dec 21, 2024
8520a5f
Update AutoLoad.cpp
Aephiex Dec 21, 2024
d94a680
Update Body.h
Aephiex Dec 21, 2024
de34130
Update Body.cpp
Aephiex Dec 21, 2024
f3b2029
Update User-Interface.md
Aephiex Dec 21, 2024
5a25372
Update AutoLoad.cpp
Aephiex Dec 21, 2024
2f78fa0
Update AutoLoad.cpp
Aephiex Dec 21, 2024
5b0dd74
Merge pull request #7 from Aephiex/patch-1
psi-cmd Dec 21, 2024
6385f63
Update AutoLoad.cpp
Aephiex Dec 21, 2024
da540d6
Update AutoLoad.cpp
Aephiex Dec 21, 2024
df6ce6e
Merge pull request #8 from Aephiex/patch-1
psi-cmd Dec 23, 2024
0f6c255
fix tank bunker filter
Aephiex Dec 23, 2024
bba2745
pBuilding->Type
Aephiex Dec 23, 2024
6aef490
style and details
Aephiex Dec 24, 2024
117add1
typo
Aephiex Dec 24, 2024
2804cdc
tank bunker check use YR function
Aephiex Dec 24, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -408,3 +408,4 @@ This page lists all the individual contributions to the project by their author.
- **Damfoos** - extensive and thorough testing
- **Dmitry Volkov** - extensive and thorough testing
- **Rise of the East community** - extensive playtesting of in-dev features
- **psi-cmd**, **Aephiex** - autoload hotkey command
psi-cmd marked this conversation as resolved.
Show resolved Hide resolved
2 changes: 2 additions & 0 deletions Phobos.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
<ClCompile Include="src\Commands\ToggleDesignatorRange.cpp" />
<ClCompile Include="src\Commands\ToggleDigitalDisplay.cpp" />
<ClCompile Include="src\Commands\SaveVariablesToFile.cpp" />
<ClCompile Include="src\Commands\AutoLoad.cpp" />
<ClCompile Include="src\Ext\Anim\Body.cpp" />
<ClCompile Include="src\Ext\Anim\Hooks.cpp" />
<ClCompile Include="src\Ext\Anim\Hooks.AnimCreateUnit.cpp" />
Expand Down Expand Up @@ -196,6 +197,7 @@
<ClInclude Include="src\Commands\ToggleDesignatorRange.h" />
<ClInclude Include="src\Commands\ToggleDigitalDisplay.h" />
<ClInclude Include="src\Commands\SaveVariablesToFile.h" />
<ClInclude Include="src\Commands\AutoLoad.h" />
<ClInclude Include="src\Ext\Bullet\Trajectories\BombardTrajectory.h" />
<ClInclude Include="src\Ext\Bullet\Trajectories\PhobosTrajectory.h" />
<ClInclude Include="src\Ext\Bullet\Trajectories\StraightTrajectory.h" />
Expand Down
12 changes: 12 additions & 0 deletions docs/User-Interface.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,18 @@ SelectionFlashDuration=0 ; integer, number of frames
- Switches on/off [frame by frame mode](Miscellanous.html#frame-step-in).
- For localization add `TXT_FRAME_BY_FRAME` and `TXT_FRAME_BY_FRAME_DESC` into your `.csf` file.

### `[ ]` Auto Load
- A shortcut to quickly command multiple units to board multiple transports at a same time. Select units and valid transports, then press the auto load hotkey, the units will be distributed among the transports and will be ordered to board them.
- Transports can be considered passengers if fully loaded, or `NoManualEnter=yes`, or it can't actually load anything from the selected passengers.
- Larger passengers are loaded first, and transports with smaller size limits are used first.
- At a given unit size and size limit, passengers will be diversely distributed into transports if possible.
- Ares `Passengers.Allowed=` and `Passengers.Disallowed=` are taken into account.
- It also supports Bio Reactors and Tank Bunkers. Select valid candidates and multiple said buildings while pressing Shift, then press the auto load hotkey, the units will be distributed among these buildings and will be ordered to enter them.
Copy link
Member

Choose a reason for hiding this comment

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

What about Soviet Battle Bunkers and other structures that you own and can select and can have garrisons?

Copy link
Contributor

Choose a reason for hiding this comment

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

Garrisonable structures are currently not supported. Neutral structures and owned troops can't be selected at a same time. Also can't read the user's intention when a bio reactor, a battle bunker, and a group of conscripts are selected at a same time. Maybe we need another shortcut key for that.

Copy link
Member

Choose a reason for hiding this comment

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

Also can't read the user's intention when a bio reactor, a battle bunker, and a group of conscripts are selected at a same time.

Everyone who can fit in bio reactor but not the garrison goes to bio reactor, everyone else is spread between bunkers and reactors. I think the situation when battle bunkers and reactors will be selected is rather rare so there's no need to do much thought about it

Copy link
Contributor

Choose a reason for hiding this comment

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

You are right. I will add such support later. However since neutral structures still can't be selected with owned troops at a same time, this will only ease the loading of battle bunkers, which is always owned by a player even when not garrisoned.

- If auto board transport can happen among selected units, then said logic takes precedence.
- A building is viewed as a Bio Reactor if it has `Passengers` >= 1, and it has `InfantryAbsorb=yes`.
- A building is viewed as a Tank Bunker if it has `Bunker=yes`.
- For localization add `TXT_AUTO_LOAD` and `TXT_AUTO_LOAD_DESC` into your `.csf` file.

## Loading screen

- PCX files can now be used as loadscreen images.
Expand Down
1 change: 1 addition & 0 deletions docs/Whats-New.md
Original file line number Diff line number Diff line change
Expand Up @@ -470,6 +470,7 @@ New:
- `<Player @ X>` can now be used as owner for pre-placed objects on skirmish and multiplayer maps (by Starkku)
- Allow customizing charge turret delays per burst on a weapon (by Starkku)
- Unit `Speed` setting now accepts floating point values (by Starkku)
- Autoload hotkey command (by psi-cmd, Aephiex)

Vanilla fixes:
- Allow AI to repair structures built from base nodes/trigger action 125/SW delivery in single player missions (by Trsdy)
Expand Down
Loading