Skip to content

Commit

Permalink
Remove RA2Mode specialization for it
Browse files Browse the repository at this point in the history
  • Loading branch information
chaserli committed Sep 17, 2024
1 parent 916afee commit 63f72f4
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 20 deletions.
2 changes: 1 addition & 1 deletion YRpp
Submodule YRpp updated 1 files
+21 −4 HouseClass.h
17 changes: 0 additions & 17 deletions src/HardEndStuff/Ra2Mode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -178,23 +178,6 @@ bool Ra2Mode::CheckSaveGameID(const char* saveGameName)
return false;
}

// Allow allies to repair on service depot
DEFINE_HOOK(0x700594, TechnoClass_WhatAction__AllowAlliesRepair, 0x5)
{
if (!Ra2Mode::IsEnabled())
return 0;

GET(TechnoClass*, pThis, ESI);
GET(ObjectClass*, pObject, EDI);

auto const pBuilding = abstract_cast<BuildingClass* const>(pObject);
auto const pBuildingOwner = pBuilding ? pBuilding->Owner : nullptr;

return (pBuildingOwner && pBuildingOwner->IsAlliedWith(pThis))
? 0x70059D
: 0x7005E6;
}

// Allow to repair the BlackHawk Transport on service depot
#pragma region AllowRepairFlyMZone

Expand Down
2 changes: 0 additions & 2 deletions src/Misc/Observers.Visibility.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,6 @@ DEFINE_HOOK(0x4AE62B, DisplayClass_HelpText_Cloak, 0x5)
return CheckSensedByHouses;
}

#ifndef IS_HARDEND_VER
// Allow showing the select cursor on the object
DEFINE_HOOK(0x700594, TechnoClass_WhatAction__AllowAllies, 0x5)
{
Expand All @@ -174,7 +173,6 @@ DEFINE_HOOK(0x700594, TechnoClass_WhatAction__AllowAllies, 0x5)

return pThis->Owner->IsAlliedWith(pObject) ? 0x70059D : 0x7005E6;
}
#endif

// Show disguised units (Spy and Mirage) for observer
#pragma region
Expand Down

0 comments on commit 63f72f4

Please sign in to comment.