Hi,
I trying to develope some small games using the LovePotion port. Wich actualle works fine. And a guy made a cool file for testing my work on a pc without the need of an actual emulator, Wich is pretty cool. Sadly everytime i use the, and using rectangles i get an error. And i'am still not very good in coding/using love especially if its unfamiliar code.
maybe some of you guys could help me with that. I Link the file/code below.
Thanks so far.
https://hastebin.com/imuxoweloq.lua
error with rectangles
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Re: error with rectangles
It would help if you specify the error you get. There is nothing obviously wrong with the code.
Also, using assert that way will result in poor performance - all arguments are evaluated before the assert function is called. You will be generating new strings every time, which is slow. If it's a simple constant string though, it's ok.
Also, using assert that way will result in poor performance - all arguments are evaluated before the assert function is called. You will be generating new strings every time, which is slow. If it's a simple constant string though, it's ok.
Re: error with rectangles
Okay thats weird, just try'd it out without any changes to get that error again, and everythink work as fine as it should be ...
I'll just go on with that, i am pretty sure it doesnt last long, and i will be right here again witz "that error", i remeber it was somthing about "old rectangles".
I'll just go on with that, i am pretty sure it doesnt last long, and i will be right here again witz "that error", i remeber it was somthing about "old rectangles".
Re: error with rectangles
Okay here i am, back again xD
The error i get is:
line 180: Bad argument #2 to 'oldRectangle' (number expected, got nill)
The error i get is:
line 180: Bad argument #2 to 'oldRectangle' (number expected, got nill)
Re: error with rectangles
well yeah, you are calling 'love.graphics.rectangle' with nil (no value) as the value for x. the error would be the same if you didn't use the DS code you posted (except it would read "Bad argument #2 to 'love.graphics.rectangle'")
Re: error with rectangles
ah okay yea i see my bad... But thanks for the quick help
Who is online
Users browsing this forum: Ahrefs [Bot] and 1 guest