Search found 39 matches

by IMP1
Wed Jan 11, 2012 12:56 pm
Forum: Support and Development
Topic: Mouse: How to emulate "MouseLook" from FPS games?
Replies: 24
Views: 2349

Re: Mouse: How to emulate "MouseLook" from FPS games?

This kinda works for me: function love.load() TURN_SPEED = 0.005 VISION_LENGTH = 1 inverseYAxis = true horizontalAngle = 0 verticalAngle = 0 love.mouse.setGrab(true) love.mouse.setVisible(false) love.mouse.setPosition( love.graphics.getWidth() / 2, love.graphics.getHeight() / 2 ) oldMouse = { love.m...
by IMP1
Sun Jan 08, 2012 2:58 am
Forum: Support and Development
Topic: My rubbishy cache thingy. Any point?
Replies: 7
Views: 604

My rubbishy cache thingy. Any point?

Now, I'm the first to admit that I'm not the oldest cow in the field, and so I'm always wondering whether what I think is a new and genius idea is actually doing any good. So I thought I'd ask whether this here code: local aliasNewImage = love.graphics.newImage local imageCache = {} function love.gr...
by IMP1
Fri Dec 30, 2011 2:31 pm
Forum: Support and Development
Topic: How do you change backgrounds when a key is pressed?
Replies: 2
Views: 390

Re: How do you change backgrounds when a key is pressed?

You shouldn't really have a love.graphics.draw in the love.keypressed method. Or anywhere outside of love.draw at all. this is how I'd go about what you seem to be trying to do: function love.load() love.graphics.setCaption("Seal Off") -- Create a table which we will fill with background images. bac...
by IMP1
Thu Dec 29, 2011 9:31 pm
Forum: Support and Development
Topic: Pausing.
Replies: 6
Views: 657

Re: Pausing.

And for when you lose focus:

Code: Select all

function love.focus(f)
  if not f and not paused then
    pause = true
  end
end
by IMP1
Tue Dec 27, 2011 11:33 pm
Forum: Support and Development
Topic: interacting with txt files?
Replies: 3
Views: 364

Re: interacting with txt files?

love.filesystem seems to be what you're looking for. Particularly http://love2d.org/wiki/love.filesystem.read ?
by IMP1
Wed Dec 14, 2011 5:04 pm
Forum: Games and Creations
Topic: Simple mouse game
Replies: 17
Views: 2768

Re: Simple mouse game

Why not link straight to the file?

http://www.speedyshare.com/file/V3Ss9/d ... pGame.Love

Like that ^

All the usefulness of obnoxious uploadery sites without any of the cons.
by IMP1
Fri Nov 04, 2011 10:38 am
Forum: General
Topic: Captcha on Forum Registration
Replies: 12
Views: 1739

Re: Captcha on Forum Registration

Can we not have both (recaptcha and mathsy thing)? I mean the spam is getting a bit ridiculous and, of late, pornographic. Which is not on.
by IMP1
Wed Nov 02, 2011 1:49 pm
Forum: Libraries and Tools
Topic: Life
Replies: 16
Views: 2123

Life

This is my rendition of Conway's Game of Life . If you don't know anything about it, and don't want to follow the link I provided, it's basically a zero-player game. Which means that after you set the initial conditions, there's not really anything for you to do but sit back and watch what happens. ...
by IMP1
Sun Oct 16, 2011 9:47 pm
Forum: Support and Development
Topic: Drawing Tiles Myself
Replies: 1
Views: 310

Drawing Tiles Myself

I hate for my first post to be a plea for help, but I guess it's just the way it's gotta be. So I used Tiled to create a map (shitty test map, shitty test tiles, but whatever). I exported it as a .lua, and tried to devise a way to draw it. I've attached the love file, which only has main.lua, the ma...