BIP Upgrades

>> Saturday, May 1, 2010

Well I've worked a bit more on BIP, the Input class now read a sequence of keys with a given delay, useful to check for actions if you are makign for example a fight game.
Also the Sprite class has been modified, the way to load spritesheets has changed, now it loads spritesheets with no requirement of it to have the same size for all images, it reads spritesheets generated by this program (which i reccommend by the way).
Another thing that changed from the Sprites class is the way to add animations, now, when you pack the spritesheet each image has it name you can use to add animations, for example say you have the images

  • wk_punch_1.png
  • wk_punch_2.png
  • wk_punch_3.png
  • wk_punch_4.png
You could add an animation by doing this

addAnimation("wk_punch", new String[]{ "wk_punch_1", "wk_punch_2", "wk_punch_3", "wk_punch_4" });

Way easier IMHO.
Also I fixed some bugs with Mouse Input and finished a little Button class, inside the gui subpackage. In the future I think it will have some more basic gui components, nothing fancy, I'll see how hard it is to give a simple interface to use swing or awt, BIP is all about simple interfaces :)

Post a Comment

  © Blogger template Simple n' Sweet by 2009

Back to TOP