u/DreamNotDeferred

*SOLVED* Solution details (in case it helps anyone else):

I’ve got 10 creatures, 5 on a player team (playercreatures) with IDs that start with “P”, and 5 on an enemy team (enemycreatures) with IDs that start with “E”. But I toss them all in the TurnOrder array to sort by their Speed stat to determine the order they take their turn each round. Arbitrarily, I had hardcoded their Speed values as numbers 1 through 10, with the enemy creatures getting the values of 6-10. So, in the TurnOrder array which was sorted to process highest speed first, the 5 enemy creatures were the first 5 creatures in the array, hence, CurrentActiveCreatureID always showing “EB4”, the ID of the enemycreature with the highest speed.

Problem is, after the above logic was implemented, I next tried to implement the logic to move them on their turn, but I only did it for the playercreatures. I’d planned to get it working for the playercreatures first, then just copy the working logic to the enemycreatures and tweak. So, the enemycreatures had no logic for turn action, but they were first in TurnOrder, so the whole thing just got stuck.

Thank God for the clarity of mind that can come from stepping away from something, someone told me about writing to the console, and I was able to see that the IDs weren't matching, I realized what was going on, and reversed the sort to “lowest to highest” (playercreatures first). Sure enough, the playercreatures each moved on their turn, one after another.

I’ve since added the enemy movement logic, and now everything’s moving properly.

Thanks all for your help!

-------------------------------------------ORIGINAL POST------------------------------------------------

Hey all,

See title. I included screenshots of the whole event sheet, since it's not super long, and in case context is needed. Logic for movement is in the second pic, see red text. When I preview, there's no movement. Appreciate any help, thanks.

https://preview.redd.it/q7nafomszuyg1.png?width=2565&format=png&auto=webp&s=bb0bddf6c6b05bf5b57857ec0eb805a95e3e125e

https://preview.redd.it/c3jpnluwzuyg1.png?width=2560&format=png&auto=webp&s=96e80159f17752d9e8a435eb20bd938d7f390525

https://preview.redd.it/16c6fjpxzuyg1.png?width=2561&format=png&auto=webp&s=8fcbf6ee7903770f829758a7c95c937cbd83ce3a

reddit.com
u/DreamNotDeferred — 19 days ago