How can i make my code short ._.?!


#1

How can I walk ;-;!!!


#2

It seems you forgot to define item there should be a local behind it.
Also you cant just use hero:moveXY() you need to know the position/coordinates of the item therefore when trying to get them you use hero:moveXY(item.pos.x , item.pos.y)


#3

moveXY()


#5

not everything is correct you need to define item that means it should be

local item = hero:findNearestItem()

not

item = hero:findNearestItem()

#6

Thank you for explain me :smiley: