Coder Social home page Coder Social logo

ruben3d / retroflightsim Goto Github PK

View Code? Open in Web Editor NEW
116.0 8.0 9.0 28.09 MB

Attempt to replicate the visuals of late 80s / early 90s flight simulators

Home Page: https://ruben3d.github.io/retroflightsim/dist

License: MIT License

HTML 1.45% TypeScript 97.59% CSS 0.70% JavaScript 0.26%
webgl flightsim 3d web threejs game retrogaming typescript

retroflightsim's Introduction

Retro Flight Simulator

Quick and dirty attempt to replicate the visuals of late 80s / early 90s flight simulators, using as a reference MicroProse's F-117A Nighthawk Stealth Fighter 2.0 (1991).

Live demo

https://ruben3d.github.io/retroflightsim/dist

Screenshots

How to build

You need node.js installed globally (I have been using 14.16.0).

$ cd retroflightsim
$ npm i
$ npm run build

How to run

Start the local web server:

$ cd retroflightsim
$ npm run serve

Then open localhost:8000 in your web browser (tested on Chrome/Linux).

Instructions

Settings

Generation

The generation of choice will simulate the experience of a game of that era:

  • 286/CGA: mid-80s
  • 286/EGA: late 80s
  • 386/VGA: early 90s
  • 486/SVGA: mid-90s before texture mapping

Flight model

The flight model selects the realism of the simulation:

  • Debug: Very simple flight model intended for debug purposes only. The plane can be stopped midair.
  • Arcade: Vaguely based on realistic parameters but closer to late 80s arcade experiences.

Keyboard layout

Choose your keyboard layout, for users using AZERTY or Dvorak keyboards.

Plane controls

Keyboard

Use the OSD settings to select the keyboard layout.

QWERTY (default):

  • W/S: Pitch
  • A/D: Roll
  • Q/E: Yaw
  • Z/X: Throttle

AZERTY:

  • Z/S: Pitch
  • Q/D: Roll
  • A/E: Yaw
  • W/X: Throttle

Dvorak:

  • ,/O: Pitch
  • A/E: Roll
  • '/.: Yaw
  • Q/J: Throttle

Joystick

The system supports a single device connected only. If the device has less than four axes the keyboard can be used to complement the missing controls. Joystick information displayed in the OSD help.

  • Axis 1: Pitch
  • Axis 0: Roll
  • Axis 3: Yaw
  • Axis 2: Throttle

Systems

  • G: Landing gear
  • F: Flaps
  • T: Select target
  • I: Toggle night (386/VGA) or IR (486/SVGA) for the tracking camera
  • H: Cycle through HUD focus modes (disabled, partial, full)

Views

  • N: Toggle day/night
  • 1: Cockpit
  • 2: Toggle exterior back/front
  • 3: Toggle exterior left/right
  • 4: Toggle to/from target

On reaching the limits of the detailed scenario the player position wraps around.

retroflightsim's People

Contributors

ruben3d avatar wmcmurray avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

retroflightsim's Issues

How does the magic velocity section in `arcadeFlightModel.ts` work?

Hi @ruben3d,

I'm working on my own arcade flight game in three and hope you could help me understand the way you apply velocity to your plane model.

Currently I'm getting my plane object's world direction via the Object3D.getWorldDirection(). Then I just apply a hard coded speed scalar value to that and add it the position of my plane.

You seem to hardcode a forward direction and then do some quaternion math to rotate your plane. Is there a benefit to that method?

Landing/Crashing

Crashing (ground only) will show the plane crashed and let start from the beginninig again.
Ignore the nature of the surface for now.

Feature Request: Customizing Hotkeys

Hi.

For those who don't use a QWZERTY keyboard layout (but instead, the AZERTY one, for example), do you think it would be possible to add an option to customize (Plane controls) hotkeys?

Thanks in advance.

Cockpit (320x200)

Aiming at a palette-based version that allows the same art to be reused across all the 320x200 modes by switching the palette

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.