Search found 5 matches

by evolve
Mon Nov 24, 2008 7:45 pm
Forum: General
Topic: Typo in the documentation
Replies: 5
Views: 2127

Typo in the documentation

Found a type: http://love2d.org/docs/Body_setMass_1.html -- "The interia." should be inertia.
by evolve
Mon Nov 24, 2008 5:35 pm
Forum: Support and Development
Topic: Physics help...
Replies: 7
Views: 3094

Re: Physics help...

I've ended up using applyImpulse to move the body and it is working fine now.

For future reference, when you applyImpulse you do not have to take into consideration the bodies current x/y coords. This makes sense if you think about it, but was causing me a lot of trouble.
by evolve
Mon Nov 24, 2008 3:31 pm
Forum: Support and Development
Topic: Making a flashlight
Replies: 12
Views: 3844

Re: Making a flashlight

Not sure how optimized this would be, but you could have a giant image for the flashlight, it would have to be 4 times the screen size, and have a transparent hole in the middle of it. Then move that, and make sure the zombies are drawn under that layer.
by evolve
Mon Nov 24, 2008 5:32 am
Forum: Support and Development
Topic: Physics help...
Replies: 7
Views: 3094

Re: Physics help...

Thank you for the reply, and yes indeed collision does *sometimes* work when you set the position directly using setPosition() or setX/Y, however it only works if you have some gravity. As soon as you setGravity(0,0) all bodies will go straight through each other. Furthermore, from the documentation...
by evolve
Mon Nov 24, 2008 3:09 am
Forum: Support and Development
Topic: Physics help...
Replies: 7
Views: 3094

Physics help...

Ok, for a little test game that I am writing I'm using the physics module mainly for easier collision detection. The game is overhead 2d and thus has no gravity. Originally I just was using the body:setX/setY function in order to move the player, however I then realized that you can't check collisio...