public PlanetView GetPlanetView(TilemapCircle tilemapCircle) { if (tilemapCircle is Planet) { return(GetPlanetView(((Planet)tilemapCircle).ThingIndex)); } return(null); }
public bool ExistsPlanetView(TilemapCircle tilemapCircle) { if (tilemapCircle is Planet) { return(planetViews[((Planet)tilemapCircle).ThingIndex] != null); } return(false); }
public void Init(TilemapCircleView tilemapCircleView) { this.tilemapCircleView = tilemapCircleView; this.tilemapCircle = tilemapCircleView.TilemapCircle; this.circleNormals = tilemapCircle.CircleNormals; this.circleHeights = tilemapCircle.CircleHeights; meshRenderer.sharedMaterial = this.tilemapCircleView.backgroundMaterial; InitMesh(); }
public void Init(TilemapCircle tilemapCircle) { this.tilemapCircle = tilemapCircle; tilemapCircle.Listener = this; UpdatePosition(); InitRenderers(); UpdateMesh(); }
public void Init(TilemapCircleView tilemapCircleView, int fromX, int toX) { dirty = true; firstTime = true; this.tilemapCircleView = tilemapCircleView; this.tilemapCircle = tilemapCircleView.TilemapCircle; this.fromX = fromX; this.toX = toX; this.circleNormals = tilemapCircle.CircleNormals; this.circleHeights = tilemapCircle.CircleHeights; meshRenderer.sharedMaterial = tilemapCircleView.material; }
public virtual void OnParentChanged(TilemapCircle parent) { parentView = universeView.GetPlanetView(universeObject.parent); UpdatePosition(); }
public virtual void Recycle() { tilemapCircle = null; gameObject.SetActive(false); }