Skip to content

A concurrent multiplayer platformer for CS 21, by Team Joyce.

Notifications You must be signed in to change notification settings

rebecca-millerr/cs21-platformer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

# cs21-platformer
A concurrent multiplayer platformer for CS 21, by Team Joyce.

Code Overview

cs21-platformer
|____backend
      |____.erlang.mk/    internal erlang info
      |____config/        config and cookie info
      |____deps/          erlang dependencies
      |____src
            |____backend_app.erl    main server app spawning processes      
            |____backend_sup.erl    background supervisor
            |____broadcaster.erl    loops, broadcasting to clients
            |____canvas_state.erl   loops, handling block placements
            |____platformer_handler.erl    handles websocket and json parsing
            |____tick_counter.erl    tracks and reports elapsed ticks
      |____backend.d       automatically generated by erlang makefile
      |____erlang.mk       erlang makefile boilerplate
      |____Makefile        erlang makefile config
      |____relx.config     general config
|____web
      |____.next/             next.js boilerplate
      |____node_modules/      code for packages and dependencies
      |____public             public html to inject react into
      |____src
            |____components/Game
			  |____Runner
			        |____ActiveRunner.jsx      manages general behavior of
                                               active runner
			        |____controlled-runner.js  handles key presses and movement
                                               of runners
			        |____index.js              runner exports
			        |____sprite.js             render sprite with animations 
			  |____constants.js		stores constants for canvas
			  |____Game.jsx			renders scrolling canvas
			  |____Game.module.css     css for game
			  |____Ground.jsx          sets ground on map
			  |____index.js            handles game exports
			  |____LevelEditor.jsx     handles builders’ blocks
			  |____renderer.js         renders bodies onto canvas
            |____pages
			  |____ _app.jsx		     main app container
			  |____game.jsx		         game-playing page
			  |____index.jsx		     lobby page
			  |____index.module.scss     css for lobby
            |____styles
			  |____global.scss		css for general app
			  |____reset.scss		css to clear browser defaults
            |____store.js
      |____.babelrc           babel config
      |____.eslintrc.json     eslint config
      |____.gitignore         what git should ignore
      |____jsconfig.json      javascript config
      |____next.config.js     next.js config
      |____package-lock.json  locks dependency versions
      |____package.json       dependency versions and project metadata
|____.gitignore        what git should ignore
|____.prettierrc       prettier formatter config
|____README.md         README info about project

Running the Project 

Start the server
(If you own a PC, skip to step 3; if you own a Mac, start at step 1)

1. brew install make
2. Add the line in ~/.zshrc: alias make=‘gmake’
3. cd backend
4. make run

Start the client

1. cd web
2. npm i
3. npm run dev

You can view the game at http://localhost:3000.

About

A concurrent multiplayer platformer for CS 21, by Team Joyce.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •