Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
(1 edit)

So (of course) I didn't actually develop the stuff on the list from the last post.

Well, I did do the health pickups (and they paved the road for further pickups).

Instead I did these things:

Muzzle flashes, they were needed because if the enemy is right next to you you never see the projectile fly.

This way there is visual feedback for the attack in all cases.

The muzzle flash is part of the shooting animation (in spriter). The interesting part was to make it fit with the big gun and the small gun.

The gun change is done via character maps (where you can replace one of the animation's sprites with another picture).

Since the size of the guns isn't the same the muzzle flash wasn't appearing at the correct position.

Solution: Also switch the picture for the muzzle flash when switching the gun picture. (Both muzzle flashes are the same size picture, but in one there is lot's of space left to the flash, in the other to the right - this changes the position in the animation to fit the gun size.)

Another thing I experimented with is ninePatch in libgdx.

For this message box:

The background of the box including the round edges is a ninePatch image. This way there is no blurring even when resizing it.

(And it is resized in this picture, because no one wants such a big box in their spritesheet.)

Original 9patch:

Notice how the edges are the same and only the repeatable part gets stretched out.

And this requires you to quickly mark the strechable parts with the android's sdk 9patch editor - and exactly one line of code with libgdx:

ninePatch = textureAtlas.createPatch(name)

So then.. maybe I do the weapon pickups tomorrow :)