Use a script. Something containing
For quite a while I've been thinking about making ESC advance text boxes. That is doesn't is inconsistent with everything else in the engine. I expect making that change would break scripts in several games, so it would have to be another general preference bitset. But I think it could default to being turned on in new games.
Code:
if (key is pressed(key:esc)) then (advance textbox)
For quite a while I've been thinking about making ESC advance text boxes. That is doesn't is inconsistent with everything else in the engine. I expect making that change would break scripts in several games, so it would have to be another general preference bitset. But I think it could default to being turned on in new games.
Hmmm... This seems like a good option.
I think it could break some of my scripts where a text box and a menu are being used at the same time, so I would probably leave it off in my own games, but turning it on by default in new games sounds fine to me.
Anyway, Willy, it is hard to say how long it will be before such a feature is ready, so here is an example of how to use TMC's "if key is pressed" suggestion
I think it could break some of my scripts where a text box and a menu are being used at the same time, so I would probably leave it off in my own games, but turning it on by default in new games sounds fine to me.
Anyway, Willy, it is hard to say how long it will be before such a feature is ready, so here is an example of how to use TMC's "if key is pressed" suggestion
Code:
plotscript, show status box, begin
show text box(5)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
wait(1)
)
end
plotscript, show status box, begin
show text box(5)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
wait(1)
)
end
Here's my script, but it doesn't seem to be working. The text box still only closes with spacebar or return. As far as I can tell, none of the menu bitsets seem like they would affect it.
Code:
plotscript, status, begin
suspend player
show text box (33)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
)
wait for text box
open menu (0)
resume player
end
suspend player
show text box (33)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
)
wait for text box
open menu (0)
resume player
end
Oh, I think I see the problems.
First, Is that I forgot the "show text box" doesn't actually take effect until the next wait command, so you should add "wait(1)" right after the show text box
Next you need a "wait(1)" inside the "while" loop, otherwise the game will freeze up, because without a wait the keyboard will never be updated, so "key is pressed(key:esc)" won't be able to ever return true
Finally, remove the "wait for text box" because once you have the while loop working, it becomes redundant.
Let me know how that works.
Oh, actually, the "suspend player" and "resume player" are also not needed, because the player is always suspended automatically when you view a text box.
First, Is that I forgot the "show text box" doesn't actually take effect until the next wait command, so you should add "wait(1)" right after the show text box
Next you need a "wait(1)" inside the "while" loop, otherwise the game will freeze up, because without a wait the keyboard will never be updated, so "key is pressed(key:esc)" won't be able to ever return true
Finally, remove the "wait for text box" because once you have the while loop working, it becomes redundant.
Code:
plotscript, status, begin
suspend player
show text box (33)
wait(1)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
wait(1)
)
open menu (0)
resume player
end
plotscript, status, begin
suspend player
show text box (33)
wait(1)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
wait(1)
)
open menu (0)
resume player
end
Let me know how that works.
Oh, actually, the "suspend player" and "resume player" are also not needed, because the player is always suspended automatically when you view a text box.
Bob the Hamster wrote:
First, Is that I forgot the "show text box" doesn't actually take effect until the next wait command, so you should add "wait(1)" right after the show text box
Note that I've changed this in nightlies: there is now a backwards compatibility bitset called "showtextbox happens immediately", which is on by default in new games.
TMC wrote:
Note that I've changed this in nightlies: there is now a backwards compatibility bitset called "showtextbox happens immediately", which is on by default in new games.
Bob the Hamster wrote:
First, Is that I forgot the "show text box" doesn't actually take effect until the next wait command, so you should add "wait(1)" right after the show text box
Note that I've changed this in nightlies: there is now a backwards compatibility bitset called "showtextbox happens immediately", which is on by default in new games.
Sorslor though, I dig the updates you keep makin'
dOn'T MiNd mE! i'M jUsT CoNtAgIoUs!!!
Play Orbs CCG: http://orbsccg.com/r/4r6x
Bob the Hamster wrote:
Let me know how that works.
Code:
plotscript, status, begin
suspend player
show text box (33)
wait(1)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
wait(1)
)
open menu (0)
resume player
end
plotscript, status, begin
suspend player
show text box (33)
wait(1)
while(current text box >= 0) do(
if (key is pressed(key:esc)) then (advance textbox)
wait(1)
)
open menu (0)
resume player
end
Let me know how that works.
Sorry for the late reply. That worked like a charm.



