just asking for tips

General discussion about LÖVE, Lua, game development, puns, and unicorns.
Post Reply
edu
Prole
Posts: 7
Joined: Sat Apr 06, 2024 2:21 pm

just asking for tips

Post by edu »

can I change a body "y" position without applying force in it?
User avatar
marclurr
Party member
Posts: 158
Joined: Fri Apr 22, 2022 9:25 am

Re: just asking for tips

Post 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. :)
User avatar
dusoft
Party member
Posts: 654
Joined: Fri Nov 08, 2013 12:07 am
Location: Europe usually
Contact:

Re: just asking for tips

Post 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.
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 4 guests