Search found 25 matches

by abyssol
Sat Feb 03, 2024 9:30 pm
Forum: General
Topic: will love extend mesh api
Replies: 2
Views: 1801

Re: will love extend mesh api

progress report: An asset system: support load .zip mod A scene system: each scene can be a file, and it has a main coroutine to run, main coroutine will be reused instead of being garbage when it is done. it is very easy to write something like loading screen, cause we can stop that scene function ...
by abyssol
Fri Feb 02, 2024 4:02 pm
Forum: General
Topic: will love extend mesh api
Replies: 2
Views: 1801

Re: will love extend mesh api

wow, maybe i can use setTexture and setDrawRange to handle pmx file, instead of separating vertices but I am not sure how is its performance and whether it works. :) ADD: a simple and crude way as a solution is to copy vertices according to vertex indices (faces) directly to form each mesh, each for...
by abyssol
Fri Feb 02, 2024 1:32 pm
Forum: General
Topic: will love extend mesh api
Replies: 2
Views: 1801

will love extend mesh api

I am writing a lot of 3D stuff in Love, rely on the little mesh api. I try to keep it lightweight and dirty, to fullfill most 3D workarounds, just like Love itself. It may now be close-source. I had read some 3d projects based on love, I think I have confidence to implement it well, especially in re...
by abyssol
Wed Jan 31, 2024 10:41 pm
Forum: Support and Development
Topic: [SOLVED]Need help with love.data.unpack
Replies: 2
Views: 1173

Re: [SOLVED]Need help with love.data.unpack

and I was stupid
I didn't notice that file:read() returns two values :P
by abyssol
Wed Jan 31, 2024 10:07 pm
Forum: Support and Development
Topic: [SOLVED]Need help with love.data.unpack
Replies: 2
Views: 1173

Re: Need help with love.data.unpack

SOLVED: I found that I must write down argument #3 'pos' which default is 1. (start of string

Code: Select all

love.data.unpack("I4", file:read(4), 1)
It is no 1 by default as said in wiki
by abyssol
Wed Jan 31, 2024 9:43 pm
Forum: Support and Development
Topic: [SOLVED]Need help with love.data.unpack
Replies: 2
Views: 1173

[SOLVED]Need help with love.data.unpack

local file = love.filesystem.read("a.bin") local s = love.data.unpack("I4", file, 5) -- is any difference between above and below? local file = love.filesystem.newFile("a.bin") file:open("r") file:seek(4) local s = love.data.unpack("I4", file:read(4...
by abyssol
Sat Dec 30, 2023 5:41 pm
Forum: General
Topic: Will Love have ephemeron table(or higher version lua) in the future?
Replies: 3
Views: 8219

Re: Will Love have ephemeron table(or higher version lua) in the future?

Well, you can compile love with whatever lua interpreter you want, be it vanilla lua or something more custom. And it's very unlikely that vanilla lua will be used as default anytime soon, because luajit is very darn fast, which is (at least, IMHO) more important to game development then some synta...
by abyssol
Sat Dec 30, 2023 8:48 am
Forum: General
Topic: Will Love have ephemeron table(or higher version lua) in the future?
Replies: 3
Views: 8219

Will Love have ephemeron table(or higher version lua) in the future?

I went back to taste latest lua for a few days. I think it has really fascinated me. :3 Like Ephemeron table, it is helpful for games development, especially in objects' lifecycle management. It help reducing code indeed. __gc is also a good feature. So I am deciding between luaJit and lua5.4, but w...
by abyssol
Sat Dec 09, 2023 2:03 pm
Forum: Support and Development
Topic: [SOLVED]One variable references two different objects simultaneously
Replies: 6
Views: 11243

Re: One variable references two different objects simultaneously

I believe your code is not accounting for the possibility that e may be nil. This makes your project crash if I click on some of the menu items displayed. As such, you might want to add some if-guard that makes the code return early. Wait, I think of your reply of my previous thread. It is clear to...
by abyssol
Sat Dec 09, 2023 1:30 pm
Forum: Support and Development
Topic: [SOLVED]One variable references two different objects simultaneously
Replies: 6
Views: 11243

Re: One variable references two different objects simultaneously

MrFariator wrote: Sat Dec 09, 2023 11:48 am
an example runs like thread topic says
lovegame.zip
(5.14 KiB) Downloaded 320 times
Well, it still seems like an impossible thing :oops: