Page 1 of 1

just asking for tips

Posted: Sun Apr 21, 2024 5:25 pm
by edu
can I change a body "y" position without applying force in it?

Re: just asking for tips

Posted: Sun Apr 21, 2024 6:10 pm
by marclurr
We're going to need more to go on. Are you using a physics engine or some custom physics? What are you trying to achieve, what have you tried and what is it doing instead of what you want? And lastly show us the code that's not working. :)

Re: just asking for tips

Posted: Sun Apr 21, 2024 7:03 pm
by dusoft
Sure:
https://love2d.org/wiki/Body:setPosition

Although you shouldn't have to directly set the position when using physics, in case of specific needs such as teleports etc. you can use this function.