/** creates an initializes a CCParticleSystemQuad from a plist file.
 This plist files can be creted manually or with Particle Designer:  
 */
 public static CCParticleSystemQuad particleWithFile(string plistFile)
 {
     CCParticleSystemQuad pRet = new CCParticleSystemQuad();
     if (pRet != null && pRet.initWithFile(plistFile))
     {
         return pRet;
     }
     return pRet;
 }
Ejemplo n.º 2
0
        /** creates an initializes a CCParticleSystemQuad from a plist file.
         * This plist files can be creted manually or with Particle Designer:
         */
        public static CCParticleSystemQuad particleWithFile(string plistFile)
        {
            CCParticleSystemQuad pRet = new CCParticleSystemQuad();

            if (pRet != null && pRet.initWithFile(plistFile))
            {
                return(pRet);
            }
            return(pRet);
        }
Ejemplo n.º 3
0
        public static CCParticleSystemQuad particleWithFile(string plistFile)
        {
            CCParticleSystemQuad quad = new CCParticleSystemQuad();

            if ((quad != null) && quad.initWithFile(plistFile))
            {
                return(quad);
            }
            return(quad);
        }
Ejemplo n.º 4
0
        public override void onEnter()
        {
            base.onEnter();

            Color = new ccColor3B(0,0,0);
            removeChild(m_background, true);
            m_background = null;

            CCParticleSystemQuad system = new CCParticleSystemQuad();
            system.initWithFile("Images/SpinningPeasPlist");
            system.setTextureWithRect(CCTextureCache.sharedTextureCache().addImage("Images/particles"), new CCRect(0,0,32,32));
            addChild(system, 10);
            m_emitter = system;

            m_nIndex = 0;
            schedule(updateQuads, 2.0f);
        }
Ejemplo n.º 5
0
        public override void onEnter()
        {
            base.onEnter();

            Color = new ccColor3B(0, 0, 0);
            removeChild(m_background, true);
            m_background = null;

            m_emitter = new CCParticleSystemQuad();
            // string filename = "Images/" + m_title + ".plist";
            string filename = "Images/" + m_title;
            m_emitter.initWithFile(filename);
            addChild(m_emitter, 10);

            m_emitter.IsBlendAdditive = true;

            setEmitterPosition();
        }