public void OnReceived(ProjectileDisappearedMessage projectileDisappearedMessage) { if (gameState == GameState.InGame) { inGame.OnReceived(projectileDisappearedMessage); } }
public void OnReceived(ProjectileDisappearedMessage projectileDisappearedMessage) { var fix = projectileDisappearedMessage.Fix.Value; if (projectileDisappearedMessage.Collision.HasValue) { Action action = () => { ProcessProjectileDisappearedMessage(fix.ProjectileId, projectileDisappearedMessage.Collision.Value.Fix.Value); }; ProcessAction(action); } else { Action action = () => { ProcessProjectileDisappearedMessage(fix.ProjectileId); }; ProcessAction(action); } }