datiswous Posted January 16, 2024 Report Posted January 16, 2024 (edited) 47 minutes ago, stgatilov said: I think it should be reloadDecls... Rather logical since subtitles are decl files. This doesn't work. But reloadXData does work. This doesn't make sense to me though, Tested with srt and inline. Edited January 16, 2024 by datiswous 2 Quote
Geep Posted January 18, 2024 Author Report Posted January 18, 2024 Quote subtitles are decl files There's nothing about .subs or .srt files that says to me: these are decl files. So reloadDecls and reloadXData are equally arbitrary. On the other hand, "reloadSubtitles", yeah, that I would understand. Quote
stgatilov Posted January 20, 2024 Report Posted January 20, 2024 On 1/18/2024 at 3:45 AM, Geep said: There's nothing about .subs or .srt files that says to me: these are decl files. So reloadDecls and reloadXData are equally arbitrary. On the other hand, "reloadSubtitles", yeah, that I would understand. How do you determine what is decl file and what is not? Actually, xdata is decl files too. You can equally argue that materials and sound shaders are not decl files and deserve a separate reload command. I guess ID guys did not want dozen of separate commands for different kind of decls. Quote
stgatilov Posted January 20, 2024 Report Posted January 20, 2024 On 1/17/2024 at 12:04 AM, datiswous said: This doesn't work. But reloadXData does work. This doesn't make sense to me though, Tested with srt and inline. I tested editing inline subtitle in tdm_stlucia.subs. That's a core file and I test on SVN, so all core assets are unpacked. It works. I edited it before triggering the sound, and then triggering it showed me the new subtitle text. I also checked in the code. Whenever some .subs file is detected as modified, all the subtitles are reloaded completely. What setup do you have specifically? Quote
datiswous Posted January 20, 2024 Report Posted January 20, 2024 3 hours ago, stgatilov said: It works. Ok, but with which command? Quote
stgatilov Posted January 20, 2024 Report Posted January 20, 2024 1 hour ago, datiswous said: Ok, but with which command? reloadDecls Quote
Geep Posted January 20, 2024 Author Report Posted January 20, 2024 6 hours ago, stgatilov said: I tested editing inline subtitle in tdm_stlucia.subs. That's a core file and I test on SVN, so all core assets are unpacked. Be interesting to know if reloadDecls works on an edited core .subs but not on an edited FM-specific .subs Quote
datiswous Posted January 22, 2024 Report Posted January 22, 2024 (edited) On 1/20/2024 at 10:28 AM, stgatilov said: I tested editing inline subtitle in tdm_stlucia.subs. That's a core file and I test on SVN, so all core assets are unpacked. It works. I edited it before triggering the sound, and then triggering it showed me the new subtitle text. Does that work with reloadXData as well? I didn't test with core files. I tested with fm's subtitles. I tested with a subtitle I made (and is now included in fm) for WS5. At the start of the mission you walk for a bit and you get a monologue of some drunk guy containing multiple (sound+)srt files. Later I tested inline on Braeden Church. Btw. do you think these sound files might be used by other missions? Otherwise I would move them to the fm folder including the subtitles. //Note: These sounds are mostly specific to Saint Lucia mission. //But for some reason, they are located in core, so better define their subtitles here. subtitles tdm_stlucia { verbosity story inline "sound/voices/builders/builder1/conversations/builder1_conv_4.ogg" "It is not for me to question Brother Renald, but it does seem that there is naught but rats and beggars to guard against." inline "sound/voices/builders/builder1/conversations/builder1_conv_3.ogg" "As you say. Though the Lord Builder is known to work in ways most mysterious." inline "sound/voices/builders/builder2/conversations/builder2_conv_3.ogg" "Indeed. It is not our place to question. Our obedience doth honor Him." inline "sound/voices/builders/builder1/conversations/builder1_conv_1.ogg" "How much longer must we guard this accursed place?" inline "sound/voices/builders/builder2/conversations/builder2_conv_1.ogg" "The archbishop doth come two days hence." inline "sound/voices/builders/builder1/conversations/builder1_conv_2.ogg" "I should be ashamed to have His Eminence in such a place as this." inline "sound/voices/builders/builder2/conversations/builder2_conv_2.ogg" "It is hard to imagine a true miracle doth take place here." } Edit: I think it's simply possible to do a search in all fm's to see if these files are used outside of Saint Lucia. Edited January 22, 2024 by datiswous Quote
Geep Posted January 22, 2024 Author Report Posted January 22, 2024 5 hours ago, datiswous said: Btw. do you think these sound files might be used by other missions? Otherwise I would move them to the fm folder including the subtitles. I think moving them to the FM-specific folder would be the right thing to do. Quote
Geep Posted January 22, 2024 Author Report Posted January 22, 2024 @stgatilov, I've been looking into the stray marks associated with Stone 12 pt. Not much progress, because there's something strange going on. Any change I make to the metadata in fonts/english/stone/fontimage_12.dat (whether in the core or as an FM "/fonts/" override) is ignored. Whereas changes to the corresponding 24 pt .dat (whether in core or override) do show up in the nominally 12 pt subtitles (with either gui textscale of 0.24 or 0.25). Is there something in the engine code that is keeping this 12 pt .dat from being used? There are no warning about such at startup. Perhaps some engine hack left over from when there was a missing file? Quote
snatcher Posted January 22, 2024 Report Posted January 22, 2024 I am overwhelmed by the amount of non-story subs that can be on screen after beta212-04. I am not sure yet what the next step is. Quote
MirceaKitsune Posted January 22, 2024 Report Posted January 22, 2024 It sucks that I've already finished every FM especially recent ones: I really need to find something to replay so I can properly try this out now that it's in at last Quote Mods: Builder Blocks minigame | Keypad | Disguises
snatcher Posted January 22, 2024 Report Posted January 22, 2024 (edited) Whoopsie @MirceaKitsune First thoughts: The moment a sub makes it in, it stays. We cannot have subs popping in and out of existence in a split sec. If we miss some in the queue, so be it. Non-story subs must have a way shorter distance over story subs. Story must prevail. If there ever is a need for a slot, a non-story sub gives place to story (this is the only exception to point one). Edited January 22, 2024 by snatcher Quote
snatcher Posted January 22, 2024 Report Posted January 22, 2024 (edited) Let's re-do this. Story always has the preference, even if the player is or goes far away from the source. The moment a story line is triggered the whole set is displayed in sequence not matter what (subs keep their slots). If there are no slots available, a bark goes away. If more than three story subtitle require a slot, then we are f***d the oldest story sub goes away. Non-story subs cannot be displayed if the player was far away when they started: we cannot have subs popping in and out of existence in a split sec. However, the moment a sub makes it in because the player was nearby the source, it stays, even if the player goes away. If we miss some non-story subs in the queue because ongoing subs didn't end yet, so be it. Non-story subs must have a way shorter distance than story subs. Edited January 22, 2024 by snatcher Quote
snatcher Posted January 22, 2024 Report Posted January 22, 2024 I am starting to think that can go away with this with simply two slots, instead of there. Quality over quantity. Quote
Geep Posted January 23, 2024 Author Report Posted January 23, 2024 18 hours ago, snatcher said: The moment a story line is triggered the whole set is displayed in sequence not matter what (subs keep their slots). I think this is probably "it depends". If a single AI is giving a story monologue, it may be implemented as a single .ogg file, just broken up into subtitles. So this would all be in the same slot. (Likewise, there are some long barks in a single .ogg file too). But the story could be in multiple .ogg files, delivered by one or several AI. Then, the slot could vary, if there also barks happening that scrambled things up. I could be wrong about this. I recall there was some chatter a long while ago about making what slot an particular AI uses somewhat sticky. 18 hours ago, snatcher said: Non-story subs must have a way shorter distance than story subs. That's interesting, about volume (or distance) threshold triggering of subtitle display. I'm guessing no threshold test is applied for story subs. Quote
MirceaKitsune Posted January 23, 2024 Report Posted January 23, 2024 Got to try it out with an older FM: Very nice stuff to see! Looks good for the most part: If anything I think there are a few issues with certain punctuation making sense... other than that, only change I'd like to see is a more stylized dialog box instead of a flat background, still black and transparent and subtle but better themed and maybe using a more appropriate font. 1 Quote Mods: Builder Blocks minigame | Keypad | Disguises
snatcher Posted January 23, 2024 Report Posted January 23, 2024 Time ago it was discussed here about Hearing Impaired and Hearing Unimpaired modes. Nothing was decided back then and now we have everything. This actually turned to be a good move because code-wise we now have lots of tools at our disposal but, in my opinion, by firing everything at all players we may end up alienating many / most. I want the average player - interested in subtitles - to keep subs enabled and have a good time enjoying the good work done here and elsewhere and I keep working on an alternative: Alt Subtitles for 2.12 v0.1 Background replaced with a (fake) font outline Widget removed (too many things to focus on) Text transparency based on distance (imperfect) Story subs can take up to three slots Barks limited to a single instance Yellow color for story subs (intensity reduced a little from previous attempts) Light grey color for barks It is far from perfect but it may lead to other ideas. Download the pk4 attached to this post and move it to your root folder. I suggest taking the Braeden Church mission for a spin. Delete the pk4 once testing is complete. z_alt_subtitles_v0.1.pk4 Quote
stgatilov Posted January 24, 2024 Report Posted January 24, 2024 On 1/22/2024 at 10:42 PM, Geep said: Any change I make to the metadata in fonts/english/stone/fontimage_12.dat (whether in the core or as an FM "/fonts/" override) is ignored. Whereas changes to the corresponding 24 pt .dat (whether in core or override) do show up in the nominally 12 pt subtitles (with either gui textscale of 0.24 or 0.25). I think engine selects texture size depending on font size. Try to lower scale 2x, maybe then it will pick up the _12 version. Quote
stgatilov Posted January 24, 2024 Report Posted January 24, 2024 On 1/22/2024 at 11:07 PM, snatcher said: I am overwhelmed by the amount of non-story subs that can be on screen after beta212-04. I am not sure yet what the next step is. People who don't like them can disable them and leave only Story subtitles On. I think we should move all the "(sign)" and "(clear throat)" to Effect level and add one more level to the menu. I definitely don't need to see them on my screen. Finally, some volume cutoff is needed I think. The problem with implementing it right now is that the engine does not determine effective volume. If you look at alpha of location ring (which is volume based), it is very different in the New Job conversation (about girls behind inn). I hope to fix this in some future... Quote
snatcher Posted January 24, 2024 Report Posted January 24, 2024 10 minutes ago, stgatilov said: Finally, some volume cutoff is needed I think. The problem with implementing it right now is that the engine does not determine effective volume. I don't understand this bit, but then I know nothing about how sounds/audio are processed internally. Based on the audio alone (listening) I would say the engine knows how far I am from a sound source (or the other way around) and sets the volume accordingly. The engine also knows if I am behind a closed door or not. I don't know, it would seem all is there already. Quote
stgatilov Posted January 24, 2024 Report Posted January 24, 2024 1 hour ago, snatcher said: I don't understand this bit, but then I know nothing about how sounds/audio are processed internally. Based on the audio alone (listening) I would say the engine knows how far I am from a sound source (or the other way around) and sets the volume accordingly. The engine also knows if I am behind a closed door or not. I don't know, it would seem all is there already. Now the subtitles use volume modifier, it's called "gain". This gain is passed to OpenAL along with .ogg file data to play. In order to determine how loud that would play, it is necessary to read the .ogg data, compute some kind of amplitude, then add gain to it. The amplitude should be computed with some pretty long time window, so it's better be accumulated continuously. Quote
snatcher Posted January 24, 2024 Report Posted January 24, 2024 Thank you. I have more questions but I would be wasting your time. I will have a look at the source code someday. Quote
Geep Posted January 25, 2024 Author Report Posted January 25, 2024 On 1/23/2024 at 12:58 PM, MirceaKitsune said: maybe using a more appropriate font At least for bark subtitles, fast readability is important, because they shouldn't be on the screen much beyond the vocalization time, and for fast talkers, that's not real long. Of the existing fonts available, Carleton and Stone are the easiest to read quickly at a glance. If you were going to allow a different font for story subs, assuming they are generally articulated at a more leisurely pace, then you could consider a more "themed" font. Still, a lot of TDM fonts are pretty slow to scan/parse. Quote
datiswous Posted January 25, 2024 Report Posted January 25, 2024 I was testing some missions with all the ai barks on and the issue I see is that for a lot of the subs I see on screen I can't hear the sound. Maybe I should only hear the sounds in a specific radius? Also, I think ai barks shouldn't show when story subs are on screen? Some subs have sugestive text, like what the tone of the voice is. Is that something that could be added as an option? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.