Skip to content

Commit

Permalink
doc finish
Browse files Browse the repository at this point in the history
  • Loading branch information
NetsuNegi committed Sep 18, 2024
1 parent 32e6147 commit 730c1d4
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 2 deletions.
1 change: 1 addition & 0 deletions CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ This page lists all the individual contributions to the project by their author.
- **NetsuNegi**
- Forbidding parallel AI queues by type
- Cloak Enhancement
- Exclusive SuperWeapon Sidebar
- **Apollo** - Translucent SHP drawing patches
- **ststl**
- Customizable ShowTimer priority of superweapons
Expand Down
22 changes: 22 additions & 0 deletions docs/User-Interface.md
Original file line number Diff line number Diff line change
Expand Up @@ -380,3 +380,25 @@ In `RA2MD.ini`:
[Phobos]
ToolTipBlur=false ; boolean, whether the blur effect of tooltips will be enabled.
```

### Exclusive SuperWeapon Sidebar

![image](_static/images/exclusive-sw-sidebar.png)

- It is possible to put sw cameos on the left of screen like C&C3 when `ExclusiveSuperWeaponSidebar` is true.
- In theory, it should be compatible with Ares
- Cameos arranged in a pyramid shape.
- `ExclusiveSuperWeaponSidebar.Max` controls the maximum number of icons on the leftmost side, which also depends on the current game resolution.

In `uimd.ini`:
```ini
[Sidebar]
ExclusiveSuperWeaponSidebar=false ; boolean
ExclusiveSuperWeaponSidebar.Max=0 ; integer
```

In `rulesmd.ini`
```ini
[SuperWeapon]
AllowInExclusiveSidebar=true ; boolean
```
1 change: 1 addition & 0 deletions docs/Whats-New.md
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,7 @@ New:
- Chrono sparkle animation display customization and improvements (by Starkku)
- Script action to Chronoshift teams to enemy base (by Starkku)
- Cloak Enhancement (by NetsuNegi)
- Exclusive SuperWeapon Sidebar

Vanilla fixes:
- Allow AI to repair structures built from base nodes/trigger action 125/SW delivery in single player missions (by Trsdy)
Expand Down
Binary file added docs/_static/images/exclusive-sw-sidebar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions src/Ext/Sidebar/TacticalButtonClass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ bool TacticalButtonClass::Draw(bool forced)
}
}

if (pSuper->IsCharged && !pCurrent->CanTransactMoney(pSWExt->Money_Amount) || (pSWExt->SW_UseAITargeting && !AresFunctions::IsTargetConstraintsEligible(AresFunctions::SWTypeExtMap_Find(pSuper->Type), HouseClass::CurrentPlayer, true)))
if (pSuper->IsCharged && !pCurrent->CanTransactMoney(pSWExt->Money_Amount) || (pSWExt->SW_UseAITargeting && AresHelper::CanUseAres && !AresFunctions::IsTargetConstraintsEligible(AresFunctions::SWTypeExtMap_Find(pSuper->Type), HouseClass::CurrentPlayer, true)))
{
RectangleStruct darkenBounds { 0, 0, location.X + this->Width, location.Y + this->Height };
pSurface->DrawSHP(FileSystem::SIDEBAR_PAL, FileSystem::DARKEN_SHP, 0, &location, &darkenBounds, BlitterFlags::bf_400 | BlitterFlags::Darken, 0, 0, ZGradient::Ground, 1000, 0, nullptr, 0, 0, 0);
Expand Down Expand Up @@ -162,7 +162,7 @@ bool TacticalButtonClass::LaunchSuper(int superIdx)
VoxClass::PlayIndex(pSWExt->EVA_InsufficientFunds);
pSWExt->PrintMessage(pSWExt->Message_InsufficientFunds, pCurrent);
}
else if (!pSWExt->SW_UseAITargeting || AresFunctions::IsTargetConstraintsEligible(AresFunctions::SWTypeExtMap_Find(pSuper->Type), HouseClass::CurrentPlayer, true))
else if (!pSWExt->SW_UseAITargeting || (AresHelper::CanUseAres && AresFunctions::IsTargetConstraintsEligible(AresFunctions::SWTypeExtMap_Find(pSuper->Type), HouseClass::CurrentPlayer, true)))
{
if (!manual && !unstopable)
{
Expand Down

0 comments on commit 730c1d4

Please sign in to comment.