Search found 3 matches

by maccard
Mon Feb 20, 2012 6:18 pm
Forum: Support and Development
Topic: box2D multiple Callbacks
Replies: 2
Views: 2118

Re: box2D multiple Callbacks

Apologies for not providing this first time around scrwidth = 1280 scrheight = 720 offset = 50 fy = 0 fx = 0 text = "" objects = {} -- table to hold all our physical objects function love.load() --initial setup scrwidth = 1280 scrheight = 720 offset = 50 love.graphics.setMode(scrwidth, scr...
by maccard
Mon Feb 20, 2012 12:28 pm
Forum: Support and Development
Topic: box2D multiple Callbacks
Replies: 2
Views: 2118

box2D multiple Callbacks

Hi, I'm having an issue with the Love2D physics callbacks. Each time I have a collision, the function gets called twice, meaning I can't do any updating in the callback. Is there a fix/workaround for this?
by maccard
Mon Feb 20, 2012 12:24 pm
Forum: Support and Development
Topic: Firing bullets, performance plummets
Replies: 4
Views: 2435

Re: Firing bullets, performance plummets

Not an expert on Love2D by any means, but from a programming perspective, it'd probably be faster to: Have an isActive flag on each bullet in the update loop check each bullets isActive flag. if it's true, then update it, if it's false, ignore it. Same in draw. When the bullet goes outside the range...