The Farmer Was Replaced

The Farmer Was Replaced

drax14 16 Dec, 2024 @ 8:03am
next_x, next_y = measure() not working
next_x, next_y = measure() from the example dinosaurus
generate error:
Error: The left hand side of the assignment didn't match the right hand side.
In:
next_x, next_y = measure()

help my
< >
Showing 1-4 of 4 comments
BRNK 16 Dec, 2024 @ 11:04pm 
It's not saying that's how to assign the value, it's telling you what to expect from `measure()` when you use it over an apple. Use quick_print(), that should be more than enough of a hint to get you going.
Leo 17 Dec, 2024 @ 2:45pm 
if your snake eats itself- you will have this error xD in my case if measure() == None I just switch hats twice to overcome this issue
drax14 17 Dec, 2024 @ 11:47pm 
thx
I had to use if for 100% functionality
if get_entity_type() == Entities.Apple: next_x, next_y = measure()
Last edited by drax14; 17 Dec, 2024 @ 11:54pm
HarmG 18 Dec, 2024 @ 9:52am 
You can just do location = measure() then use location[0] for x and location[1] for y
< >
Showing 1-4 of 4 comments
Per page: 1530 50