This is an accessible flight simulation experience that uses a smartphone accelerometer to control the plane. This allows users who don't have an expensive controller/joystick to have a taste for what its like to fly a plane.
This was a JavaScript project made this using React, Three.js, Node.js, and Socket.io, among other smaller libraries.
The goal of this project was to demo an immersive flight simulator that is accessible for nearly anyone to try without any fancy controllers. Personally, I enjoy the idea of creating a fun experience that anyone can enjoy, and this demo shows that a flight simulation experience can be created in such a way that is accessible to anyone with a cellphone and a computer.
You can pull the container from docker hub (not always up to date) here.
docker run -dp 3030:3030 --rm --name flight-sim jdehal/flight-sim
This will open the flight-sim program at http://localhost:3030
docker stop flight-sim
- Run
./docker_build.sh
to build the docker image - Run
./docker_run.sh
to run the container - Visit
http://localhost:3030
to view the simulator - Enter
docker stop flight-sim
to stop the container
- Clone the repository
- Run
npm install
to install dependencies (node >= v14 required) - Run
npm run build
to build the front-end view - Copy the
build/
folder to thesocket/
directory undersocket/build/
. - Enter
socket/
directory- Run
npm install
to install socket dependencies - Run
node server.js
to run the simulator
- Run
Simply run the simulator based on the install method chosen above. Then, scan the QR code shown with a smartphone. Once connected, it should begin to control the airplane like a joystick. Hold the phone upright, with the charging port facing down, and the screen facing to your left. Enjoy!
Smooth camera logic- Plane SFX
A QR code to connect with phone- Dynamic terrain/scenes to fly in
- Google earth support?
- Support for multiple socket connections on the same server
- Fix quaternion calculations to smooth bumpy controls