July 1, 2016 at 8:18 pm #1581
As this starts to work better and better, I decided to also share my 2d game framework on Github: https://github.com/mutatedmonkey/game2d
I have a few features in already, and as I am finishing up my Asteroids clone (which starts to behave brilliantly) I will add more and more to this framework. First demo game should be up on this repository by tomorrow as well.
Here’s the read me and feature list.Monkey12345678910111213141516171819202122232425262728293031323334353637383940AboutGame2D is a 2d game engine for Monkey2, featuring states, entities, and much more. Functionality will expand while games get written. It is not yet known what the full feature set of this engine will be but there are planned and considered features on the bottom of this page.Copy the repository content into a folder called 'game2d' in the Monkey2/modules/ folder. Run Monkey2/bin/mx2cc_linux makemods -clean -target=desktop game2dThe module compiles and you should be able to use it from now on by adding #Import "< game2d >" to your main project file.An example game will be added shortly (Asteroids, of course!)Current FeaturesEngine:Windows and Linux compatibleeasy setup, run and shutdownfixed time steppause modestates and transitionspre/post update/render callsgame options and config menuInput:key control devicereconfigure config menuGraphics:render tweeningvirtual resolution, aspect ratiosrender layersGame Entities:entity manager (render layers, entity groups)image entitySound:tbd, in progressPlanned features:better sound controlgamepad supporttext entitiesinterpolated values for use with sound, entities, color, etc. ( in progress )July 3, 2016 at 9:00 am #1634
I have added an example Asteroids game to github to show how this is used. Also added sound playback etc to the framework…July 5, 2016 at 5:02 am #1739
Nearly missed it – will check it out Wiebo!July 5, 2016 at 6:25 pm #1762
OK Matthew, let me know what you think. I’m a bit offline these days (working on installing a new kitchen) but should be back next week.July 10, 2016 at 8:17 pm #1992
OK, kitchen is working, so I’m back… I have added docs to most classes now, and have also added the first issues/enhancements to the github page. If you have any requests or new features you would like to see, let me know.July 11, 2016 at 12:34 am #2015
Had a quick play yesterday – going to start adding into some stuff i’m playing with. Looks nice mate!July 11, 2016 at 11:31 am #2046
Hi Matthew. Thanks! Let me know which functionality you miss.
I’m going to move the Asteroids example game into the main repository for the module.July 11, 2016 at 12:21 pm #2049
Will do – having a play now!July 13, 2016 at 10:14 pm #2105
Entity pooling would be a nice feature.July 14, 2016 at 6:38 am #2122
@sammy: Indeed. I am concentrating on the more essential stuff for now though: audio, gamepad input, configuration stuff.
But for particles etc pooling of some kind would be nice to have.July 17, 2016 at 6:54 pm #2233
I just pushed a change that allows the use gamepads. Xbox360, PS3 and 4 supported. Code is kinda messy, but I’m sure I’ll return to it when I know more of Monkey2’s new language features to make stuff more clean.
EDIT: yesterday evening I realised I forgot to add Hats, and I thought of a better way to support these and other controls, so I’ll give that a go later today.
Attachments:August 3, 2016 at 1:59 am #2689
Just wanted to add I’ve been using Wiebo’s framework for the past couple of weeks which has made the backend gaming stuff easy to setup and manage. I’ve taken some of Wiebo’s Asteroids example (thanks! 🙂 ) and created a customized Vector entity using some code I’ve had sitting there for ages – not sure where from) which I’ve used for the ship, asteroids, bullets etc and customised the particle engine (up on the forum and in the bananas folder) and vector font (originally from Mark Incitti in BlitzMax) for the rest. Pics attached but as with vector games, it looks better on-screen than in image!
Asteroids has been probably my favorite game to make over the years – having played it heaps on the Atari 2600 originally. Over the years I’ve tried building it in Garry Kitchens GameMaker on the c64, Amos on the Amiga, Blitz 2d and now in Monkey2!
The base game is done (minus the UFO – todo!) with all the gfx (with nice little flickering effect) and sound effects done (including the thump thump!) but i’m going to add some powerups (such has faster turn, speed, extra bullets, maybe bombs etc) to spice it up a little. I’ve already added current level and remaining asteroids (ahla Wizball).
Overall Wiebo’s Game2d Framework has taken out the boring stuff such as states (screens, playfields) and object management (images, sounds) etc and allowed me to concentrate on the game itself (the reason we uses such frameworks!). Even has some built-in management for configuring keyboards and joysticks.
Attachments:August 3, 2016 at 2:42 am #2692
Now we just need shaders and make it look like a CRT monitor 😉August 3, 2016 at 3:14 am #2693
Yes! Even adding the flickering adds a bit.August 3, 2016 at 8:13 am #2702
Matthew, that looks great!! 🙂 When can I play it?
Glad you like the little framework I’m working on! Expanding it as we program on 🙂
You must be logged in to reply to this topic.