Skip to content

Commit

Permalink
disable showAnswers, #67
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Malley <[email protected]>
  • Loading branch information
pixelzoom committed Jul 13, 2018
1 parent a1188e0 commit 5a02400
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 10 deletions.
3 changes: 0 additions & 3 deletions js/common/GLQueryParameters.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ define( function( require ) {

var GLQueryParameters = QueryStringMachine.getAll( {

// shows the game answers and additional debugging controls
showAnswers: { type: 'flag' },

// shows the game reward regardless of score
showReward: { type: 'flag' },

Expand Down
3 changes: 1 addition & 2 deletions js/linegame/view/ChallengeGraphNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ define( function( require ) {
'use strict';

// modules
var GLQueryParameters = require( 'GRAPHING_LINES/common/GLQueryParameters' );
var graphingLines = require( 'GRAPHING_LINES/graphingLines' );
var GraphNode = require( 'GRAPHING_LINES/common/view/GraphNode' );
var inherit = require( 'PHET_CORE/inherit' );
Expand Down Expand Up @@ -46,7 +45,7 @@ define( function( require ) {
GraphNode.call( this, challenge.graph, challenge.modelViewTransform );

// To reduce brain damage during development, show the answer as a translucent gray line.
if ( GLQueryParameters.showAnswers ) {
if ( phet.chipper.queryParameters.showAnswers ) {
this.addChild( new LineNode( new Property( challenge.answer.withColor( 'rgba( 0, 0, 0, 0.1 )' ) ), challenge.graph, challenge.modelViewTransform ) );
}

Expand Down
5 changes: 2 additions & 3 deletions js/linegame/view/ChallengeNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ define( function( require ) {
var EquationForm = require( 'GRAPHING_LINES/linegame/model/EquationForm' );
var FaceWithPointsNode = require( 'SCENERY_PHET/FaceWithPointsNode' );
var GLFont = require( 'GRAPHING_LINES/common/GLFont' );
var GLQueryParameters = require( 'GRAPHING_LINES/common/GLQueryParameters' );
var graphingLines = require( 'GRAPHING_LINES/graphingLines' );
var inherit = require( 'PHET_CORE/inherit' );
var LineGameConstants = require( 'GRAPHING_LINES/linegame/LineGameConstants' );
Expand Down Expand Up @@ -98,7 +97,7 @@ define( function( require ) {
this.buttonsParent.bottom = challengeSize.height - 20;

// debugging controls
if ( GLQueryParameters.showAnswers ) {
if ( phet.chipper.queryParameters.showAnswers ) {

// description at leftTop
var descriptionNode = new Text( challenge.description, { font: new GLFont( 16 ), fill: 'black' } );
Expand Down Expand Up @@ -188,7 +187,7 @@ define( function( require ) {
nextButton.visible = ( state === PlayState.NEXT );

// dev buttons
if ( GLQueryParameters.showAnswers ) {
if ( phet.chipper.queryParameters.showAnswers ) {
replayButton.visible = ( state === PlayState.NEXT );
skipButton.visible = !replayButton.visible;
}
Expand Down
3 changes: 1 addition & 2 deletions js/linegame/view/MakeTheEquationNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ define( function( require ) {
var EquationBoxNode = require( 'GRAPHING_LINES/linegame/view/EquationBoxNode' );
var EquationForm = require( 'GRAPHING_LINES/linegame/model/EquationForm' );
var GLConstants = require( 'GRAPHING_LINES/common/GLConstants' );
var GLQueryParameters = require( 'GRAPHING_LINES/common/GLQueryParameters' );
var graphingLines = require( 'GRAPHING_LINES/graphingLines' );
var inherit = require( 'PHET_CORE/inherit' );
var LineGameConstants = require( 'GRAPHING_LINES/linegame/LineGameConstants' );
Expand Down Expand Up @@ -94,7 +93,7 @@ define( function( require ) {
}

// To reduce brain damage during development, show the answer equation in translucent gray.
if ( GLQueryParameters.showAnswers ) {
if ( phet.chipper.queryParameters.showAnswers ) {
var devAnswerNode = ChallengeNode.createEquationNode( new Property( challenge.answer ), {
equationForm: challenge.equationForm,
fontSize: 14
Expand Down

0 comments on commit 5a02400

Please sign in to comment.