Quote:
Originally Posted by curtis0gj
But I am a bit confused with:
Auto.run(this, autoMethod);
this is still static. Since you now have a constructor and stuff, this should be "autonManager.run...".
|
To review
Static methods are designated by the "static" keyword, accessed through the classes name itself (ex. "Auto.run"), and do not have accessed to instanced variables and methods
Instaneced methods are designated through the lack of the "static" keyword, accessed through an instance of the class (ex. "autonManager.run..."), and have access to instanced variables and methods.
The specified piece of code is in Robot.autonomousInit. In robot, you have an instance of Auto named "autonManager", yet you attempt to call the instanced method "run" by designating the class "Auto" instead of the instance "autonManager"