void Awake() { if (instance == null) { instance = this; } updateMaterial(); }
/// <summary> /// Init the cursor /// </summary> protected override void OnInitializeCursor() { selector = HexTerrain.CreateTileSelector(controller.color, 1.5f, 0.9f); AlphaPingPong anim = selector.AddComponent <AlphaPingPong>(); anim.intensity = 0.5f; selector.transform.position = Vector3.forward * 10000.0f; if (GameController.state == GameState.Exploration) { HexCamera.ShowMask(character, maxRange); } updateTargets(); updateSelector(); }
protected override void OnHideCursor() { HexCamera.HideMask(character); selector.gameObject.SetActive(false); }
protected override void OnHideCursor() { HexTerrain.DestroyBorder(outlineHandle); HexCamera.HideMask(character); selector.gameObject.SetActive(false); }