Saturday, December 14, 2024

Various Combat Engagement Stuff

It's a quick update, I've been neck deep in the code for the majority of the weekend now, and I've gotten it to a pretty decent place with encounters. This morning and late yesterday, I was wrestling with, of all things, the "Combat" button to show up and disappear in a quick and responsive manner.

As I was working with better code for creatures, I noticed a rather striking limitation on how this had worked in the past - namely, it really only looked at one creature at a time, which basically, did work reasonably well when the spawns weren't really up to the job. As I've fixed that, and there's now often more than one encounter on the screen, it's a bit trickier to manage. I can't simply show/hide the button when a single creature attacks or stops attacking. What if one is attacking, but a second one stops attacking... can't hide it yet... that sort of thing. Super super in the weeds of how this stuff works... but I've made this into another long-winded way of saying "It's working properly now!"

Now. While I've been playing quite deep into these sections of code, I've noticed some other things that would benefit from tweaks, so that's going to be my target for the rest of the day if I can manage it. I'd like to have the character stat bars and effects updating much more efficiently than they do currently - which is a one-size fits all "update everything" sort of command, which is actually quite horrible.

So, that's the plan. Update only when needed, and only what's needed to update. Oh, and to turn off things when characters aren't conscious. I noticed that characters that get knocked out, can still be activated (out of combat) and use things or abilities and so on. Derp. Whoopsie.

No comments:

Post a Comment

Rumourmill: There's Orcs About!

So, I've been smashing out as much as I can today, buying up some assets to use, and inserting them into the game as I build up the worl...