Page 1 of 1
Rasterizer
Posted: Fri Dec 06, 2013 4:02 pm
by Ref
Anybody know what the error message:
Error: [string "graphics.lua"]:1252: Incorrect parameter type: expected Rasterizer
really means?
Re: Rasterizer
Posted: Fri Dec 06, 2013 4:14 pm
by get52
remove the " " from love.graphics
[]
Posted: Fri Dec 06, 2013 5:05 pm
by bekey
-snip-
Re: Rasterizer
Posted: Fri Dec 06, 2013 5:24 pm
by Ref
Thanks.
Narrowed down to one line of code:
Code: Select all
if self.font then self.font = gr.newFont( self.font, self.width ) end
The surprise is that if I call it once, everything is fine. Twice gives the error.
Second surprise is that self didn't have a font field, so code shouldn't even have been executed.
Think that the bug is actually somewhere else that is effected by this.
No big deal - can work around.
Thanks again for the pointer as to error message meaning.
Re: Rasterizer
Posted: Sat Dec 07, 2013 9:53 am
by bartbes
The second time self.font is a Font object, not a font name (string).