mirror of
https://github.com/roflmuffin/CounterStrikeSharp.git
synced 2025-12-05 23:58:24 -08:00
chore: update hl2sdk (#336)
This commit is contained in:
@@ -18,8 +18,10 @@ SET(SOURCE_FILES
|
||||
src/mm_plugin.h
|
||||
libraries/hl2sdk-cs2/tier1/convar.cpp
|
||||
libraries/hl2sdk-cs2/tier1/generichash.cpp
|
||||
libraries/hl2sdk-cs2/tier1/keyvalues3.cpp
|
||||
libraries/hl2sdk-cs2/entity2/entityidentity.cpp
|
||||
libraries/hl2sdk-cs2/entity2/entitysystem.cpp
|
||||
libraries/hl2sdk-cs2/entity2/entitykeyvalues.cpp
|
||||
libraries/dotnet/hostfxr.h
|
||||
libraries/dotnet/coreclr_delegates.h
|
||||
libraries/metamod-source/core/sourcehook/sourcehook.cpp
|
||||
|
||||
Submodule libraries/hl2sdk-cs2 updated: 2f9dd2e61a...43bfe744a1
@@ -84,6 +84,9 @@ bool gameLoopInitialized = false;
|
||||
GetLegacyGameEventListener_t* GetLegacyGameEventListener = nullptr;
|
||||
std::thread::id gameThreadId;
|
||||
|
||||
// Based on 64 fixed tick rate
|
||||
const float engine_fixed_tick_interval = 0.015625f;
|
||||
|
||||
void Initialize()
|
||||
{
|
||||
modules::engine = new modules::CModule(ROOTBIN, "engine2");
|
||||
|
||||
@@ -110,6 +110,8 @@ extern ISmmAPI *ismm;
|
||||
extern CCoreConfig* coreConfig;
|
||||
extern CGameConfig* gameConfig;
|
||||
|
||||
extern const float engine_fixed_tick_interval;
|
||||
|
||||
typedef IGameEventListener2 *GetLegacyGameEventListener_t(CPlayerSlot slot);
|
||||
|
||||
extern bool gameLoopInitialized;
|
||||
|
||||
@@ -107,7 +107,7 @@ void TimerSystem::OnGameFrame(bool simulating)
|
||||
m_has_map_simulated = true;
|
||||
}
|
||||
} else {
|
||||
timers::universal_time += globals::getGlobalVars()->interval_per_tick;
|
||||
timers::universal_time += globals::engine_fixed_tick_interval;
|
||||
}
|
||||
|
||||
m_last_ticked_time = globals::getGlobalVars()->curtime;
|
||||
|
||||
@@ -61,7 +61,7 @@ bool IsMapValid(ScriptContext& script_context)
|
||||
|
||||
float GetTickInterval(ScriptContext& script_context)
|
||||
{
|
||||
return globals::getGlobalVars()->interval_per_tick;
|
||||
return globals::engine_fixed_tick_interval;
|
||||
}
|
||||
|
||||
float GetCurrentTime(ScriptContext& script_context) { return globals::getGlobalVars()->curtime; }
|
||||
|
||||
Reference in New Issue
Block a user