Search found 93 matches
- Sat Sep 17, 2022 5:34 pm
- Forum: Support and Development
- Topic: Moving sprite is jitter.
- Replies: 11
- Views: 3425
Re: Moving sprite is jitter.
For what it's worth, I don't see any jittering. Very smooth.
- Thu Jul 07, 2022 10:11 pm
- Forum: Support and Development
- Topic: ...
- Replies: 7
- Views: 3283
Re: I think slid is outdated and I need help saving with it
slib.lua -- line 86
change this:
to this:
change this:
Code: Select all
local size = love.filesystem.getInfo(filename)
Code: Select all
local size = love.filesystem.getInfo(filename).size
- Mon Jul 04, 2022 4:03 pm
- Forum: Libraries and Tools
- Topic: lua_switch, a shorthand for creating switch statements in lua
- Replies: 5
- Views: 5487
Re: lua_switch, a shorthand for creating switch statements in lua
Here's a really simple example with syntax that's more C-like. local function switch(value) return function (cases) cases[value]() end end local value = "hello" switch (value) { hello = function () print "Hello, world!" end, goodbye = function () print "Goodbye, world!"...
- Wed Jun 29, 2022 1:29 am
- Forum: Libraries and Tools
- Topic: LÖVE-MoonScript
- Replies: 3
- Views: 4486
Re: LÖVE-MoonScript
In case anyone is interested, I modified the default error handler to use MoonScript line numbers when available. This is probably the last update I'll make to this project until either LÖVE or MoonScript are updated.
- Sat Jun 18, 2022 2:24 pm
- Forum: General
- Topic: Need help creating a specific function
- Replies: 12
- Views: 4865
Re: Need help creating a specific function
That looks great . Excellent work for a first project in LÖVE. And yes, the lerp function takes a normalized time to 0.0 to 1.0. The duration and elapsed properties of the enemies are in seconds.
- Sat Jun 18, 2022 12:17 am
- Forum: General
- Topic: Need help creating a specific function
- Replies: 12
- Views: 4865
Re: Need help creating a specific function
Thank you for your help, I will try to """""convert"""""" it for my code ! I understand how it works mostly, i'll give updates when things starts to look better than a blue screen :D No problem! And please do post updates, I love to see what ot...
- Fri Jun 17, 2022 11:47 pm
- Forum: General
- Topic: Need help creating a specific function
- Replies: 12
- Views: 4865
Re: Need help creating a specific function
What you want is a function that acts across frames to move your enemy to the desired location over a period of time. Unfortunately, this is not possible. No matter what you do, you need to have *something* in love.update that moves the enemy frame by frame. You can take my code as an example and ad...
- Fri Jun 17, 2022 11:10 pm
- Forum: General
- Topic: Mega Moonlight Mania - Art
- Replies: 6
- Views: 2484
Re: Mega Moonlight Mania - Art
Nice job, great art! Is that cake a lie, or am I just seeing things?
- Fri Jun 17, 2022 10:45 pm
- Forum: General
- Topic: Need help creating a specific function
- Replies: 12
- Views: 4865
Re: Need help creating a specific function
Maybe this can help you get started? local enemy = { origin = {x = 100, y = 100}, -- pixels destination = {x = 400, y = 200}, duration = 1.0, -- seconds elapsed = 0.0 } local function lerp(from, to, t) return {x = from.x + (to.x - from.x) * t, y = from.y + (to.y - from.y) * t} end function love.upda...
- Sun Jun 12, 2022 2:08 pm
- Forum: Libraries and Tools
- Topic: LÖVE-MoonScript
- Replies: 3
- Views: 4486
LÖVE-MoonScript
Hello, everyone! Long time no post (I was getting my hands dirty with Unity and Godot). I'm back to the awesomest engine out there, and I have a project to share with you. :awesome: Have you heard of MoonScript before? If so, you should be excited. If not, you really should take a look at it. Great ...