Repository files navigation 2DJS - 2d Javascript engine
2d JS engine via the HTML Canvas API
basic grid map generation via 2d array
grid row/column units based on length or height of map (grid)
for loop tracks 0 (space) or 1 (wall) in map array
if 1, pushes a new instance of square geometry to the wall array with its coords
delta time animation
fixed (target) fps rate
classes for different geometries:
collision detection
wallCheck(); function (checks for walls)
checks via coordinates being equal or not
checks for player coords + player radius (player is a circle
mouse movement tracking
dynamic ray from player to mouse
basic player as a blue circle
triangle class
player direction
scrolling background
CLEAN UP CODE/OPTIMIZE
sprites
different wall types
projectiles
enemies
CLEAN UP CODE/OPTOMIZE
health system
items/item pickups
inventory system
map editor
different wall types
enemy spawns
light levels
item pickums
player spawn
port game to differnt languages/systems (besides browser)
Python via Python Turtle/Pygame
C++ via openGL or SDL3
mac
linux
physics engine to expand graphics engine beyond top-down
gravity
velocity
more advanced collision between objects/environment
About
Two dimensional javascript graphics engine via HTML canvas API. No physics yet, but can be implimented. *may be a seperate engine*
Resources
Stars
Watchers
Forks
You can’t perform that action at this time.