diff options
| author | boris <wzn@moneybot.cc> | 2019-01-02 17:46:05 +1300 |
|---|---|---|
| committer | boris <wzn@moneybot.cc> | 2019-01-02 17:46:05 +1300 |
| commit | d1ec3d3bb3a87a08e1c9348ca6e482549ebde664 (patch) | |
| tree | b1b4d86bdc9e9c83a02e2ad3258a61674421eb07 /cheat/internal_rewrite | |
| parent | 16b4fd429ecaf259c4e2bd7307431f3c855812e8 (diff) | |
fixed bug and idk
i really dont wanna work on this anymore holy fuck
Diffstat (limited to 'cheat/internal_rewrite')
| -rw-r--r-- | cheat/internal_rewrite/extra.cpp | 9 | ||||
| -rw-r--r-- | cheat/internal_rewrite/extra.hpp | 2 | ||||
| -rw-r--r-- | cheat/internal_rewrite/internal_rewrite.vcxproj | 2 |
3 files changed, 8 insertions, 5 deletions
diff --git a/cheat/internal_rewrite/extra.cpp b/cheat/internal_rewrite/extra.cpp index 2cffb39..66aba08 100644 --- a/cheat/internal_rewrite/extra.cpp +++ b/cheat/internal_rewrite/extra.cpp @@ -87,7 +87,7 @@ namespace features // emplace new record
netchan_record_t record{
- g_csgo.m_globals->m_realtime,
+ g_csgo.m_globals->m_curtime,
netchan->m_nInReliableState,
netchan->m_nInSequenceNr
};
@@ -99,7 +99,7 @@ namespace features // clear outdated records
for( size_t i{ }; i < m_net_records.size( ); ++i ) {
- const float delta = g_csgo.m_globals->m_realtime - m_net_records.at( i ).m_realtime;
+ const float delta = g_csgo.m_globals->m_curtime - m_net_records.at( i ).m_curtime;
// 200ms is the max we can fake anyway..
// hnn this might be why it's so fucked :/
@@ -109,6 +109,9 @@ namespace features }
void c_extra::add_latency( INetChannel* channel ) {
+ if(!g_settings.misc.net_fakelag())
+ return;
+
auto nci = g_csgo.m_engine( )->GetNetChannelInfo( );
float in_latency = nci->GetLatency( 0 );
@@ -118,7 +121,7 @@ namespace features if( g_ctx.m_local && g_ctx.m_local->is_valid( ) ) {
// god this is autistic
for( auto& it : m_net_records ) {
- const float delta = g_csgo.m_globals->m_realtime - it.m_realtime;
+ const float delta = g_csgo.m_globals->m_curtime - it.m_curtime;
if( delta >= latency ) {
// apply latency
diff --git a/cheat/internal_rewrite/extra.hpp b/cheat/internal_rewrite/extra.hpp index 5c7d5f4..f3ab837 100644 --- a/cheat/internal_rewrite/extra.hpp +++ b/cheat/internal_rewrite/extra.hpp @@ -9,7 +9,7 @@ namespace features // i'm gay
struct netchan_record_t {
- float m_realtime;
+ float m_curtime;
int32_t m_reliable;
int32_t m_sequence;
};
diff --git a/cheat/internal_rewrite/internal_rewrite.vcxproj b/cheat/internal_rewrite/internal_rewrite.vcxproj index f75393b..3d30b5a 100644 --- a/cheat/internal_rewrite/internal_rewrite.vcxproj +++ b/cheat/internal_rewrite/internal_rewrite.vcxproj @@ -46,7 +46,7 @@ <VCProjectVersion>15.0</VCProjectVersion>
<ProjectGuid>{140DEC51-B0E7-4289-BB6F-79686422318E}</ProjectGuid>
<RootNamespace>internal_rewrite</RootNamespace>
- <WindowsTargetPlatformVersion>10.0.17134.0</WindowsTargetPlatformVersion>
+ <WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
<ProjectName>csgo</ProjectName>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
