diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/player.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/player.cpp b/src/player.cpp index 1908af4..d9a4a98 100644 --- a/src/player.cpp +++ b/src/player.cpp @@ -242,10 +242,10 @@ void PlayerSystem::receive(const UseItemEvent& uie) } } - /*cool.store(false); - std::thread([&](void) { - std::this_thread::sleep_for(std::chrono::milliseconds(uie.item->cooldown)); + cool.store(false); + std::thread([&](unsigned int ms) { + std::this_thread::sleep_for(std::chrono::milliseconds(ms)); cool.store(true); - }).detach();*/ + }, uie.item->cooldown).detach(); } } |