Ejemplo n.º 1
0
    private void Start()
    {
        boardController = GetComponentInParent <BoardController>();
        uiController    = GetComponentInParent <UiController>();
        arrowRenderer   = GetComponentInChildren <ArrowRenderer>();
        outline         = GetComponent <Outline>();
        if (this.item.ItemRarity.Equals(ItemRarity.Trash))
        {
            this.outline.OutlineColor = Color.gray;
        }
        else if (this.item.ItemRarity.Equals(ItemRarity.Common))
        {
            this.outline.OutlineColor = Color.green;
        }
        else if (this.item.ItemRarity.Equals(ItemRarity.Rare))
        {
            this.outline.OutlineColor = Color.blue;
        }
        else if (this.item.ItemRarity.Equals(ItemRarity.Artifact))
        {
            this.outline.OutlineColor = new Color(190, 65, 0); //orange
        }
        this.outline.OutlineWidth = this.item.outlineWidth;

        belowTheScreen = new Vector3(0, -10, 0);
    }
Ejemplo n.º 2
0
 protected void DeleteParabola()
 {
     if (arrow)
     {
         EffectManager.instance.DeleteEffect(arrow.gameObject);
         arrow = null;
     }
 }
Ejemplo n.º 3
0
 protected void DrawParabola()
 {
     if (arrow == null)
     {
         Vector3 pos = spellCaster.transform.position;
         arrow = EffectManager.instance.MakeEffect("ArrowRenderer", pos, Quaternion.identity).GetComponent <ArrowRenderer>();
         CursorStalker.GameCursor.track = arrow.GetComponent <TrackerArrow>();
     }
 }
Ejemplo n.º 4
0
    void Start()
    {
        if (player_rBody == null)
        {
            Debug.LogError("Player_rBody must be assigned for UI to work");
        }

        speedometerText        = UISpeedometer.GetComponent <Text>();
        dampeningIndicatorText = UIDampeningIndicator.GetComponent <Text>();
        arrowRenderer          = UIVelocityArrow.GetComponent <ArrowRenderer>();
    }
Ejemplo n.º 5
0
    protected void DrawParabola()
    {
        if (arrow == null)
        {
            Vector3 pos = spellCaster.transform.position;
            arrow = EffectManager.instance.MakeEffect("ArrowRenderer", pos).GetComponent <ArrowRenderer>();
        }

        if (casterhair == null)
        {
            casterhair = EffectManager.instance.MakeEffect("CasterHair");
            casterhair.transform.position = spellCaster.transform.position;
        }
    }
Ejemplo n.º 6
0
    protected void DeleteParabola()
    {
        if (arrow)
        {
            EffectManager.instance.DeleteEffect(arrow.gameObject);
            arrow = null;
        }

        if (casterhair != null)
        {
            EffectManager.instance.DeleteEffect(casterhair);
            casterhair = null;
        }
    }
Ejemplo n.º 7
0
    public void SetRenderer(ArrowRenderer value)
    {
        if (arrowRenderer)
        {
            arrowRenderer.gameObject.SetActive(false);
        }

        arrowRenderer = value;

        if (arrowRenderer)
        {
            arrowRenderer.gameObject.SetActive(true);
        }
    }
Ejemplo n.º 8
0
 public void Start()
 {
     renderer = this.GetComponent <ArrowRenderer>();
     this.SetVisible(false);
     this.gameObject.SetZ(Constants.ARROW_Z);
 }