In our update() method, we will assign these values based on the player score and progressDenom. We will also use this method to call our updateUpperBound() and updateLowerBound() methods that we created earlier in this chapter:
this.updateUpperBound();this.updateLowerBound();maxBoundaryHeight = 30+playerCharacter.getScore() / progressDenom;if(maxBoundaryHeight > HEIGHT/4)maxBoundaryHeight = HEIGHT/4;minBoundaryHeight = 5 + playerCharacter.getScore()/progressDenom;
We're almost there. Now, the only thing remaining to create is our newGame() function.