*facepalm*
I thought it was ok to set dt as a global variable, well that ended up being the problem. Thanks a lot for all your help.
Search found 24 matches
- Tue Jan 27, 2015 1:50 am
- Forum: Support and Development
- Topic: Window being held issue
- Replies: 9
- Views: 3170
- Sun Jan 25, 2015 8:32 pm
- Forum: Support and Development
- Topic: Window being held issue
- Replies: 9
- Views: 3170
Re: Window being held issue
This is what I now have, however it is not working. If you hold the window long enough all the enemies will end up with the same x and y values.
Code: Select all
function love.update(dt)
dt=math.min(dt,1/30)
--run events
end
Code: Select all
self.x=self.x+100*dt
- Sun Jan 25, 2015 11:04 am
- Forum: Support and Development
- Topic: Window being held issue
- Replies: 9
- Views: 3170
Re: Window being held issue
Can someone please post code of this, all my attempts have failed.
My Attempt
Also for the enemy moving im using:
My Attempt
Code: Select all
function love.update(dt)
dtc_start=love.timer.getTime()
--Process events
dtc=love.timer.getTime()-dtc_start
end
Code: Select all
self.x=self.x+100*dtc
- Sat Jan 17, 2015 11:17 pm
- Forum: Support and Development
- Topic: Window being held issue
- Replies: 9
- Views: 3170
Window being held issue
Is there any way to check if the game window is being held, also is there any way to make so the game won't stop when the window is held.