Search found 108 matches

by sphyrth
Mon Jul 08, 2019 10:24 pm
Forum: General
Topic: Custom map loading technique [Solved]
Replies: 32
Views: 9921

Re: Custom map loading technique

I'm not really sure. I also saw that effect and I assumed that it's because of the code's quirkiness. Maybe moving the image up and down behaves differently with moving it left and right. But then again, the original Tutorial doesn't have that problem. Anyway, that's my limit. I might try to solve t...
by sphyrth
Mon Jul 08, 2019 11:05 am
Forum: General
Topic: Custom map loading technique [Solved]
Replies: 32
Views: 9921

Re: Custom map loading technique

Okay, try this code. I stripped it down as much as I could to leave out the unimportant bits. I personally don't recommend depending on it as it's for discussion purposes (meaning that it's very rough and therefore inefficient for serious game prototyping). I assume this is how you want it to work. ...
by sphyrth
Sun Jul 07, 2019 10:38 pm
Forum: General
Topic: Custom map loading technique [Solved]
Replies: 32
Views: 9921

Re: Custom map loading technique

Okay, I think I have to review the tutorial to know what you are talking about (Weird Moving Square). When it comes to what zorg is talking about, it's a technique used by a lot of Adventure RPGs. I'm not sure how many games have been made, but they are in the Games and Creations section. In your pa...
by sphyrth
Sun Jul 07, 2019 1:09 pm
Forum: General
Topic: Custom map loading technique [Solved]
Replies: 32
Views: 9921

Re: Custom map loading technique

Tutorial: Efficient Tile-based Scrolling seems to cover that one up.

I don't really remember if it "deletes" tiles outside of the screen (because learning about Spritebatch was enough for me), but I assume that it also does that.
by sphyrth
Sun Jul 07, 2019 5:58 am
Forum: Support and Development
Topic: I am trying to draw multipule objects but only one is being drawn
Replies: 4
Views: 1231

Re: I am trying to draw multipule objects but only one is being drawn

pgimeno wrote:
Sat Jul 06, 2019 8:52 pm
This is a good example of why avoiding globals everywhere is a good idea.
More like "remembering local variables" is a good idea. I mean, I've stumbled several times simply because I forgot to put in local in my variables.

But yeah, what you said.

Code: Select all

local object = {}
by sphyrth
Sun Jul 07, 2019 5:51 am
Forum: Support and Development
Topic: How to use same image more than once
Replies: 7
Views: 1431

Re: How to use same image more than once

For now, change

Code: Select all

object[1] = blueprint[1]
to

Code: Select all

object[1].name = blueprint[1].name
by sphyrth
Sat Jul 06, 2019 5:16 am
Forum: Support and Development
Topic: Need help with selective collision detection
Replies: 14
Views: 2759

Re: Need help with selective collision detection

Sky_Render wrote:
Sat Jul 06, 2019 1:20 am
...category means "I am a..." and masks mean "and I won't touch...".
And this one helped ME figure out what you guys are talking about.
by sphyrth
Fri Jul 05, 2019 11:57 am
Forum: Support and Development
Topic: Need help with selective collision detection
Replies: 14
Views: 2759

Re: Need help with selective collision detection

As we wait for the more meaningful answers, let me put in my 2 cents: This is the best visual representation I can produce of what you're trying to achieve. A rough draft suggests that objects shouldn't ask the entities (player, enemies, items, projectiles) what NOT to collide with, but with WHAT th...
by sphyrth
Tue Jul 02, 2019 12:32 pm
Forum: Support and Development
Topic: The game paused but the time keeps running (Android)
Replies: 7
Views: 3137

Re: The game paused but the time keeps running (Android)

Bummer. I can't participate when the error can't be reproduced on a desktop.
by sphyrth
Fri Jun 28, 2019 1:56 pm
Forum: Support and Development
Topic: A Question about SpriteBatch and Maxsprites
Replies: 3
Views: 3962

A Question about SpriteBatch and Maxsprites

So this is what I've read in the SpriteBatch Wiki : 01.png Because of that, I started coding like this: spriteBatch = love.graphics.newSpriteBatch(img, 1) I just set maxsprites to 1, and let any tile I add grow it. Is it a good programming practice, or should I go with something like this: spriteBat...