public virtual void SelectPlanet(PlanetPreview planetPreview) { Core.GameState.CurrentTarget = planetPreview.planet; foreach (var preview in this.previews) { preview.Button.interactable = false; } }
public override void SelectPlanet(PlanetPreview planetPreview) { base.SelectPlanet(planetPreview); if (planetPreview.IsScanned) { this.Move(Core.GameState.ConsumptionRates.Movement, SceneNames.Planet); } else { planetPreview.Scan(OnScanCompleted); } }
private void RefreshPlanetViews() { if (Core.GameState.Planets.Count == previews.Count) { for (int i = 0; i < previews.Count; i++) { PlanetPreview planetPreview = previews[i]; Planet planet = Core.GameState.Planets[i]; planetPreview.planet = planet; Text type = planetPreview.type; type.text = planet.Type; Image planetImage = planetPreview.planetBase; planetImage.color = planet.BaseColor; } } }
private void RefreshPlanetViews() { for (int i = 0; i < previews.Count; i++) { PlanetPreview planetPreview = previews[i]; Planet planet = Core.GameState.Planets[i]; planetPreview.planet = planet; Text type = planetPreview.type; type.text = planet.Type; Image planetBase = planetPreview.planetBase; planetBase.color = planet.BaseColor; if (planet == Core.GameState.CurrentTarget) { planetPreview.RevealResources(); } else if (Core.GameState.Planets[i].Scanned) { planetPreview.RevealResources(); } } }
public override void SelectPlanet(PlanetPreview planetPreview) { base.SelectPlanet(planetPreview); planetPreview.Scan(OnScanCompleted); }