Thursday, October 27, 2011

Keyboards

At one point during the development of PewPew, I wanted the players to be able to enter their name for the online high scores and replays. At first I started to use the native iOS keyboard,  and for a couple of months that's all there was.

But because I always wanted to have as few OS-specific code as possible to make the porting to different OS as simple as possible, I decided to implement my own keyboard.
It was going to be a lot of boring work though, so I kept postponing for later... And then, one day, I got in I saw this:

Extract from Gunnm, a fantastic manga.

I immediately wanted to have this keyboard in PewPew, and two days later it was done. And it looked great:
custom keyboard = seamless integration.


Besides the speed gain when porting to a new platform and the code simplification, there are many other advantages to having a custom keyboard. PewPew's font does not contain all the characters, so I can show only the characters that can be entered. Also, you can have custom colors in your nickname, and by having a custom keyboard I can make it very easy for the users to specify them:


Of course, there are disadvantages to using a custom keyboard: the users aren't used to the layout, they can't copy paste, the native keyboards are likely capable of detecting false key-presses, etc... but when you just want to enter your nickname, those things are not important.

Thursday, October 20, 2011

Asteroids

Quick post to say that I released an update for both PewPew and PewPew 2, that includes a new game mode called Asteroids.
It's of course an homage to the classic 1979 game, albeit PewPew style: lots of shooting, and lots of enemies.

A few notes: To keep the retro mood going on, the ship's color is forced to white. The asteroids' shape is generated at run time: it was faster for me to write code than to draw manually them :-) Added bonus: they have a unique shape every time. Final note: I resisted the urge of making the asteroids rotate, to stay closer to the original. A game developer's life is tough.

Unexpected Gotchas in Making a Game Deterministic

When aiming for a fully deterministic program, it is common knowledge that you have to deterministically seed your random number generators,...