Tag Info

New answers tagged

0

To make a particle track your finger motion you first need to track at least two different events in onTouchEvent(), and possibly a third depending on what you want to happen when you lift your finger. You need to check for MotionEvent.ACTION_DOWN and MotionEvent.ACTION_MOVE, and possibly MotionEvent.ACTION_UP. The first event you will set the initial ...


1

I would recommend an animated Projector. You'd simply configure the IgnoreLayers property to ignore your player. And you could animate the effect with a simple script to modify the UV offsets of the material you use. One thing to remember is for every object a projector is projected onto an extra draw call is issued (just like a light), so use them ...


0

you have to create an array of pooled effects Array<PooledEffect> effects = new Array<PooledEffect>(); so, in render(), you draw all effects from array. for(int i = 0; i < blocos.size();i++){ if(obj.colision(block.get(i),config)) { PooledEffect effect = block.get(i).getEffectPool().obtain(); ...


1

When you call effect.setPosition(...), it changes the position of all the emitters, but not of the particles. In libGDX, there is currently no way of changing the position of a single particle, so in order to draw particles at 2 locations, you must do the following: // Pseudo-code move effect at position 1 add particles move effect at position 2 add ...


1

It might be related to your Update function: function Update() { if (triggered && Input.GetKeyDown(KeyCode.JoystickButton1)) particle1.SetActive(true); particle2.SetActive(true); particle3.SetActive(true); } Having no brackets, only particle1.setActive(true) is in the condition. The other two will be called on each ...



Top 50 recent answers are included