135 posts
Posted 25 May 2016 - 08:52 PM
I keep getting the attemp to index a nil value error in an if statement that checks if the value isnt nil
please help!
link to code:
http://pastebin.com/Viye5gAkLook at line 53
Edited on 25 May 2016 - 06:59 PM
3057 posts
Location
United States of America
Posted 25 May 2016 - 08:56 PM
I'm guessing the or is executing before the addition, for whatever reason.
Try changing it to:
(y+yd < 0) or (x+dx < 0)
135 posts
Posted 25 May 2016 - 08:59 PM
I'm guessing the or is executing before the addition, for whatever reason.
Try changing it to:
(y+yd < 0) or (x+dx < 0)
thanks for the quick response it turns out the "dx" i got mixed up for with "xd" LOL
fixed that quickly, thanks for your help though.
i am getting another error now not sure why.
3057 posts
Location
United States of America
Posted 25 May 2016 - 09:01 PM
135 posts
Posted 25 May 2016 - 09:12 PM
OH i see, lol cant believe i didnt see that xD
thanks!
it all works perfect now :)/>