Skip to content

Commit

Permalink
Fix for the latest game update on Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
danielkrupinski committed Oct 4, 2024
1 parent 1c36359 commit 8754811
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Source/MemoryPatterns/Linux/ClientPatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ struct ClientPatterns {

[[nodiscard]] cs2::GlobalVars** globalVars() const noexcept
{
return patternFinders.clientPatternFinder("48 89 35 ? ? ? ? 48 89 46"_pat).add(3).abs().template as<cs2::GlobalVars**>();
return patternFinders.clientPatternFinder("8D ? ? ? ? ? 48 89 35 ? ? ? ? 48 89 ? ? C3"_pat).add(9).abs().template as<cs2::GlobalVars**>();
}

[[nodiscard]] cs2::ClientModeCSNormal* clientMode() const noexcept
Expand Down
4 changes: 2 additions & 2 deletions Source/MemoryPatterns/Linux/EntityPatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ struct EntityPatterns {

[[nodiscard]] OffsetToHealth offsetToHealth() const noexcept
{
return patternFinders.clientPatternFinder("8B 87 ? ? ? ? 85 C0 7E ? C7"_pat).add(2).template readOffset<OffsetToHealth>();
return patternFinders.clientPatternFinder("C7 87 ? ? ? ? 00 00 00 00 48 8D 35"_pat).add(2).template readOffset<OffsetToHealth>();
}

[[nodiscard]] OffsetToLifeState offsetToLifeState() const noexcept
Expand All @@ -39,6 +39,6 @@ struct EntityPatterns {

[[nodiscard]] OffsetToOwnerEntity offsetToOwnerEntity() const noexcept
{
return patternFinders.clientPatternFinder("BF ? ? ? ? 8B 8F ? ? ? ?"_pat).add(7).template readOffset<OffsetToOwnerEntity>();
return patternFinders.clientPatternFinder("8B BF ? ? ? ? 8B 8F ? ? ? ?"_pat).add(8).template readOffset<OffsetToOwnerEntity>();
}
};
2 changes: 1 addition & 1 deletion Source/MemoryPatterns/Linux/GameRulesPatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ struct GameRulesPatterns {

[[nodiscard]] cs2::C_CSGameRules** gameRules() const noexcept
{
return patternFinders.clientPatternFinder("4C 8D ? ? ? ? ? 49 8B ? 48 85 FF 0F 84 ? ? ? ? 41 80 BC 24"_pat).add(3).abs().template as<cs2::C_CSGameRules**>();
return patternFinders.clientPatternFinder("83 3D ? ? ? ? 00 74 ? 48 83 C4"_pat).add(2).abs(5).template as<cs2::C_CSGameRules**>();
}

[[nodiscard]] RoundStartTimeOffset roundStartTimeOffset() const noexcept
Expand Down
2 changes: 1 addition & 1 deletion Source/MemoryPatterns/Linux/HostageServicesPatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ struct HostageServicesPatterns {

[[nodiscard]] OffsetToCarriedHostage offsetToCarriedHostage() const noexcept
{
return patternFinders.clientPatternFinder("44 8B 4E ? 89 C7"_pat).add(3).template readOffset<OffsetToCarriedHostage>();
return patternFinders.clientPatternFinder("07 C7 47 ? FF FF FF FF C3"_pat).add(3).template readOffset<OffsetToCarriedHostage>();
}
};
2 changes: 1 addition & 1 deletion Source/MemoryPatterns/Linux/PanoramaLabelPatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ struct PanoramaLabelPatterns {

[[nodiscard]] cs2::CLabel::setTextInternal setTextInternal() const noexcept
{
return patternFinders.clientPatternFinder("31 C9 E8 ? ? ? ? E9"_pat).add(3).abs().template as<cs2::CLabel::setTextInternal>();
return patternFinders.clientPatternFinder("85 ? ? ? ? 31 C9 E8 ? ? ? ?"_pat).add(8).abs().template as<cs2::CLabel::setTextInternal>();
}

[[nodiscard]] std::uint32_t* size() const noexcept
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ struct PanoramaUiEnginePatterns {

[[nodiscard]] cs2::CUIEngine::runScript runScript() const noexcept
{
return patternFinders.panoramaPatternFinder("55 48 89 E5 41 57 41 56 49 89 D6 41 55 49 89 F5 41 54 49"_pat).template as<cs2::CUIEngine::runScript>();
return patternFinders.panoramaPatternFinder("55 48 89 E5 41 57 49 89 CF 41 56 49 89 F6 41 55 41"_pat).template as<cs2::CUIEngine::runScript>();
}

[[nodiscard]] cs2::CUIEngine::makeSymbol makeSymbol() const noexcept
Expand Down
2 changes: 1 addition & 1 deletion Source/MemoryPatterns/Linux/PlantedC4PatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ struct PlantedC4Patterns {

[[nodiscard]] cs2::CUtlVector<cs2::CPlantedC4*>* plantedC4s() const noexcept
{
return patternFinders.clientPatternFinder("0F 85 ? ? ? ? 48 8D 05 ? ? ? ? 8B 10"_pat).add(9).abs().template as<cs2::CUtlVector<cs2::CPlantedC4*>*>();
return patternFinders.clientPatternFinder("? ? ? ? 8B 10 85 D2 0F 8F"_pat).abs().template as<cs2::CUtlVector<cs2::CPlantedC4*>*>();
}

[[nodiscard]] BombSiteOffset m_nBombSite() const noexcept
Expand Down
6 changes: 3 additions & 3 deletions Source/MemoryPatterns/Linux/PlayerPawnPatternsLinux.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ struct PlayerPawnPatterns {

[[nodiscard]] OffsetToPlayerPawnImmunity offsetToPlayerPawnImmunity() const noexcept
{
return patternFinders.clientPatternFinder("75 ? 0F B6 83 ? ? ? ? 5B"_pat).add(5).template readOffset<OffsetToPlayerPawnImmunity>();
return patternFinders.clientPatternFinder("75 ? 0F B6 83 ? ? ? ? 5B 41"_pat).add(5).template readOffset<OffsetToPlayerPawnImmunity>();
}

[[nodiscard]] OffsetToWeaponServices offsetToWeaponServices() const noexcept
Expand All @@ -29,12 +29,12 @@ struct PlayerPawnPatterns {

[[nodiscard]] OffsetToIsPickingUpHostage offsetToIsPickingUpHostage() const noexcept
{
return patternFinders.clientPatternFinder("45 0F B6 AE ? ? ? ? 45 84 ED"_pat).add(4).template readOffset<OffsetToIsPickingUpHostage>();
return patternFinders.clientPatternFinder("45 0F B6 AE ? ? ? ? 45 84 ED 0F"_pat).add(4).template readOffset<OffsetToIsPickingUpHostage>();
}

[[nodiscard]] OffsetToHostageServices offsetToHostageServices() const noexcept
{
return patternFinders.clientPatternFinder("E8 ? ? ? ? 49 8B B5 ? ? ? ? 48 85 F6 0F 84 ? ? ? ? 0F"_pat).add(8).template readOffset<OffsetToHostageServices>();
return patternFinders.clientPatternFinder("C6 4C 89 C7 E8 ? ? ? ? 49 8B ? ? ? ? ?"_pat).add(12).template readOffset<OffsetToHostageServices>();
}

[[nodiscard]] OffsetToFlashBangEndTime offsetToFlashBangEndTime() const noexcept
Expand Down

0 comments on commit 8754811

Please sign in to comment.