Search found 410 matches

by miko
Thu Apr 14, 2011 11:46 pm
Forum: Support and Development
Topic: MySQL?
Replies: 24
Views: 17562

Re: MySQL?

You could use luaSQL . Though you would have to add it in to your own copy of the LOVE source files, and then compile your own version. That is, if you wanted to use it with LOVE. Lua can load modules dynamically. So if lua can load a module, then love could do it also. You just need to put your (b...
by miko
Wed Apr 13, 2011 10:22 pm
Forum: General
Topic: Waiting.
Replies: 15
Views: 5215

Re: Waiting.

See this page here buddy: http://lua-users.org/wiki/SleepFunction The author provides this solution: local clock = os.clock function sleep(n) -- seconds local t0 = clock() while clock() - t0 <= n do end end -- warning: clock can eventually wrap around for sufficiently large n -- (whose value is pla...
by miko
Wed Apr 13, 2011 10:11 pm
Forum: Support and Development
Topic: Why love.update() instead of love.draw()?
Replies: 5
Views: 2159

Re: Why love.update() instead of love.draw()?

Is there any reason why I should use love.update() instead of putting calculations in love.draw()? If I for example get the mouseposition in love update() wouldn't it be the same as getting it in draw()? There are some situations, where you want to update() but not to draw(). For example, android c...
by miko
Mon Apr 11, 2011 11:18 pm
Forum: Support and Development
Topic: Trying a Qix clone.
Replies: 5
Views: 3172

Re: Trying a Qix clone.

I can see the problem. But still, I cannot tell if this is the right direction for what I'm trying to do. And still, I have no clue on how to limit the cursor movement only on the traced lines. I really need some help to see clearer where I should go... Don't worry, you are almost there. Some rando...
by miko
Sun Apr 10, 2011 8:39 pm
Forum: Support and Development
Topic: Slow fonts
Replies: 4
Views: 1739

Re: Slow fonts

anjo wrote:That it is. It will be much faster in 0.8.0.
How much faster? I just noticed the same, and wondered if people used framebuffers for images with lots of strings? Anyway, can I assume that for 0.8.0 print() will be the fastest way to put (dynamic) strings?
BTW, any ETA of 0.8.0 release?
by miko
Tue Apr 05, 2011 11:34 pm
Forum: Support and Development
Topic: Can I have multiple keypressed callbacks?
Replies: 15
Views: 8599

Re: Can I have multiple keypressed callbacks?

Topic pretty much says it. Currently I have this: ... But only escape works and if I comment out escape, pause works. Can I have both? Others already replied, but I know (I hope) what you are trying to do. So here is another approach: -- main.lua KEYPRESSED={} function love.keypressed(key, unicode)...
by miko
Sun Apr 03, 2011 8:47 pm
Forum: Support and Development
Topic: Arbitrary scissor shapes?
Replies: 11
Views: 3882

Re: Arbitrary scissor shapes?

Robin wrote:How would that be an improvement over using scissor?
It would be an improvement over using mapPixel(). I imagine you could render one part of image to buffer1, another one to buffer2, and then combine them (or put buffer2 over the half of buffer1).
Note: I hope that I am right, I have not tested it.
by miko
Sun Apr 03, 2011 8:25 pm
Forum: Support and Development
Topic: Love testing framework?
Replies: 6
Views: 5101

Re: Love testing framework?

TDD lover here. At the moment löve simply ignores testing. I mean, there's no assert_image_visible (x,y). The only way of testing right now is actually starting löve and doing a visual check. In plain Lua, however, there are some facilities. I use telescope for testing middleclass. Others prefer lu...
by miko
Sun Apr 03, 2011 8:18 pm
Forum: Support and Development
Topic: Arbitrary scissor shapes?
Replies: 11
Views: 3882

Re: Arbitrary scissor shapes?

Robin wrote:mapPixel could work, but that would be horribly, horribly slow.
How about ImageData:paste()? You could only split it horizontally or vertically, but still should be faster.
by miko
Thu Mar 31, 2011 10:17 am
Forum: Support and Development
Topic: What is mouse button x1 and x2 ?
Replies: 6
Views: 22960

Re: What is mouse button x1 and x2 ?

I'm trying to compile love 0.7.1 on linux (debian). My SDL library does not contains SDL_BUTTON_X1 and SDL_BUTTON_X2. I have : $ grep -r SDL_BUTTON_ /usr/include/SDL/ /usr/include/SDL/SDL_mouse.h:#define SDL_BUTTON_LEFT 1 /usr/include/SDL/SDL_mouse.h:#define SDL_BUTTON_MIDDLE 2 /usr/include/SDL/SDL...