ParticleSnow* ParticleSnow::createWithTotalParticles(unsigned int numberOfParticles) { ParticleSnow* pRet = new ParticleSnow(); if (pRet && pRet->initWithTotalParticles(numberOfParticles)) { pRet->autorelease(); } else { CC_SAFE_DELETE(pRet); } return pRet; }
ParticleSnow* ParticleSnow::createWithTotalParticles(int numberOfParticles) { ParticleSnow* ret = new (std::nothrow) ParticleSnow(); if (ret && ret->initWithTotalParticles(numberOfParticles)) { ret->autorelease(); } else { CC_SAFE_DELETE(ret); } return ret; }