Game Development Reference
In-Depth Information
How to do it...
Now, we can begin creating the muzzle flash emitter:
1. Navigate to the Emitters folder in the project and select New.../Empty jme3
Scene . We should now have a fresh scene.
2. Right-click on the main node in the SceneExplorer window and select Add Spa-
tial/Particle Emitter .
3. Select the emitter instance and open the Properties window.
4. Make sure the Shadow Mode option is Off and Queue Bucket is Transparent .
5. Then, select the muzzle flash material we created in the Geometry/Material sec-
tion.
6. Make the Emitter shape really small, for example, something like [Sphere,
0.0, 0.0, 0.0, 0.05] .
7. Num Particles should be 1 , and Particles Per Sec should be 0.0 .
8. Set Start Color to something like [1.0, 1.0, 0.4, 1.0] and End Color to
[1.0, 0.6, 0.2, 0.7] .
9. Both Start Size and End Size should be 1.0 .
10. High Life and Low Life should be 0.15 .
11. Gravity and Face Normal should be [0.0, 0.0, 0.0] .
12. Check the Facing Velocity box and set the Initial Velocity to [0.0, 0.0,
1.0] .
13. Images X and Images Y should reflect the number of frames in the texture we cre-
ated.
14. We can now test the emitter by clicking on the Emit! button.
All these values can be seen in the following screenshot:
Search WWH ::




Custom Search