Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

[SOLVED][BUG] STM Reads out while game (in-editor) is paused

A topic by hy created Sep 20, 2017 Views: 476 Replies: 12
Viewing posts 1 to 5
(1 edit)


Above attached gif demonstrates the effect. (alternative link here: https://i.imgur.com/PYTdVmI.gif)

While a line of text from the Dialogue Sample  (with readout controls script attached) is being read, pausing the game in the editor does not halt the readout. While the graphics and sound halt, it is still being read normally in the background. Unpausing the game in the editor will update and the graphics will load, being at the expected 'point' as if the readout had been continuous. Everything else behaves as expected.

Developer

Hey!

This is a weird one - could you let me know if it still happens when "ignore time scale" is true/false, and if "remember read position" is true/false?

It might just be a quirk of the editor if those don't effect it, since meshes reading out should be based on an internal timer, not Time.time.

Oh ! Currently, both are set to 'true'.

If Ignore Time Scale is false, but Remember Read Position is true...
-Text readout pauses with editor pause.

If Ignore Time Scale is true, but Remember Read Position is false...
-Similar behaviour to both being true occurs
-All sounds play rapidly when catching up to current readout position

If Ignore Time Scale and Remember Read Position are false...
-Text readout pauses with editor pause.

When toggling them during play mode...
-works as described for each situation
-when Ignore Time Scale is toggled, the sounds from readout will re-play rapidly to catch up with current readout position, but continue from then as described for situation

So it looks like it's mostly a quirk of sorts, from Ignore Time Scale. Ideally, I think it should pause readout (as when Ignore Time Scale is false) when it's an editor pause, but regard to the Time Scale reference otherwise. As it's not a major bug, it's low priority and entirely optional.

However, another quirk I've noticed is when pausing, switching tasks, then returning, the text renderer fails for a frame, giving a null material. This appearance is kept for the duration of the pause when Ignore Time Scale is true. When switching back and forth again, the material is restored as if unpaused. No settings or data are lost during this, so it's also low priority imo.


Thank you ! I'll consider this 'solved' but also sort of as a bug report ? Good luck ! Thanks for all your help. <3

Deleted 1 year ago
Developer

Thanks for the info! I'll give it another look, but yeah there's a couple things that are just strange editor quirks. Hopefully I can find a workaround tho, this should help!

Developer

I think it's gotta be... since it has an internal timer, when it's set to ignore time scale and you move out of the window, the internal timer counts up based on the delta time, the last time since the previous frame. So it keeps counting, even when the window is in the background (and the app is set to not run in the background)

This isn't the intended behaviour of ignore time scale (its for animated effects on pause menus, really) so I should either change the way STM counts up time (Use Time.time - timestarted) or make a special bool that checks whether the window is focused or not. The first option wouldn't be the best, since meshes can have variable read speeds, so I'll try the second.


Yep, got it working!! This fix will be in v1.5.2. Thanks!

Could not actually find ignore time scale and remember read position. Can you tell me where you got this info and how to find it? :(

I'm having a problem here when pausing the game, but the music isn't pausing at all.

https://teamtwa.itch.io/monsterbeats

Developer (1 edit)

When your mesh's "read delay" is set to a value higher than 0, the timing-related options will appear in STM's inspector. So a boolean option for remember read position and ignore time scale will appear. (If you don't want the mesh to actually read-out, despite following these options, set the read mode to "all at once" and the animation to "Appear")


Also, what do you mean by "music"...? The text reading sound made by STM, or your game's background music...?

Background music, matching with the beat scroller.

Developer

Does this have to do with Super Text Mesh...? I'm confused... Did the "ignore time scale" and "remember read position" booleans work for you?

...WebGL may actually have something to do with music; it functions differently than EXE.


Whenever I pause the game, the music pauses as well, but in the WebGL, it secretly goes out of sync and rapidly fast before I unpause it and ended up out of sync.

Developer

Are you talking about the background music in your game, or something related to Super Text Mesh...?

Background music.

Developer

This is the Super Text Mesh support forum, so if something is wrong with your game's background music and it's unrelated to Super Text Mesh, I've become a bit too busy to be able to help, sorry!