Skip to content

snakerabbit/tprime

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TPrime

TPrime is a basic educational simulation game that allows users to interact with moving and static objects in varying degrees of gravitational pull and time dilation to demonstrate the theory of relativity.

Users are able to traverse between different states of physical constants and see a visual representation of the differences in the behavior of the objects that can be interacted with.

tprimelanding

Features

In TPrime, users are be able to:

  • toggle between different physical states that differ in the strength of gravitational fields and time dilation
  • Observe the changes in moving and static objects
  • Input age and see the effects that gravity have one time
  • Toggle the atmospheric gas levels to observe air friction
  • Toggle the mass of pendulum objects and soft objects to observe the effect of mass on gravitational force.

tprimeopen

The current age is input and the time following is added and displayed to demonstrate the effects of gravitational field on time using the Schwarzschild Gravitational Time Dilation equation.

In addition, the project includes:

  • a How To Play modal to describe how to interact with the simulation tprimemodal

Architecture and Technologies

This project was implemented with the following technologies

  • Vanilla JavaScript DOM for overall structure and game logic,
  • Canvas for DOM manipulation and rendering,
  • Matter.js for basic physics engine structure and manipulation,
  • Webpack to bundle and serve up the various scripts.

Future Direction

To evolve this project, I would like to do the following:

  • Add more objects and add the functionality for users to interactive by mouse or touch
  • Create a physics engine from scratch in order to have more flexibility in physics manipulation, and to gain autonomy from using JS libraries.
  • Create more physical states that the user can interact with
  • Allow users to render custom objects and have more user control of physical states

About

Javascript Project

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages