Friday, 22 January 2010

Engine3.16 released

Bugs fixed in this release
==========================
EngineManager010 - killed sprites now removed from bins properly upon removal.

EngineManager011 - hopefully fixed the SpriteBatch.End() crash that is occuring when you drag window between screens. I don't seem to be able to re-create it anymore on my teacher desk machine. Need some people to test it. After testing with Patrick's code I've tracked down the culprit but not the reason, I have a fix that should stop it crashing in future, but I need to look at the reason it actually occurs.

EventManager005 - Events repeatedly raised using RaisedUntil() now re-initialise

Changes in this release
=======================
EngineManager
-------------
cleanup - Draw(), cleaned some of the code to reduce number of new objects created during draw cycle


Limit
-----
added - turnOffGravityBottomOnly, this turns gravity off only when you hit the bottom of a limit box all other edges are ignored.

added - killPastXStopY, kills a sprite if it goes past the left/right boundaries and stops sprites vertical movement if it touches top/bottom

added - killPastYStopX, kills a sprite if it goes past top/bottom boundaries and stops sprites horizontal movement if it touches left/right


Timing (TimerActions)
------

added - OnTimingDone(), lets you set an internal sprite event, which automatically runs an Update subroutine when the timer elapses

TimingDone can be called at the end of

ShowAfter(), ShowAfterFlash(), StopAfter(), ImpulseStopAfter(), FlashAfter(), ShowAfterKillAfter(), once sprite is shown, StartAfterStopAfter() (called when it starts and again when it stops use GetPhase to determine which state its in), FlashAfterKillAfter() (once flashing starts)

For instance, you may want the player to be invicible to start with and indicate with flashing, Using StopAfter() to flash the sprite for a while (set sprite CollisionDisable() when you create the sprite). Set the OnTimingDone which will be called when the flashing stops, to turn on CollisionEnable() the sprite.

added - RemoveOnTiming(), lets you remove the update handler associated with timer actions

added - FireEvent(), lets you specify an update handler that runs repeatidly after a certain amount of time

added - FireEventOnce(), lets you specify an update handler that runs once after a certain amount of time

adjusted - Timing updates to take account of partial time overlaps, this should make the timer actions more regular

Monday, 4 January 2010

Engine3.15 released

This is the last release before I updated the collision engine, I will try to make it work with the same setup of CollisionChecks, but this may not be possible. I am currently developing a two player asteroids game and this has given me a chance to bug fix a tweak many aspects of the engine, including adding useful functions.


Bugs fixed in this release
==========================



Changes in this release
=======================

Sprite
------

added - Position2D, this returns the position of the sprite as a 2D result (ignoring the Z value), this is useful for distance calculations.

SpriteHelper
------------

added - RotateFacingPosition(), this lets you make a sprite face a given position (for perfect tracking systems)

added - VelocityToGetHereInThisTime(), this let's you easily specify a position to move towards in a certain specified time


Timing (TimerActions)
------

added - OnTimingDone(), lets you specify a sprite update routine to call when timing finishes for actions that don't involve Kill (you could use a funeral for these).

TimingDone can be called at the end of

ShowAfter(), ShowAfterFlash(), StopAfter(), ImpulseStopAfter(), FlashAfter(), ShowAfterKillAfter(), once sprite is shown, StartAfterStopAfter() (called when it starts and again when it stops use GetPhase to determine which state its in), FlashAfterKillAfter() (once flashing starts)

For instance, you may want the player to be invicible to start with and indicate with flashing, Using StopAfter() to flash the sprite for a while (set sprite CollisionDisable() when you create the sprite). Set the OnTimingDone which will be called when the flashing stops, to turn on CollisionEnable() the sprite.

added - RemoveOnTimingDone(), removes any specified TimingDone handler

added - GetPhase, this gives you the phase of multipart actions such as StartAfterStopAfter()