ld40.git
5 years agoFix monster sprite master
MegaBrutal [Tue, 1 May 2018 03:55:55 +0000 (05:55 +0200)]
Fix monster sprite

Removed the ugly black square from the monster sprite which was
only there by mistake.

modified:   monster.png

6 years agoGame icon
MegaBrutal [Sat, 27 Jan 2018 12:00:00 +0000 (13:00 +0100)]
Game icon

Added game icon for OneGameAMonth.

new file:   determination_icon.png

6 years agoAdd particle effect for player death
MegaBrutal [Wed, 3 Jan 2018 13:40:00 +0000 (14:40 +0100)]
Add particle effect for player death

Added a simple particle effect to visualize how the player's soul
shatters upon death. The Game Over screen had to be delayed as the
player needs some time to see the particle effect.

modified:   ld40.js
new file:   soulbreak.png
new file:   soulbreak.svg

6 years agoAdd 'GameOver' game state
MegaBrutal [Tue, 2 Jan 2018 22:00:00 +0000 (23:00 +0100)]
Add 'GameOver' game state

Added a Game Over screen with the possibility to restart the game.

modified:   ld40.js

6 years agoAdd 'GamePlay' game state
MegaBrutal [Tue, 2 Jan 2018 19:05:00 +0000 (20:05 +0100)]
Add 'GamePlay' game state

This commit prepares the source code to use Phaser game states.
A default game state is already added. The main game functions
(preload, create, update) were moved into this game state.

This was necessary to add a Game Over state later.

modified:   ld40.js

6 years agoReuse same tween for monster shaking
MegaBrutal [Fri, 29 Dec 2017 23:25:00 +0000 (00:25 +0100)]
Reuse same tween for monster shaking

Now one tween is created and reused to shake a monster when it is
damaged. As a side-effect, the amplitude of shaking is now constant
while it was random in the previous commit.

I decided to use one tween for a monster to avoid creating a memory
leak by leaving unused tweens in memory.

modified:   ld40.js

6 years agoShake monsters when damaged
MegaBrutal [Fri, 29 Dec 2017 22:55:00 +0000 (23:55 +0100)]
Shake monsters when damaged

Monsters should give some feedback when they are damaged to let the
player know that shooting them has effect.

modified:   ld40.js

6 years agoFix healthbar not showing 0 when killed
MegaBrutal [Fri, 29 Dec 2017 19:15:00 +0000 (20:15 +0100)]
Fix healthbar not showing 0 when killed

When the player died, the healthbar showed some HP value which
confused some players (some of them didn't realize that they died).

modified:   ld40.js

6 years agoMerge branches 'cleaning' and 'balancing'
MegaBrutal [Thu, 28 Dec 2017 01:00:00 +0000 (02:00 +0100)]
Merge branches 'cleaning' and 'balancing'

modified:   ld40.js

6 years agoCleanup: Remove unused keyboard handler cleaning
MegaBrutal [Thu, 28 Dec 2017 00:45:00 +0000 (01:45 +0100)]
Cleanup: Remove unused keyboard handler

modified:   ld40.js

6 years agoRemove the first monster balancing
MegaBrutal [Thu, 28 Dec 2017 00:15:00 +0000 (01:15 +0100)]
Remove the first monster

Remove the very first monster that spawned in the game's create code
at a fixed location, as it intimidated some players. It's better to
let a few seconds for the player to accommodate with the movements
before the first monster spawns.

modified:   ld40.js

6 years agoCleanup: Monster also uses JusticeBlaster as a weapon
MegaBrutal [Wed, 27 Dec 2017 23:45:00 +0000 (00:45 +0100)]
Cleanup: Monster also uses JusticeBlaster as a weapon

To further simplify the code, the Monster class should also use
the JusticeBlaster weapon class as its weapon.

modified:   ld40.js

6 years agoCleanup: Use Phaser.Bullet & Phaser.Weapon
MegaBrutal [Wed, 27 Dec 2017 23:05:00 +0000 (00:05 +0100)]
Cleanup: Use Phaser.Bullet & Phaser.Weapon

I realized I reinvented the wheel by implementing my custom projectile
sprite derived from Phaser.Sprite. There are predefined classes in
Phaser.js just for this purpose. Now the player's weapon is derived
from Phaser classes.

modified:   ld40.js

6 years agoDone some balancing
MegaBrutal [Wed, 27 Dec 2017 10:35:00 +0000 (11:35 +0100)]
Done some balancing

– Player starts off with lower speed and gets faster in lower steps.
– Monsters spawn sooner depending on LV. With high enough LV, swarm of monsters may appear.

modified:   ld40.js

6 years agoInitial commit
MegaBrutal [Tue, 5 Dec 2017 22:40:00 +0000 (23:40 +0100)]
Initial commit

First version published at LD40.

new file:   determination.png
new file:   determination.svg
new file:   determination_shot1.png
new file:   determination_shot2.png
new file:   index.html
new file:   ld40.html
new file:   ld40.js
new file:   monster.png
new file:   projectile.png
new file:   projectile.svg
new file:   wall.png