Point & Shoot Games (JavaScript tutorial) @Frankslaboratory
Point & Shoot Games (JavaScript tutorial)  @Frankslaboratory
Uploaded January 2024 | Updated November 2026, 17 hours ago
Every mobile game needs to have 3 main elements: fullscreen, touch controls & optimized code, that runs well on a variety of devices. We will do all of that, and we will 1) build a BLANK REUSABLE BOILERPLATE project and 2) in the advanced section we will add graphics, animation & sounds to turn it into an ANIMATED SPACE HORROR game. Scary noises included.

OBJECT POOL DESIGN PATTERN allows us to reuse objects, rather than constantly creating new ones and destroying the old ones. This approach will improve the performance of the codebase, because it solves problems with automatic memory allocation and garbage collection processes.

STATE DESIGN PATTERN allows us to separate behaviors of the object into separate code blocks, giving us the ultimate control over each individual state, while at the same time making the code easier to read, maintain and debug.

Let's learn how to implement both of these design patterns in a real project using JavaScript & HTML Canvas.

๐Ÿ‘ฝ Download Project Art assets ๐Ÿ‘ฝ
Background horizontal: frankslaboratory.co.uk/downloads/136/background1920x1080.png
Background vertical: frankslaboratory.co.uk/downloads/136/background1080x1920.png
Simple crew member: frankslaboratory.co.uk/downloads/136/crew.png
Beetlemorph 100x100px frames: frankslaboratory.co.uk/downloads/136/beetlemorph100x100.png
Lobstermorph 100x100px frames: frankslaboratory.co.uk/downloads/136/lobstermorph100x100.png
Crew members sprite sheet: frankslaboratory.co.uk/downloads/136/crewSprite.png
Phantommorph 100x100px frames: frankslaboratory.co.uk/downloads/136/phantommorph100x100.png

Sounds (right click and 'Save link as'):
New game: frankslaboratory.co.uk/downloads/136/newgame.mp3
Boom 1: frankslaboratory.co.uk/downloads/136/boom1.mp3
Slide: frankslaboratory.co.uk/downloads/136/slide.mp3
Boom 2: frankslaboratory.co.uk/downloads/136/boom2.mp3
Boom 3: frankslaboratory.co.uk/downloads/136/boom3.mp3
Boom 4: frankslaboratory.co.uk/downloads/136/boom4.mp3
Win: frankslaboratory.co.uk/downloads/136/win.mp3
Lose: frankslaboratory.co.uk/downloads/136/lose.mp3
Scream: frankslaboratory.co.uk/downloads/136/scream.mp3

(if you can't download the files, try to use a different browser or VPN to change your country, also leave a comment so I can fix it)

Playlist: youtube.com/playlist?list=PLYElE_rzEw_tw6scwjv96oEABmnMSQoQW

๐ŸŒŒ Tutorial Contents ๐ŸŒŒ
Beginner project:
00:00:00 Build mobile games JavaScript and HTML Canvas.
00:01:08 Project setup
00:03:05 Make everything responsive
00:09:20 Enemy class
00:17:19 Object pool design pattern
00:20:55 Periodic triggers
00:27:45 Mouse controls
00:29:15 Collision detection
00:37:05 Touch events
00:38:43 Game text
00:45:46 Start & restart
00:49:21 Fullscreen games

Advanced project:
00:53:29 Simple crew members
00:54:59 Simple enemy type
00:59:23 Sprite animation
01:03:44 Animation timing
01:07:52 Debug mode
01:10:01 Enemy variety
01:14:31 Randomized space crew
01:18:18 State management in games
01:22:46 State design pattern
01:38:10 Sounds and final details

Source code:
Checkpoint 1 (00:16:21): frankslaboratory.co.uk/downloads/136/source_code_1.zip
Checkpoint 2 (00:52:46): frankslaboratory.co.uk/downloads/136/source_code_2.zip

If you want to SUPPORT me you can use the links below and get some one my EXTENDED classes! :)
udemy.com/course/learn-creative-coding-with-vanilla-javascript/?referralCode=7C560D4661C5C59262BB
udemy.com/course/learn-game-development-with-javascript/?referralCode=69874A38D543D7F510F2
udemy.com/course/creative-coding-deep-dive-for-beginners/?referralCode=F43E8FCE60957A64DF4A
udemy.com/course/build-animated-physics-game-with-javascript/?referralCode=B4482AF631243104650B
udemy.com/course/learn-html-canvas-pixels-particles-physics/?referralCode=F7977062A4BC964A1F5E
udemy.com/course/remake-retro-games-with-javascript/?referralCode=2ACCA21F16FE78E631F7
udemy.com/course/learn-html-canvas-advanced-text-effects/?referralCode=4C5821D2D04048CC4A01

Get Skillshare FREE for 1 month:
skillshare.com/en/r/profile/Frank-Dvorak/507488567?gr_tch_ref=on&gr_trp=on

The description of this video may contain affiliate links, which means that if you buy one of the products that I recommend, I'll receive a small commission without any additional cost for you. This helps to support the channel and allows me to continue making videos like this. Thank you for the support!
#frankslaboratory
Point & Shoot Games (JavaScript tutorial)JavaScript Side Scroller Game TutorialJavaScript Game Tutorial: Planet DefenseFree Tool Makes ANY Indie Game CharacterWhy Hardcoding Kills Scale (Go Data-Driven)Pure CSS Animated Background Tutorial - Dripping Liquid EffectPerfect Pixel Art in Seconds (CSS)Pure CSS Morph Effect | Awesome UI Hover Animations with CSS Clip Path PropertySprite Animation in JavaScriptMake a Mobile Game with JavaScriptBuild a Swarm With One UpgradeHTML Canvas Deep Dive 2026
Franks laboratory |

Point & Shoot Games (JavaScript tutorial)

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER