-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Factor out SoccerModel and improve tandem names, see #6
- Loading branch information
Showing
7 changed files
with
72 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
// Copyright 2022, University of Colorado Boulder | ||
|
||
/** | ||
* TODO Describe this class and its responsibilities. | ||
* | ||
* @author Chris Klusendorf (PhET Interactive Simulations) | ||
* @author Sam Reid (PhET Interactive Simulations) | ||
*/ | ||
|
||
import optionize from '../../../../phet-core/js/optionize.js'; | ||
import Tandem from '../../../../tandem/js/Tandem.js'; | ||
import centerAndSpread from '../../centerAndSpread.js'; | ||
import CASModel, { CASModelOptions } from '../../common/model/CASModel.js'; | ||
import CASObjectType from '../../common/model/CASObjectType.js'; | ||
|
||
type SoccerModelSelfOptions = {}; | ||
type SoccerModelOptions = SoccerModelSelfOptions & CASModelOptions; | ||
|
||
class SoccerModel extends CASModel { | ||
|
||
constructor( options: SoccerModelOptions ) { | ||
|
||
options = optionize<SoccerModelOptions, SoccerModelSelfOptions, CASModelOptions>( { | ||
|
||
// phet-io options | ||
tandem: Tandem.REQUIRED | ||
}, options ); | ||
|
||
super( CASObjectType.SOCCER_BALL, options ); | ||
} | ||
|
||
/** | ||
* Resets the model. | ||
*/ | ||
reset() { | ||
} | ||
|
||
/** | ||
* Steps the model. | ||
* @param dt - time step, in seconds | ||
*/ | ||
step( dt: number ) { | ||
} | ||
} | ||
|
||
centerAndSpread.register( 'SoccerModel', SoccerModel ); | ||
export default SoccerModel; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters