public void UpdateScore(ShootingGalleryScoreUpdateMessage updateMessage, int remainingTargets) { foreach (Scoreboard board in scoreboards) { board.UpdateScore(updateMessage, remainingTargets); } scoreOnlyBoard?.UpdateScore(updateMessage, remainingTargets); }
private void OnScoreUpdate(ShootingGalleryScoreUpdateMessage update) { PlayerController pc = GetPlayerView(update.entityID); if (pc != null) { pc.ShowTargetHit(); } targetsController.DestroyTargetByUID(update.targetUID); scoreboardController.UpdateScore(update, targetsController.GetRemainingTargets()); }
public void UpdateScore(ShootingGalleryScoreUpdateMessage updateMessage, int remainingTargets) { ScoreboardEntry entryForView = GetEntryByID(updateMessage.entityID); if (entryForView != null) { entryForView.UpdateScore(updateMessage.score); UpdateEntryOrder(); } else { LSLog.LogError("Tried to Update a score but couldn't find an entry!"); } SetTargetsText(remainingTargets); }