
上QQ阅读APP看书,第一时间看更新
Time for action — modifying the gameClasses file
To modify the gameClasses
file, follow the ensuing steps:
- Open the
gameClasses.monkey
file. - Add an
Import
statement for theexplosionClass.monkey
file.Import rocketClass Import explosionClass
- Save the file and close it.
What just happened?
You have added the explosion
class to the game, so that it can be used later on.