Search found 3 matches
- Sat Mar 09, 2024 9:41 pm
- Forum: Support and Development
- Topic: Method doesn't see self variable when called by other method (hump.class)
- Replies: 8
- Views: 2747
Re: Method doesn't see self variable when called by other method (hump.class)
Thanks all. Great community!
- Sat Mar 09, 2024 5:48 pm
- Forum: Support and Development
- Topic: Method doesn't see self variable when called by other method (hump.class)
- Replies: 8
- Views: 2747
Re: Method doesn't see self variable when called by other method (hump.class)
Many thanks. it works!
I came across this Class library on the Harvard CS50 Gaming course. Is there another one you’d recommend/are using?
I came across this Class library on the Harvard CS50 Gaming course. Is there another one you’d recommend/are using?
- Sat Mar 09, 2024 3:34 pm
- Forum: Support and Development
- Topic: Method doesn't see self variable when called by other method (hump.class)
- Replies: 8
- Views: 2747
Method doesn't see self variable when called by other method (hump.class)
Newbie question. I created a class with hump.class and try to access one of its variables in a method called by another method. The sub-method doesn't see the self. variable (nil). What do I miss? Output of the program below: Var in main 5 Var in sub nil Class = require 'lib/class' MyObject = Class ...