Example #1
0
    public void SetEffectParticle(Object _BaseObj, float _ImageSize)
    {
        ReleaseParticleList();
        if (m_objParticleList == null)
        {
            m_objParticleList = new List <GameObject>(DefineBaseManager.inst.EffectParticleMax);
        }
        if (m_renParticleList == null)
        {
            m_renParticleList = new List <ControlMesh>(DefineBaseManager.inst.EffectParticleMax);
        }

        for (int i = 0; i < DefineBaseManager.inst.EffectParticleMax; i++)
        {
            m_objParticleList.Add((GameObject)Instantiate(_BaseObj));
            m_objParticleList[i].name  = "EffectParticle_" + i;
            m_objParticleList[i].layer = m_LayerMask;

            m_objParticleList[i].transform.parent = this.transform;

//			m_renParticleList.Add(m_objParticleList[i].AddComponent<ControlMesh>());
            ControlMesh tmpControlMesh = new ControlMesh();
            tmpControlMesh.Create(m_objParticleList[i]);
            tmpControlMesh.Anchor = SpriteRoot.ANCHOR_METHOD.MIDDLE_CENTER;
            tmpControlMesh.SetSize(_ImageSize, _ImageSize);
            m_renParticleList.Add(tmpControlMesh);
        }
    }
Example #2
0
    public void SetKittyObject()
    {
        SetTmpEffectZero();
        gameObject.layer = m_LayerMask;

//		m_renBackground	= gameObject.AddComponent<ControlMesh>();
        m_renBackground = new ControlMesh();
        m_renBackground.Create(gameObject);
        m_renBackground.Anchor = SpriteRoot.ANCHOR_METHOD.MIDDLE_CENTER;
        m_renBackground.SetSize(DefineBaseManager.inst.KittyGap + 0.5f, DefineBaseManager.inst.KittyGap + 0.5f);
    }
Example #3
0
    public void SetEffectTurnBack(Object _BaseObj)
    {
        ReleaseTurnBack();

        m_objTurnBack       = (GameObject)Instantiate(_BaseObj);
        m_objTurnBack.name  = "EffectTurnBack";
        m_objTurnBack.layer = m_LayerMask;

        m_objTurnBack.transform.parent        = this.transform;
        m_objTurnBack.transform.localPosition = m_posTurnBack;
        m_objTurnBack.transform.eulerAngles   = Vector3.zero;
        SetTmpEffectZero();
        m_objTurnBack.transform.localScale = m_vecTmp;

//		m_renTurnBack	= m_objTurnBack.AddComponent<ControlMesh>();
        m_renTurnBack = new ControlMesh();
        m_renTurnBack.Create(m_objTurnBack);
        m_renTurnBack.Anchor = SpriteRoot.ANCHOR_METHOD.MIDDLE_CENTER;
        m_renTurnBack.SetSize(DefineBaseManager.inst.KittyGap, DefineBaseManager.inst.KittyGap);
    }
Example #4
0
 protected void SetResources()
 {
     m_imgLoading.Anchor = SpriteRoot.ANCHOR_METHOD.MIDDLE_CENTER;
     m_imgLoading.SetSize(m_imgLoading.spriteMesh.texture.width, m_imgLoading.spriteMesh.texture.height);
     m_imgLoading.gameObject.layer = LayerMask.NameToLayer("GUI");
 }