HOME | DD

Published: 2013-04-21 06:05:25 +0000 UTC; Views: 429; Favourites: 3; Downloads: 1
Redirect to original
Description
Hey look! I've broken ground in Flash development!I wanted to learn Haxe NME, (a language very similar to ActionScript 3, the Flash programming language,) so I decided to port a game I made a few years ago as part of a tutorial on the C++ graphics library Allegro 5. I made a few changes to the game logic, (I added some acceleration to the player movement, as well as some trigonometry to keep you from moving faster on the diagonals than on the vertical or horizontal. Also, some changes were made to the scoring system.) as well as a few cosmetic additions, (the screen shaking, the red flash, the stars,) but beyond that most everything here should be credited to the guy who made that tutorial, because all of the numbers and calculations are the same even if it's written in another language.
A selection of the trials and tribulations encountered during the creation of this SWF:
- For the longest damn time I couldn't even get the ship to show up on the screen. I had to spend an entire day reading about the Flash rendering pipeline before any headway could be made.
- Another whole day (maybe two) was spent trying to get the player object to register key presses. Until I figured that out, it was impossible to move.
- There were more null reference errors than I can count regarding the removal of objects from the screen.
- Shifting from one game state to another (e.g. from the in-game screen to the game over screen) yielded a lot of interesting errors. I became very well acquainted with the Flash event system trying to figure them out.
So it took about a week and a lot of headaches, but I think I know enough Haxe to get by now. Maybe the next game will be a) my own idea and b) a little more presentable, yeah?
Also, incidentally, this is the first thing I've uploaded since dA rolled out the new submission form layout. Can't say I'm a huge fan of it, but I guess I'll adapt.
Related content
Comments: 4
cogs10 [2013-04-22 12:25:30 +0000 UTC]
i like it. the ship moves too slow for me, and the shaking screen is distracting. it's fun, and i'm sure you'll improve it as time goes by. it's great that you're learning, and it seems like you know a lot already. i'll go play it again, lol.
👍: 0 ⏩: 1
Randomonium09 In reply to cogs10 [2013-04-22 23:51:42 +0000 UTC]
Thank you.
The screen shaking was born out of a need to signal that an asteroid had been missed, but that the player hadn't lost a life. It needed to be clear but unambiguously different from the "you-just-lost-a-life" red flash, and a shaking screen was the first thing that came to mind, but I can see how it might be distracting. Do you think it would be less distracting if it were less intense or lasted a shorter time? Or do you think there's a better way to signal that the player's score has gone down?
As for the movement speed, I can easily modify by just changing a number. I might play around with it some.
👍: 0 ⏩: 1
cogs10 In reply to Randomonium09 [2013-04-23 18:48:26 +0000 UTC]
thanks. i thought you'd be able to change the speed pretty easily (isn't it faster now? i didn't notice being slow). i knew when i was missing asteroids,so i didn't mind an extra reminder. i love how you did the flash and shake upon contact with asteroid. ok, maybe you could blink the score 3 times at missing an asteroid. also, the score could be on the right for me, since i'm looking that way. i love the moving stars. great job, and it's not a crappy game, so i'd remove that, lol.
👍: 0 ⏩: 0