Earlier quoted context omitted.
In many aspects, Lua is more verbose and awkward than other similar languages. Compare local alive_enemies = {} for _, enemy in ipairs(enemies) do if not enemy.dead then table.insert(alive_enemies, enemy) end end enemies = alive_enemies with enemies = enemies.filter(enemy => enemy.alive)
It's more minimalistic, that's true. But there's nothing stopping you writing or downloading an array library so you can do this: enemies = array.filter(enemies, function(e) return e.alive end) Or even setting a metatable so you can do: enemies = enemies.filter(function(e) return e.alive end)
LÖVE: 2D Game Framework for Lua
141–150 of 229 posts
Re: LÖVE: 2D Game Framework for Lua
#142Re: LÖVE: 2D Game Framework for Lua
#143Am I really the first one to mention pico8 in this thread? Anyway, pico8 is another option that has a bit different spin, but you also implement the games in Lua :)
(It is neither open source nor free)
Re: LÖVE: 2D Game Framework for Lua
#144One of the biggest recent indie hits, Balatro, was made in Löve! I really like it, the developer experience is so smooth for beginners, just drag a zip onto the exe and it starts. And the APIs are simple enough to memorize while allowing pretty cool rendering stuff.
Moonring[1] is another one that that is written in Löve (apparently by the co-creator of XBox's Fable series). The base game is even available for free. I had lots of fun playing it.
Re: LÖVE: 2D Game Framework for Lua
#145Re: LÖVE: 2D Game Framework for Lua
#146Earlier quoted context omitted.
I know it’s bikeshedding and leads to pointless discussions, but in my opinion Lua would be the perfect scripting language if it had 0-based indexing. “It makes more sense this way” is not a good enough reason to break convention.
There is nothing stopping you from doing someArray[0] = "the first item", you know. For me, the table is extremely powerful. I like it that it can be used as a sparse array, a hash, a vector, whatever. Of course one must know, at heart, the difference between pairs() and ipairs() and what it means for your data, though ..
Yes, there is:
local l = {[0] = 'a', [1] = 'b', [2] = 'c'}
for i, c in ipairs(l) do
print(i, c)
end
This will only print the last two pairs. Lua is 1-indexed, end of story. You can store values at index zero, but it's no different than storing values at index -1 or index 'lolrofl'. It does not exist in the array-part of the table as far as Lua is concerned.Re: LÖVE: 2D Game Framework for Lua
#147I generally very much dislike dynamic languages but for some reason I've always really liked Lua. I'm not exactly sure why to be honest. Maybe because you can fit the whole language spec on a single sheet of paper and adding more advanced features is pretty easy. Love looks really cool. I never got into it personally but I still might
I know it’s bikeshedding and leads to pointless discussions, but in my opinion Lua would be the perfect scripting language if it had 0-based indexing. “It makes more sense this way” is not a good enough reason to break convention.
Re: LÖVE: 2D Game Framework for Lua
#148Earlier quoted context omitted.
Well, it's kind of a machine code for a self-modifying compiler, so there's that.
The source is not just dna - that's just one type of architecture that exists. There might be others that operate on different instruction sets. The real source is mathematics. But some might say it's incomplete.
If I remember correctly, Stargate-SG1 at one point had some ideas about this sort of universal language, that multiple species could use for communication, as any sufficiently intelligent specie probably been able to see atoms and so on, but may have completely other way of doing "math-like" stuff.
Re: LÖVE: 2D Game Framework for Lua
#149Earlier quoted context omitted.
extract the exe like a zip file, that's how love packages itself. last i looked at the source myself it had comments in still from the dev
I'm really curious how they do version control. The Steam version was created by one guy, but the platform ports have a couple different authors. The Google Play and Xbox PC versions, for instance, have divergences. I wonder how the ports influence the upstream and each other. How do they keep the codebases in sync, while also accounting for platform differences?
Re: LÖVE: 2D Game Framework for Lua
#150I love LÖVE. For me it sits at the perfect intersection between high and low level abstraction. Unfortunately the latest released version is getting pretty long in the tooth now and a lot of devs use the latest HEAD from the repo since it has better performance and compatibility. One day the mythical 12.0 will get released for real…..
How? has Lua changed any?
Or all the references are to old versions?