Version 3.0.1 is out

Hi Citrus engineers!

We would like to thanks people for the nice welcoming made to the Citrus Engine!

We’ve received some pull requests (it’s always an awesome feeling!), bug report/fix and ideas of new features. The community is already growing, thank you very much!

This first revision include mostly fixed bugs, change some platformer objects behaviors, improve performances and prepare a new (huge) feature under the hood.

    This is the changelog :

  • fixed a bug on Nape’s Hero colliding with a Sensor.
  • fixed a bug where the Box2D Hero was able to double jump thanks to a Sensor or a Cloud.
  • fixed a bug where a passenger falls on a Moving Platform if it changes direction to downward.
  • optimizing States loops.
  • an Enemy doesn’t move anymore during the period it is hurt (don’t forget it is killed after this period).
  • Hero switches facing direction while in mid-air.
  • DistanceBetweenTwoPoints method added in MathUtils.
  • CitrusEngine’s handleAddedToStage method is now protected.
  • Adding auto setting of a component’s entity when adding to an entity, also added 2 utilites that search for a component by class type.
  • Frame Rate Independent Motion support added!

FRIM
You guessed it, the incoming new feature is the Frame Rate Independent Motion support. But what is it? At the moment, if you change the framerate of your swf, your game will be quicker or slower. The problem is if on some old devices you would like a fps equal to 30 and on newest devices a fps equal to 60, you will have to change all game objects velocity. The worst side is if you’ve targeted 60 fps, and on some part of your game there are so many objects that your fps fall to 30 fps, there will be huge gameplay differences!

The frim will ensure that we will always have the same object’s speed, it doesn’t matter the targeted swf fps! Take a look on this example. An other good side is that your graphics/art animations will keep the targeted fps speed! Also don’t forget that using Starling you can easily change the MovieClip’s animation speed.

Enable the FRIM
The frim isn’t enabled by default in this update because it isn’t 100% ready at the moment. However you can already test it : in your GameState class wich extends State or StarlingState classes, set up the frim to true. The default time step is 1/60.

public class GameState extends StarlingState {

	public function GameState() {

		super();

		_frim = true;
		_timeStep = 1 / 50; // means 50 FPS targeted on physics.
	}

	override public function initialize():void {
		super.initialize();

		// add physics and your objects
	}
}

Don’t hesitate to share your experience and advice with us on this feature!

Menu and HUD
On an other side, we’ve received several e-mails asking how a menu and a HUD should be setting up using the Citrus Engine. We are working on a tutorial that will show several ways using Flash Pro, Starling or even FeathersUI!

Again we will enjoy to hear your feedbacks, spread the word!

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>