Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

freeCodeCamp

JavaScript Game Development with Kaplay Library - From Basics to Advanced Features

via freeCodeCamp

Overview

Master JavaScript game development fundamentals and the Kaplay library in this comprehensive 4-hour course designed for aspiring game developers. Begin with essential JavaScript concepts including variables, conditional statements, data types, loops, functions, and scoping before diving into practical game development. Set up a modern development environment using Node.js, NPM, and Vite to create and export games to platforms like itch.io. Progress to exploring the Kaplay library's features including asset loading, scene management, game objects, component systems (sprite, area, body, text), collision handling, user input management, and advanced concepts like tweening, game maps, state machine AI, and custom events. Access additional resources through provided documentation links and join the Kaplay community through Discord for continued learning and support.

Syllabus

Intro
Why learn JS to make games?
Environment Setup
Core concept #1 : variable and constants
Core concept #2 : conditional statements and boolean operations
Core concept #3 : complex data types Arrays and objects
Core concept #4 : loops
Core concept #5 : functions + param passing by reference vs by value
Core concept #6 : local vs global scoping
Core concept #7 : comments + how import/export js code works
What is a library?
Setting a modern dev environment with Node.js, NPM and Vite
Making our first JS game
How to export your JS game to a platform like itch.io
Next steps useful resources
Intro - What is Kaplay
How to install Kaplay
How to deploy/publish a game made with Kaplay
How to initialize the Kaplay
How to load assets in Kaplay
How scenes work in Kaplay
How game objects work in Kaplay
Child vs parent game objects
Kaplay major components : the sprite component
Kaplay major components : the area component
Kaplay major components : the body component
Kaplay major components : the text component
Introducing tags and get method
use and unuse methods to add/remove components
Handling collisions with onCollide and onCollideEnd
Handling use input with onKeyDown, onKeyPress and onKeyRelease
Advanced features : tween function
Advanced features : Briefly introducing how game maps are made in Kaplay
Advanced features : Briefly introducing how AI made with state machines
Advanced features : Briefly introducing custom events in Kaplay

Taught by

freeCodeCamp.org

Reviews

Start your review of JavaScript Game Development with Kaplay Library - From Basics to Advanced Features

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.