Beispiel #1
0
    ///找到某个FightObject的提示
    public EdgeHint findEdgeHint(FightEntity fightObject)
    {
        int i, len;

        len = edgeHintList.Count;
        for (i = 0; i < len; i++)
        {
            EdgeHint edgeHint = edgeHintList [i];
            if (fightObject == edgeHint.fightEntity)
            {
                return(edgeHint);
            }
        }
        return(null);
    }
Beispiel #2
0
    /// 增加对一个物体的边缘提示
    public void addFightObject(int index, FightEntity fightEntity)
    {
        GameObject go = this.getEdgeHintGameObject(index);

        go.SetActive(false);
        go.transform.SetParent(this.gameObject.transform, false);

        EdgeHint edgeHint = go.GetComponent <EdgeHint> ();

        //edgeHint.name = prefabs[index].name +" "+fightEntity.view.name;
        edgeHint.init(fightEntity);
        if (index == INDEX_RADISH)
        {
            radishEdgeHint = edgeHint;
        }
        edgeHintList.Add(edgeHint);
//		ViewUtils.setGameObjectScale (go, 12f);
    }
Beispiel #3
0
    /// 萝卜提示切换状态
    //public void changeRadishEdgeHint(int team) {
    //    if(null != radishEdgeHint) {
    //        radishEdgeHint.changeRadishEdgeHint(team);
    //    }
    //}

    public void clear()
    {
        radishEdgeHint = null;
        edgeHintList.Clear();
        ViewUtils.clearChildren(this.transform);
    }