Skip to content

mohsenheydari/three-fps

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Three FPS Demo

Three.js FPS game using ammo.js and three-pathfinding with ES6 and Webpack.

The project features an entity/component system, FPS controller using ammo.js rigidbody, NPC with root-motion animations and a basic AI.

Please note that the project is still under development.

Online Demo

Install

Before you begin, make sure you are comfortable with terminal commands and have Node and NPM installed. Then either install via a download or with Git.

Install via Download

First download the zip of the project and extract it. Then in terminal at that folder type npm install to set things up. To get going run: npm start.

Install with Git

In terminal clone the project into a directory of your choice then delete the git folder to start fresh.

git clone --depth=1 https://github.com/mohsenheydari/three-fps.git three-fps
cd three-fps
rm -rf .git
npm install

Running the development server

To see the changes you make to the project go to the project's folder in terminal and type...

npm start

This command will bundle the project code and start a development server at http://localhost:8080/. Visit this in your web browser.

Editing the code

The first file you should open is ./src/entry.js. In it you will find the main application class. This class is reponsible for initializing the libraries and loading art assets, it also handles the main game loop.

Building the project for the web

Running npm run build in terminal will bundle your project into the folder ./build/. You can upload this directory to a web server. For more complex results read this guide.

About the models

Art assets used in this project:

Thanks to

License

MIT

Releases

No releases published

Packages

No packages published