void Start() { bounds = new Bounds(center, 2 * extend * DefaultVoxManager.getDefault().getRatio()); ps = GetComponent <ParticleSystem>(); switch (mode) { case ParticleSystemEmitMode.GRAVITY: impl = new ParticleSystemObjectGravityImpl(bounds, ps, heightRange, needTranslation); break; case ParticleSystemEmitMode.NORMAL: impl = new ParticleSystemObjectImpl(bounds, ps, heightRange, needTranslation); break; case ParticleSystemEmitMode.FIREWORK: impl = new ParticleSystemObjectFireworksImpl(bounds, ps, heightRange, needTranslation); break; case ParticleSystemEmitMode.CONTINUOUS: impl = new ParticleSystemObjectContinuousImpl(bounds, ps, heightRange, needTranslation); break; default: throw new NotImplementedException(); } }
// Use this for initialization void Start() { objectsWorld = DefaultVoxManager.getDefault().objectsWorld; fishvelocity = 5 * RandomWalkVelocity(objectsWorld, transform.position); MeshNormalObject self = GetComponent <MeshNormalObject>(); self.listener = this; }
void OnCollisionEnter(Collision col) { if (col.gameObject.name.Contains("Hand")) { DefaultVoxManager.getDefault().onBubble(col.gameObject.transform.position); suicide(); } }
void Awake() { UnityEngine.Debug.Log("Awake"); if (NeedRegister) { manager = this; } QualitySettings.vSyncCount = 0; Application.targetFrameRate = 20; initConfig(); initBounds(); ledseq = initLedSeq(); }
void Start() { bounds = new Bounds(center, 2 * extend * DefaultVoxManager.getDefault().getRatio()); pe = GetComponent <EllipsoidParticleEmitter>(); impl = new ParticleEmitObjectImpl(bounds, pe, heightRange); }