Search found 10 matches

by mateusak
Fri Jun 07, 2019 1:08 am
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: RUBI Gamestate Stack

This way, you don't need to clobber the functions with 'if handled then return end'; you just return true when handled, and that stops propagation, which looks clean to me. I think that in most cases, you'll want the background draw() to be executed, therefore the cases where you need to check self...
by mateusak
Thu Jun 06, 2019 3:10 pm
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: RUBI Gamestate Stack

It wasn't my idea, it was in s-ol's library actually. I liked the design. You're the one who brought it to me. Anyways, I'm having a hard time deciding my approach. A messaging system sounds interesting but I don't see use for it on normal callbacks like update, draw, etc, and there's a special pro...
by mateusak
Thu Jun 06, 2019 2:33 am
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: RUBI Gamestate Stack

I've now taken a look at other similar libraries. Yours is the only one I see that has separate event handlers while running in the background, which seems interesting. However, I wonder if it wouldn't be better calling the same callbacks but letting them know whether they're on the background or n...
by mateusak
Wed Jun 05, 2019 11:00 pm
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: Lovely Scene Stack

From a state transition standpoint, I think it's mostly a DPDA. You really just have one active state, the one at the top of the stack. The fact that you invoke callbacks on the others doesn't have an influence on the structure of the state machine. I don't think it's nondeterministic. The term non...
by mateusak
Wed Jun 05, 2019 10:51 pm
Forum: Libraries and Tools
Topic: RUBI 9-Patch
Replies: 0
Views: 2192

RUBI 9-Patch

9-patch library with the ability to batch 9-patches. Based on Android 9-patch system (with the scaling top & left and padding bottom & right). It was created because the only existing library I could find, patchy, doesn't support batching AFAIK. Patchy also uses a rather CPU consuming immediate-mode...
by mateusak
Wed Jun 05, 2019 6:24 pm
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: Lovely Scene Stack

FWIW, conceptually I don't think it's a nondeterministic finite automaton, as NFAs have deterministic equivalents. I think it's a deterministic pushdown automaton. PDAs are automata with a state and a stack. I prefer to call them states (although a more accurate term could be screens), because the ...
by mateusak
Mon Jun 03, 2019 5:11 pm
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: Lovely Scene Stack

logic is uncaring; that said, future prospects are extending your lib with other functions that may be useful; that way it won't be just another generic/simple state manager on the block! :3 I've been in the game industry for many years and by far the most common way of managing game 'states' (whic...
by mateusak
Fri May 31, 2019 6:55 pm
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

Re: Lovely Scene Stack

dusoft wrote:
Wed May 29, 2019 8:10 pm
Well, it's basically a state management / switcher.
why do you hurt my feelings
by mateusak
Sat May 04, 2019 12:19 am
Forum: Libraries and Tools
Topic: Lovely Camera
Replies: 0
Views: 2100

Lovely Camera

Lovely Camera is a basic camera. It features target resolution, scaling mode, anchoring, optional black border, position, zoom, space conversions (screen to world, world to screen, screen to window, window to screen) and mouse position on those spaces (world and screen). If you want to do splitscree...
by mateusak
Thu May 02, 2019 4:16 am
Forum: Libraries and Tools
Topic: RUBI Gamestate Stack
Replies: 15
Views: 5425

RUBI Gamestate Stack

A gamestate stack is a way of handling game logic. Each gamestate receives the normal Love2D callbacks (update, draw, ...) and a few special stack related callbacks. The catch is that a gamestate can block these callbacks to gamestates under it (with blockDraw, blockUpdate and blockInput), which wil...