Survive as long as possible against a never ending horde of randomly appearing zombies with nothing but your trusty pistol. Get more points for landing consecutive kills on zombies. Try to beat your own high score and comment below your personal best.


Controls: 

WSAD / Arrows - Move

Mouse - Aim

Mouse Click - Shoot


This game was made with GameMaker Studio 2 for the 100 Lines of Code Gamemaker Jam. Source code is downloadable below. Final count for lines of code is 96(last time i checked). Due only being able to use 100 lines of code, a lot of code has been spaghettified. The comments might help, but there are some lines that I myself look at and go, "What is going on here?" This is a prime example of terrible coding practice due to the code limit. 

One trick I abuse in this code is to turn an if statement(4 lines of code minimum) into an expression(1 line of code). Because GameMaker does not really have a boolean type(they are just 1 and 0), I multiply an expression by its desired output when true. So if(foo){bar=123} becomes bar = foo*123. This way, I can use as few if statements as possible.

Hope this helps you in making your own games.


Download

Download NowName your own price

Click download now to get access to the following files:

Survive Source.zip 550 kB

Comments

Log in with itch.io to leave a comment.

Fun game! The respawn positions felt a little unfair sometimes, though -- an enemy appeared right next to me and killed me before I got the chance to move. But it's good overall! Also, I really liked the sound effects and tweening of the score text. :)

I felt this way about spawning as well. But an if statement to check if the spawn was too close to the player would have sent my line count to just over 100. Really appreciate the feedback.

I just realized that my game is a bit similar to yours. Sorry? :D

21170. Nice! :D

(1 edit)

At first glance enemies look like Kratos from GOW, hehe. Also great trick with booleans.

(1 edit)

My personal best is 4350. Try and beat that!