[Utils] Rename interval update method

This commit is contained in:
momo5502 2016-11-13 12:10:51 +01:00
parent 091c604675
commit 9d3af2cd69
3 changed files with 5 additions and 5 deletions

View File

@ -104,7 +104,7 @@ namespace Components
if(check.Elapsed(20s)) if(check.Elapsed(20s))
{ {
check.Set(); check.Update();
if (HANDLE h = OpenProcess(PROCESS_VM_READ, TRUE, GetCurrentProcessId())) if (HANDLE h = OpenProcess(PROCESS_VM_READ, TRUE, GetCurrentProcessId()))
{ {
@ -127,7 +127,7 @@ namespace Components
if (check.Elapsed(30s)) if (check.Elapsed(30s))
{ {
check.Set(); check.Update();
unsigned long flags = ((AntiCheat::IntergrityFlag::MAX_FLAG - 1) << 1) - 1; unsigned long flags = ((AntiCheat::IntergrityFlag::MAX_FLAG - 1) << 1) - 1;
@ -162,7 +162,7 @@ namespace Components
{ {
// Perform check only every 10 seconds // Perform check only every 10 seconds
if (!AntiCheat::LastCheck.Elapsed(10s)) return; if (!AntiCheat::LastCheck.Elapsed(10s)) return;
AntiCheat::LastCheck.Set(); AntiCheat::LastCheck.Update();
// Hash .text segment // Hash .text segment
// Add 1 to each value, so searching in memory doesn't reveal anything // Add 1 to each value, so searching in memory doesn't reveal anything

View File

@ -4,7 +4,7 @@ namespace Utils
{ {
namespace Time namespace Time
{ {
void Interval::Set() void Interval::Update()
{ {
this->LastPoint = std::chrono::high_resolution_clock::now(); this->LastPoint = std::chrono::high_resolution_clock::now();
} }

View File

@ -10,7 +10,7 @@ namespace Utils
public: public:
Interval() : LastPoint(std::chrono::high_resolution_clock::now()) {} Interval() : LastPoint(std::chrono::high_resolution_clock::now()) {}
void Set(); void Update();
bool Elapsed(std::chrono::nanoseconds nsecs); bool Elapsed(std::chrono::nanoseconds nsecs);
}; };
} }