Search found 11 matches
- Sun Mar 23, 2025 2:13 pm
- Forum: General
- Topic: ECS -- is it ok to have a method/function as a component ?
- Replies: 11
- Views: 1802
Re: ECS -- is it ok to have a method/function as a component ?
First of all, one more time thank you for your participation and help. It's insane how you're involved ! ___ but from this article here: I met this article before. First of all, I am not intrested in the animation loop which changes frames inside the animation which that article is mostly about. Yes...
- Sat Mar 22, 2025 5:57 am
- Forum: General
- Topic: ECS -- is it ok to have a method/function as a component ?
- Replies: 11
- Views: 1802
Re: ECS -- is it ok to have a method/function as a component ?
I kinda did that a week ago but met same initial problem. This is the walk system: local system = tiny.processingSystem({ nocache = true }) system.filter = tiny.requireAll('walk') function system:process(e, dt) if not e.surface then e.walk = nil e.fly = true return end e.animation.current = e.animat...
- Sun Mar 16, 2025 8:33 am
- Forum: Libraries and Tools
- Topic: [Library] tiny-ecs - Fast Simple Entity Component System
- Replies: 51
- Views: 104611
Re: [Library] tiny-ecs - Fast Simple Entity Component System
When filters are used, does it cache the results? For example, if I had a fadeout system that required "fadeout" and "opacity", would just adding those fields to an entity cause it to start using the fadeout system? Filters aren't updated until you cycle an entity in the world (...
- Fri Mar 14, 2025 6:28 pm
- Forum: General
- Topic: ECS -- is it ok to have a method/function as a component ?
- Replies: 11
- Views: 1802
Re: ECS -- is it ok to have a method/function as a component ?
I like the second approach. Looks more flexible and generic. However, this approach might be non-efficient when states are often changed from one to another. Oh the other hand for that I described: player states are not supposed to change frequently. I will try to implement this approach during this...
- Thu Mar 13, 2025 6:08 pm
- Forum: General
- Topic: ECS -- is it ok to have a method/function as a component ?
- Replies: 11
- Views: 1802
Re: ECS -- is it ok to have a method/function as a component ?
Hm. Quite interesting. I took a quick look at it. Sounds something that might fit my needs. Thank you ! Will be back with the response later.
- Thu Mar 13, 2025 2:36 pm
- Forum: General
- Topic: ECS -- is it ok to have a method/function as a component ?
- Replies: 11
- Views: 1802
Re: ECS -- is it ok to have a method/function as a component ?
Hi, @RNavega, Thank you for your reply. However, you answered a bit different question I am afraid. Yes, of course updating animation should go in another system. It is not a problem. Sorry if my post was ambiguous. Let me explain it in more details. Your player has different states: walk, fly, swim...
- Wed Mar 12, 2025 6:34 pm
- Forum: General
- Topic: ECS -- is it ok to have a method/function as a component ?
- Replies: 11
- Views: 1802
ECS -- is it ok to have a method/function as a component ?
I am working on a game using the ECS architecture pattern. It is very raw but I've reached some checkpoint implementing different stuff with that pattern (I am from OOP so biased a bit). Now I'm struggling with the Animation system/component. I have the Camera system which is intended to draw the .....
- Wed Feb 12, 2025 6:49 pm
- Forum: Libraries and Tools
- Topic: statemachine.lua
- Replies: 6
- Views: 10125
Re: statemachine.lua
@conroy, did you finish your game ?
- Sun Jan 05, 2025 4:59 pm
- Forum: General
- Topic: How to store/process metadata corresponding to a sprite
- Replies: 6
- Views: 3175
Re: How to store/process metadata corresponding to a sprite
Extended with the ability to load selections:
- Sun Jan 05, 2025 8:35 am
- Forum: General
- Topic: How to store/process metadata corresponding to a sprite
- Replies: 6
- Views: 3175
Re: How to store/process metadata corresponding to a sprite
Thank you all for the replies ! I took some time and wrote a plugin (script) for Aseprite though merging in some sense several approaches. It is similar to the JSON approach but it saves the selection in the `.lua` file with the same name as your sprite: This is the plugin (see attach). It is not fu...