public void NextPlayerShop() { _currentPlayerIndex++; Console.WriteLine("player index: " + _currentPlayerIndex); Console.WriteLine("number of players: " + A3RData.NumberOfPlayers); if (_currentPlayerIndex > A3RData.NumberOfPlayers - 1) { A3RData.Camera.FocusLock = false; UserInterface.Instance.NotifyUIEvent(this, new UIEventArgs(UIEvent.StartCombat)); } else { A3RData.SelectedPlayer = A3RData.Players[_currentPlayerIndex]; } UIModule = new UI_ShopMenu(A3RData, NextPlayerShop); _scrollingPoint = new CameraFocusPoint(); _scrollingPoint.Vector.Y = A3RData.WindowRect.Height / 2; A3RData.Camera.FocusLock = false; A3RData.Camera.FocusCamera(_scrollingPoint); A3RData.Camera.FocusLock = true; UserInterface.Instance.RefreshUI(); }
public override void EnterState() { _currentPlayerIndex = 0; A3RData.SelectedPlayer = A3RData.Players[_currentPlayerIndex]; UIModule = new UI_ShopMenu(A3RData, NextPlayerShop); _scrollingPoint = new CameraFocusPoint(); _scrollingPoint.Vector.Y = A3RData.WindowRect.Height / 2; Console.WriteLine("Welcome to the shop!"); A3RData.Camera.FocusCamera(_scrollingPoint); A3RData.Camera.FocusLock = true; SwinGame.StopMusic(); SwinGame.PlayMusic("shopDrone"); SwinGame.PlaySoundEffect("entryboomShop"); base.EnterState(); }