## Simple Tiled Implementation - STI v1.2.3.0

pauljessup
Party member
Posts: 148
Joined: Wed Jul 03, 2013 4:06 am

### Re: Simple Tiled Implementation - STI v0.6.14

Straw man? This isn't me arguing with you. this was me making a statement.

1- This is so offtopic it's sick. What does any of this have to do with the STL anymore? Now it's you attacking my personal preferences in my coding HOBBY. Something I do for fun. For personal enjoyment. As a way to relax at the end of the day.
2- It's not a straw man because I'm not arguing with you. I'm stating a fact- I disable the use of OGL, D3D, etc, when I use it, since I don't use any of the enhancements that those systems provide. I don't need them. I want shit to work, I do it to make it work. I've been using Allegro since 1998, when I was compiling them in DJGPP for DOS. It didn't use OGL/D3D then and since then I haven't found the need (personally, as a hobby) to do so. I make retro games, I don't need anything fancy. That is how I use Allegro. Am I saying that's how you should use it if you use it? No. I was trying Love2d as a short cut- I was using Lua to extend my own engines, and wanted to have something that simplified this. That's all. I'm going to finish Sunsorrow in Love2d, then I'm moving back to something I'm more comfortable with.

All I ask is that you guys respect my personal choices in how I program as a HOBBY. My day job is a different story, and how I approach that is completely different. I don't need that kind of stress for something I'm doing for fun.

Karai17
Party member
Posts: 892
Joined: Sun Sep 02, 2012 10:46 pm

### Re: Simple Tiled Implementation - STI v0.6.14

I just don't even. You go out of your way to disable everything that was designed for exactly what you want to do (and more). At this point I either believe you are trolling harder than the force of 10,000 suns, or are seriously stuck in 1998. Either way, there is no need to continue this discussion. The simple fact of the matter is: STI uses sprite batches for supreme efficiency and optimization, therefore it is incompatible with CPU lighting. If you want to use STI, you are going to have to write a very simple tile-based lighting shader. If you'd rather keep your games extremely inefficient and CPU-bound, for whatever hilarious reasons you have, then STI won't work for you.

Good luck, you'll need it.

STI - An awesome Tiled library
LÖVE3D - A 3D library for LÖVE 0.10+

Dev Blog | GitHub | excessive ❤ moé

pauljessup
Party member
Posts: 148
Joined: Wed Jul 03, 2013 4:06 am

### Re: Simple Tiled Implementation - STI v0.6.14

Thank you. I'm glad this is done. Please respect my wishes though, and try not to call me silly, or stuck in some other timezone. I have my reasons, and it's outside of this forum to post it. As I say over and over again, just don't call me names. I guess that's really hard, so difficult to not be a jerk! I'm not trolling. You asked, I responded with my honest feelings, you insulted me. Awesome. (ps- we're on a forum, using a language called Love2d, making 2d games. Don't tell me I'm the one stuck in a different timezone without looking in the mirror)

Helvecta
Party member
Posts: 167
Joined: Wed Sep 26, 2012 6:35 pm

### Re: Simple Tiled Implementation - STI v0.6.14

Man, this library is intense! Documentation as long as twenty of my arms, covering anything I might need to know about, support for virtually anything that Tiled can throw at it, it's definitely something to behold. I know that if I hadn't made my own editor before realizing this library existed I would have jumped on the opportunity. Either way, mad kudos!

P.S. Is this based on Kadoba's older version?
P.P.S. Oh, you want to know what's in this briefcase, do you? Oh, nothing, just some fishing bait. No but seriously nice work.

Karai17
Party member
Posts: 892
Joined: Sun Sep 02, 2012 10:46 pm

### Re: Simple Tiled Implementation - STI v0.6.14

Thank you for your praise! No, this is not based on ATL, this was written from the ground up to fix some of the issues that ATL had.
STI - An awesome Tiled library
LÖVE3D - A 3D library for LÖVE 0.10+

Dev Blog | GitHub | excessive ❤ moé

Ref
Party member
Posts: 687
Joined: Wed May 02, 2012 11:05 pm

### Re: Simple Tiled Implementation - STI v0.6.14

Just wondering why:

Code: Select all

function Map:drawEllipse(mode, x, y, w, h, color)
local segments = 100
love.graphics.push()
love.graphics.translate(x + w/2, y + h/2)
love.graphics.scale(w/2, h/2)
love.graphics.setColor(color)
love.graphics.circle(mode, 0, 0, 1, segments)
love.graphics.pop()
end

function Map:drawEllipseOutline(x, y, rx, ry, color)
local segments = 100
local vertices = {}
for i=0, segments do
local angle = (i / segments) * math.pi * 2
local px = x + rx / 2 + math.cos(angle) * rx / 2
local py = y + ry / 2 + math.sin(angle) * ry / 2
vertices[#vertices+1] = px
vertices[#vertices+1] = py
end
love.graphics.setColor(color)
love.graphics.line(vertices)
end

when you could handle both cases with:

Code: Select all

function Map:drawEllipse( mode, x, y, rx, ry, color)
local segments = 100
local vertices = {}
for I = 0, 2*math.pi*(1-1/segments), 2*math.pi/segments do
local px = x + rx*(1 + math.cos( I ) ) / 2
local py = y + ry*(1 + math.sin( I ) ) / 2
vertices[#vertices+1] = px
vertices[#vertices+1] = py
end
love.graphics.setColor(color)
love.graphics.polygon(mode,vertices)
end

Ellipse x,y relative to upper left hand corner - either 'filled' or 'line'.
Just be obnoxious.

Karai17
Party member
Posts: 892
Joined: Sun Sep 02, 2012 10:46 pm

### Re: Simple Tiled Implementation - STI v0.6.14

"circle" does not have a mode, it just draws a solid circle, which is why I use a separate function for drawing an outline. That being said, using a polygon instead of circle makes a whole bunch of sense. I'll post this in the bug tracker and get around to adding it... at some point. :>
STI - An awesome Tiled library
LÖVE3D - A 3D library for LÖVE 0.10+

Dev Blog | GitHub | excessive ❤ moé

Mikaboshi
Prole
Posts: 12
Joined: Mon Jul 22, 2013 8:55 pm

### Re: Simple Tiled Implementation - STI v0.6.14

Great, I've been waiting for something like this, but I seem to have ran into a bug:
https://github.com/karai17/Simple-Tiled ... /issues/29

Clean3d
Prole
Posts: 30
Joined: Fri Mar 29, 2013 4:16 pm

### Re: Simple Tiled Implementation - STI v0.6.14

Just wanted to stop by and say thanks for all the hard work, Karai17! I switched to STI from ATL when I needed to hack in some animated tiles, and I really appreciate how easy that was. Thanks so much!

Karai17
Party member
Posts: 892
Joined: Sun Sep 02, 2012 10:46 pm

### Re: Simple Tiled Implementation - STI v0.6.14

<3

Do you think you could share your animation code? I have been trying to think of a way to add those in myself, but so far I am stumped.
STI - An awesome Tiled library
LÖVE3D - A 3D library for LÖVE 0.10+

Dev Blog | GitHub | excessive ❤ moé

### Who is online

Users browsing this forum: No registered users and 4 guests