Search found 69 matches

by Nelvin
Fri Jun 29, 2018 8:09 am
Forum: Support and Development
Topic: Coloring sprites with a per-vertex attribute in a spritebatch
Replies: 2
Views: 396

Re: Coloring sprites with a per-vertex attribute in a spritebatch

It's a per vertex attribute, so yes, you can use different values for quads in the same batch.
by Nelvin
Mon Jun 18, 2018 2:25 pm
Forum: Support and Development
Topic: [solved]issues with an isometric map
Replies: 4
Views: 855

Re: issues with an isometric map

Ah yeah, I just guessed the solution as that was the obvious problem with regards to the height. Here's a kind of "fixed" version that does remotely what you aim for (only quick fixed in terms of, a hacky version to show off how it's basically down, it's not a version to keep building upon, does jus...
by Nelvin
Mon Jun 18, 2018 11:00 am
Forum: General
Topic: ECS programming pattern question
Replies: 1
Views: 617

Re: ECS programming pattern question

If you solved your problem with one line of code and you're questioning your solution with 5 lines of text in a forum message I'd say, you've already done a decent job before posting. Seems like you found a solution, it's as pragmatic as possible (which is IMO really good) and there's actually no re...
by Nelvin
Mon Jun 18, 2018 5:22 am
Forum: Support and Development
Topic: [solved]issues with an isometric map
Replies: 4
Views: 855

Re: issues with an isometric map

You just have a typo (I guess) as, in Map:draw you use the height instead of height_size to calculate the yoffset and color gradient of your tiles.
by Nelvin
Tue Jun 12, 2018 6:00 am
Forum: Support and Development
Topic: Using love.graphics.newImage() with png files in an external directory
Replies: 7
Views: 1229

Re: Using love.graphics.newImage() with png files in an external directory

I use a helper function like this in such situations local function loadImageFromPath( filePath ) local f = io.open( filePath, "rb" ) if f then local data = f:read( "*all" ) f:close() if data then data = love.filesystem.newFileData( data, "tempname" ) data = love.image.newImageData( data ) local ima...
by Nelvin
Tue Jun 12, 2018 5:18 am
Forum: Support and Development
Topic: Pixelation when downscaling images, even when using 'linear' filter?
Replies: 5
Views: 710

Re: Pixelation when downscaling images, even when using 'linear' filter?

Have you tried if using mipmaps helps?

Change your image loading line into

Code: Select all

    heart = love.graphics.newImage("heart.png", { mipmaps=true } )
by Nelvin
Fri Jun 08, 2018 7:17 am
Forum: Support and Development
Topic: Simple Recursive Tactical RPG Movement Range Issue
Replies: 2
Views: 411

Re: Simple Recursive Tactical RPG Movement Range Issue

Your problem is that you recursively only check if the position is reachable and if so, mark it as true and never evaluate the position again. But to reach all the possible destinations you need to also check for the length of the path so far and not skip the recursion if you reached a tile in less ...
by Nelvin
Fri Jun 01, 2018 8:29 am
Forum: Support and Development
Topic: issue on showing large image
Replies: 6
Views: 766

Re: issue on showing large image

I've fixed the spritesheet for you - 2k x 2k is all you need, separating the shadow form the sprite will probably reduce to about half of that.
sprites_test_00.png
sprites_test_00.png (894.15 KiB) Viewed 742 times
by Nelvin
Tue May 29, 2018 11:52 am
Forum: Games and Creations
Topic: Stone Kingdoms 0.1 (RTS)
Replies: 8
Views: 2561

Re: Stone Kingdoms 0.1 (RTS)

Please don't tell me you do anything at a scale of 18000 files in an even remotely manual way?
Write small tools/scripts/batchfiles to convert/pack/generate textures, uvs, create animtables and save them as lua files you can directly require and use in your game etc. etc.
by Nelvin
Mon May 21, 2018 5:12 am
Forum: General
Topic: Improving Collision Resolution System
Replies: 1
Views: 444

Re: Improving Collision Resolution System

Depending on the final speed of your moving objects (defined by the velocity and dt) objects may tunnel through each other without a collision. The core issue is, you're object may move so fast, that the last check happens before a colliding tile and the next one when it's in a position fully behind...