[Beta] Andengine Particle Editor and Loader

  ... the case you feel the need for a new feature or want to submit one.

[Beta] Andengine Particle Editor and Loader

Postby vichuics » Fri Sep 19, 2014 11:55 am

Hi Everyone,
Today, I want to contibute back to the community.
A month ago, I started to study about the particle system of Andengine. Although It is not difficult, it was very time consuming without a proper tools. I know libGDX has a good tools for it, so I try to translate the saved file from libGDX to Andengine but outcome is not good enough. Finally, I come up with the solution in this post.
screencap.png (32.45 KiB) Viewed 844 times

To Shorten everything:
AndEngineParticleEditor.zip the source code of the editor:
:evil: You will notices this is a libGDX Application. I have copy all Andengine Particle System related class and "MODIFIED" them to fit into libGDX Framework and result this WYSIWYG Andengine Particle System Editor :-
** I have not do any data format validation, invalidate input will be saved and only not show up the Particle System
- Eimtter: Life , Size, Shape, Texture
- Initializer : Velocity, Acceleration/Gravity, Rotation, Scale, Color, Alpha(tint)
- Modifier: Alpha, RGB(Andengine Color Modifier), HSV(My own Color Modifier),Rotation, Scale
- save - save all setting into a anp extension file (remember type ".anp" in the end)
- save packed: same as save but the texture name will replace to gfx/filename
- load: load a saved anp file

AndEngineParticleEditorExtension.zip the source coed of the editor:
Library use to load the file produce from the editor (FOR GLES2-AnchorCenter Only):
very simple to use, here is the example:-
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. ParticleLoader loader = new ParticleLoader (this.activity,this.engine);
  3. try {
  4.   ParticleEffect pEffect =loader.load("gfx/test2.anp");
  5.   //ParticleEffect pEffect =loader.load("gfx/test2.anp", new ITextureFactory(){....}) // or you can provide your own ITextureFactory
  6.   pEffect.setPosition(360, 640);
  7.   pEffect.setScale(1f);
  8.   attachChild(pEffect);
  9.   pEffect.start();
  10.   //pEffect.stop();
  11. } catch (IOException e) {
  12. // TODO Auto-generated catch block
  13. e.printStackTrace();
  14. }
Parsed in 0.011 seconds, using GeSHi

Thats All. Since I just quick develop it out (just few days), it still contains bugs. Feel to tell me :geek:
(641.5 KiB) Downloaded 180 times
(5.33 MiB) Downloaded 186 times
Posts: 1
Joined: Mon Apr 14, 2014 5:48 am

Return to Features

Who is online

Users browsing this forum: No registered users and 5 guests