Search found 153 matches

by The Burrito
Fri Jan 27, 2012 8:00 pm
Forum: Support and Development
Topic: draw question
Replies: 3
Views: 405

Re: draw question

Since you're telling it to draw in the exact same spot each time it's going to draw them right on top of each other. I'm guessing you want something that will draw n circles in random positions and make them fly across the screen, so try something like this: px = 600 circles = {} for i=1,5 do circle...
by The Burrito
Tue Jan 24, 2012 5:34 am
Forum: Support and Development
Topic: Saving[Please helpDD:]
Replies: 4
Views: 1116

Re: Saving.

I assume you mean between sessions. You'll probably want to use love.filesystem.newFile() to generate a file, and you can load it using love.filesystem.load(). So you might have something that looks like this to create a save: savefile = love.filesystem.newFile('save.lua') savefile:open('w') savefil...
by The Burrito
Mon Jan 23, 2012 7:51 am
Forum: Support and Development
Topic: Light (dynamic?)
Replies: 16
Views: 3632

Re: Light (dynamic?)

There are several ways to do lights, since Löve supports stencils and framebuffers it's not too complicated even if you want multiple lights. I rely on the physics engine's features ( here's what I wrote about it ) to do dynamic lights. However my game's mechanic requires the lights to behave in a v...
by The Burrito
Fri Jan 20, 2012 4:43 pm
Forum: Games and Creations
Topic: Bomberman
Replies: 14
Views: 3531

Re: Bomberman

Yay bomberman! As the others said it does feel a little off, but it's playable, so thats a good start. I think the collision needs to be changed a bit, if you walk to the left into the bottom right corner of a block, you'll overlap the block a bit and won't be able to move up or left. Something to p...
by The Burrito
Tue Jan 17, 2012 6:10 am
Forum: Support and Development
Topic: Is there a safe way to generate physics polygons?
Replies: 10
Views: 1209

Re: Is there a safe way to generate physics polygons?

Thanks! hopefully I'll be able to finish In The Dark soon, I've been working on it in some capacity for a long time (my first rough proof of concept for it was just over 2 years ago :shock: ) but only seriously for the last few months. Trying out these angle based checks and they seem to work, now l...
by The Burrito
Tue Jan 17, 2012 3:28 am
Forum: Support and Development
Topic: Is there a safe way to generate physics polygons?
Replies: 10
Views: 1209

Re: Is there a safe way to generate physics polygons?

Cool, thanks. Somewhat ironically I don't remember any geometry from school because I spent the entire class programming games on a ti-83. :P
by The Burrito
Tue Jan 17, 2012 1:48 am
Forum: Support and Development
Topic: Is there a safe way to generate physics polygons?
Replies: 10
Views: 1209

Re: Is there a safe way to generate physics polygons?

Oh yeah, that makes sense, just compare each coord with the 2 adjacent and make sure none of the angles are > 180.

The easiest way I can think of to determine the polygon winding is averaging all the coords and comparing the angles to that center point, so I guess I'll give that a try.

Thanks
by The Burrito
Tue Jan 17, 2012 12:25 am
Forum: Support and Development
Topic: Is there a safe way to generate physics polygons?
Replies: 10
Views: 1209

Is there a safe way to generate physics polygons?

I started adding a polygon drawing tool to my map editor today, and I realized I can't think of an efficient way to ensure that the polygon is convex, or that the points are in counter-clockwise order. I figure there must be a fairly easy way to do this, but I haven't been able to come up with anyth...
by The Burrito
Tue Jan 17, 2012 12:14 am
Forum: Support and Development
Topic: Advanced Table Stuff[Solved][Thanks!]
Replies: 4
Views: 457

Re: Advanced Table Stuff.

for some reason the bullets won't dissapear well for one i is not defined with your loop, but also like I said you don't want to mess with the table while you're iterating through it, bad things will happen. Try this: local delTable = {} for bIter, bullet in ipairs(bullet) do for zIter, zombie in i...
by The Burrito
Mon Jan 16, 2012 8:21 pm
Forum: Support and Development
Topic: Creating more than one block through 2 lua files
Replies: 27
Views: 4951

Re: Creating more than one block through 2 lua files

Basically you don't want to define things like love.draw or love.load outside of main.lua, what you should do is maybe rename them to blockdamageDraw or something and then call that within love.draw in main.lua so you have something like: function love.draw() love.graphics.rectangle("fill",rect.x,re...