!IqEpaTAhXMMTmUWDnC:matrix.org

Vegan on a Desert Island

748 Members
Cheeky adventure game about activism and animal liberation (WIP). https://gitlab.com/voadi/voadi41 Servers

Load older messages


SenderMessageTime
12 Jul 2019
@alexgleason:matrix.orgAlexI tried sharing another message which causes Riot to crash15:50:31
@alexgleason:matrix.orgAlex Anyway it would be like "darkness/" .. entity:get_sprite():get_id() 15:51:17
@daniel-molina:matrix.orgdaniel-molinaok15:51:43
@alexgleason:matrix.orgAlex The hardest part might be reorganizing the assets in this way so I'll do that first 15:52:19
@alexgleason:matrix.orgAlexIt sounds like you're suffering from the heat quite a bit so there's no pressure to do it today15:52:54
@daniel-molina:matrix.orgdaniel-molinahaha, I can work15:53:23
@daniel-molina:matrix.orgdaniel-molinaor maybe share ideas with you15:53:40
@daniel-molina:matrix.orgdaniel-molinasometimes I think t is useful to you to share your thinkings, it is ok with me15:54:20
@alexgleason:matrix.orgAlexYes15:54:28
@alexgleason:matrix.orgAlexFeel free to commit anything to a branch15:54:39
@alexgleason:matrix.orgAlexIt will take me a little while to reorganize the assets but I'll do that now15:54:48
@alexgleason:matrix.orgAlexThis will be a bit tricky. It's okay to commit some code that doesn't work.15:55:00
@daniel-molina:matrix.orgdaniel-molinaI will look for some commands to check if a file exists in lua15:55:33
@alexgleason:matrix.orgAlexI think Solarus itself might have some helpers15:56:22
@alexgleason:matrix.orgAlexBut also you might be able to try creating a new sprite object with the given ID, and just use a try/catch if it fails15:56:49
@alexgleason:matrix.orgAlexMaybe we should also think about what functions the darkness menu needs15:57:31
@alexgleason:matrix.orgAlex Like perhaps darkness:process_entities() performs the looping over all entities, and calls darkness:process_entity(entity) internally. The second function will have the logic which looks for the darkness sprite. 15:58:21
@alexgleason:matrix.orgAlexOh right, but we have to keep draw functions separate from on_creation functions15:59:25
@alexgleason:matrix.orgAlexGenerally speaking, maybe the first step is just to break up the existing code into separate function so it makes more sense15:59:52
@alexgleason:matrix.orgAlexThen it will be easier to refactor and add new functions without breaking it16:00:09
@alexgleason:matrix.orgAlexThe spotlights are also a separate thing16:01:46
@alexgleason:matrix.orgAlexI think we should handle it similar to how we did the interaction bubble. So if an entity has a function like "entity:should_show_spotlight()` then show the spotlight16:02:26
@_discord_321461848828542976:t2bot.iollamazing @Alex I don't understand why you said earlier that you need a game:on_map_loaded() event? Wouldn't that just be the same as map:on_started()? 16:02:08
@alexgleason:matrix.orgAlex In the case of a torch entity, the should_show_spotlight() function would be true if torch.is_lit is true 16:02:59
@daniel-molina:matrix.orgdaniel-molinaanother function would be needed to get the radius16:03:58
@alexgleason:matrix.orgAlex Maybe it could be called get_spotlight_size() instead. If it doesn't exist on the entity, the entity is skipped. If it does exist it should return the size, or nil / false to not draw the spotlight 16:05:04
@alexgleason:matrix.orgAlexI'll take notes on the issue16:05:50
@daniel-molina:matrix.orgdaniel-molina and what about the sprite:get_id(), do you have an idea of how to define it? Alex 16:07:33
@alexgleason:matrix.orgAlex
In reply to @daniel-molina:matrix.org
and what about the sprite:get_id(), do you have an idea of how to define it? Alex
Oh shit. I had no idea this wasn't in the engine.
16:08:18
@alexgleason:matrix.orgAlexOh, I just have the wrong name16:08:35

Show newer messages


Back to Room ListRoom Version: