The std::async calls need a lock on them.
This commit is contained in:
parent
4b2ed2951e
commit
ea89e083dd
3 changed files with 9 additions and 3 deletions
|
@ -64,7 +64,7 @@ void GameEngine::idle(GameEvent ev) {
|
|||
void GameEngine::in_round(GameEvent ev, string &hit_type) {
|
||||
switch(ev) {
|
||||
case GameEvent::HIT:
|
||||
hit(hit_type); // FIXME: bring back error type
|
||||
hit(hit_type);
|
||||
if(is_dead()) {
|
||||
state(GameState::DEAD);
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue