PICO-8 Text Editor with Effects, #15

I’m trying to figure out how to handle particle effects. The problem is that I don’t know where letters appear on screen until the word wrap stage and I need to create particle effects at the letters’ screen positions. So now I’m faced with an architecture question: which makes more sense, storing effects in the letters, or in a separate table? And by effects, I mean flags which are consumed by the particle engine later. If I store effects in the letters, I could add effects to draw later as I’m word wrapping. On the other hand, a separate table would make more sense because the effects aren’t part of the letters. The other part which makes this tricky is that some letters don’t reach the word wrap stage. If the user presses a key and backspace at the same time, the letter is added and deleted without ever reaching word wrap. Maybe instead of deleting them immediately, I could mark them as deleted, and then delete them once I have their screen positions from the word wrap.
Anyway, at least screen shake is working.

Leave a comment

Your email address will not be published. Required fields are marked *


Your data is processed in accordance with my privacy policy. Comments are manually approved and may take a while to appear.