www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - "Error: need 'this' for 'bbox' of type 'Bong!(double, 3u)'"

reply Enjoys Math <enjoysmath gmail.com> writes:
I'm getting that on the last line of this code:

		auto wh = Vec2([loadSurf.w, loadSurf.h]);
		wh /= 2;
		auto x = wh.plus1Dim(pos[Z]);
		this.bbox = Box3(pos - x, pos + x);

Any ideas?
Feb 05 2016
parent Enjoys Math <enjoysmath gmail.com> writes:
On Saturday, 6 February 2016 at 04:41:26 UTC, Enjoys Math wrote:
 I'm getting that on the last line of this code:

 		auto wh = Vec2([loadSurf.w, loadSurf.h]);
 		wh /= 2;
 		auto x = wh.plus1Dim(pos[Z]);
 		this.bbox = Box3(pos - x, pos + x);

 Any ideas?
Found it, this was occuring in a static function.
Feb 05 2016