I'm thinking nested for loops that check every term against every term?
A little wasteful if done poorly, but should work.
Guess i'll eat those cookies mahself!
Search found 20 matches
- Mon Jun 21, 2010 8:36 am
- Forum: General
- Topic: Having trouble getting a program running
- Replies: 34
- Views: 2278
I'm trying to write a program that simulates a 7 card hand dealt randomly, and putting output to the console if the hand was good or bad, but I'm not getting anywhere at all. What is wrong? I'm not getting an error, just a blank console. function love.main() while total < 100 do while rand == ran...
- Sat Apr 10, 2010 6:52 pm
- Forum: Support and Development
- Topic: New to Lua and love
- Replies: 3
- Views: 1005
I would start by returning to the wiki page and clicking on the link for love.audio. From here you should learn how to initialize/preload whatever sounds you want outside of your main loop using newSource. Then I would totally memorize love.audio.play( ____ ) because it's just that easy. Best of luc...
function love.mousereleased (x,y,button) ... love.mouse.setVisible(false) ... causes my mouse's position to become 0,0 for one frame upon moving the mouse for the first time after this is called. What is the best way to get around this? In my program my player is controlled by the position of the m...
I'm trying to make any sensible way of playing background music with the option of letting the user stop it in-game. if key == "m" then love.audio.play(bgmusic) end This above works fine for me. If I press "m" then the music starts, and it is fantastic. However if I make any attempt to have a functi...