mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-12-13 04:36:59 +00:00
coreinit: Clean up time functions
This commit is contained in:
parent
c714e8cb6b
commit
ec2d7c086a
16 changed files with 40 additions and 51 deletions
|
|
@ -267,7 +267,7 @@ namespace vpad
|
|||
{
|
||||
if (channel <= 1 && vpadDelayEnabled)
|
||||
{
|
||||
uint64 currentTime = coreinit::coreinit_getOSTime();
|
||||
uint64 currentTime = coreinit::OSGetTime();
|
||||
const auto dif = currentTime - vpad::g_vpad.controller_data[channel].drcLastCallTime;
|
||||
if (dif <= (ESPRESSO_TIMER_CLOCK / 60ull))
|
||||
{
|
||||
|
|
@ -1149,7 +1149,7 @@ namespace vpad
|
|||
void start()
|
||||
{
|
||||
coreinit::OSCreateAlarm(&g_vpad.alarm);
|
||||
const uint64 start_tick = coreinit::coreinit_getOSTime();
|
||||
const uint64 start_tick = coreinit::OSGetTime();
|
||||
const uint64 period_tick = coreinit::EspressoTime::GetTimerClock() * 5 / 1000;
|
||||
const MPTR handler = PPCInterpreter_makeCallableExportDepr(TickFunction);
|
||||
coreinit::OSSetPeriodicAlarm(&g_vpad.alarm, start_tick, period_tick, handler);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue