Closed smiths closed 6 years ago
Dear Dr.Smith,
Firstly thank you very much for your review and comments ! :) @smiths Yes as your comment said that I am wrong about how environment variables are used. I should not put variable in my class in environment part. I review lecture slides that I should put screen in this section. So I wonder where shall I put variables in class defined by myself ? For example in my class PieceObj below, I have series variables such as onGround. Now I consider I should put them in state variable section because they can be changed at run time. In template seems only these 2 sections about variables(environment var and state var)
class PieceObj { bool onGround; ... }
Thank you !
Best Regards, Marshall
The state variables section is where you define the variables for your class. In the definition of your PieceObj ADT, you definitely could have a state variable of type bool to represent onGround.
Update in d41c42bffcb30695686c5f9e681565a433f122a4
Available at 90f399e.