4.3 Starting a new simulation
Refer to official documentation here: https://github.com/phetsims/phet-info/blob/master/doc/phet-development-overview.md#creating-a-new-sim
After checking out the dependencies and installing grunt-cli in the preceding instructions, you can create your own simulation using the template.
- Check out the template sim, called ‘simula-rasa’ using this git
clone command:
cd phetsims
git clone https://github.com/phetsims/simula-rasa.git
- Install the chipper dependencies:
cd chipper
npm install
- Install the perennial dependencies:
cd ../perennial
npm install
- Use the perennial ‘grunt’ task to create a new sim, like so (still
in the perennial directory):
grunt create-sim --repo=NAME --author=AUTHOR
For instance, if the simulation is going to be named Acceleration Lab and the author is Jane Doe, then you could put:grunt create-sim --repo=acceleration-lab --author="Jane Doe"
- Test the created simulation in the browser and make sure it launches. It should be a blank simulation. Write to the Developing Interactive Simulations in HTML5 Google Group if you run into problems.
Citation: PhET Interactive Simulations. They can be found here at: https://github.com/phetsims
Available under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0).