Exemple #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);
    }
Exemple #2
0
 protected void DeleteParabola()
 {
     if (arrow)
     {
         EffectManager.instance.DeleteEffect(arrow.gameObject);
         arrow = null;
     }
 }
Exemple #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>();
     }
 }
Exemple #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>();
    }
Exemple #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;
        }
    }
Exemple #6
0
    protected void DeleteParabola()
    {
        if (arrow)
        {
            EffectManager.instance.DeleteEffect(arrow.gameObject);
            arrow = null;
        }

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

        arrowRenderer = value;

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