andrew-peng-144 / js-explore-game

0 stars 0 forks source link

clean text dialogue #8

Open andrew-peng-144 opened 3 years ago

andrew-peng-144 commented 3 years ago

how text dialogue works: For each "phrase" or sentence:

andrew-peng-144 commented 3 years ago

should there be only one main text box? for this text dialogue?

Just can use hide/show for this, then set text. And it should automatically pace the characters and fill it line by line. Also it should parse escape sequences like @n to force to get on next line

andrew-peng-144 commented 3 years ago

Cannot have the text visually scroll upward, unless using a new canvas for text dialogue. So if we still want to keep using only 1 canvas, then instead, we just have the text fill all the lines, then clear all and restart from the top, like in Pokemon gen 3.

andrew-peng-144 commented 3 years ago

done lmao kinda. Text rendering works like pokemon gen 3 dialogue style. Controller functions seem to work properly. Can support many sizes, but the text string length must be calibrated manually as it doesn't calculate an ideal size for any width. Also only works with monospace fonts for now. Also supports escaping the dialogue which is stopping the text until the player advances.

Next step is to hook up the dialogue controller to activators. And also prevent player from advancing mid-sentence.