Odie / skyui-vr

SkyUI interface mod for SkyrimVR
MIT License
160 stars 27 forks source link

Another line on Shout description window for moving translations to #16

Closed Shizof closed 6 years ago

Shizof commented 6 years ago

Not an issue, just a request.

In this mod: https://www.nexusmods.com/skyrimspecialedition/mods/18572 I added pronunciations of shouts and put the translations in parenthesis. It would be better if there was another line for the translations so they won't be so cluttered together.

Something like this: https://i.imgur.com/FW4TFt0.jpg

If it automatically splits the text to the other line if it has "|" (pipe) for example, it would be nice.

Odie commented 6 years ago

Wow, looks like you already a working mod! So, are you mostly looking to have slightly better looking layout?

I’m away from the computer for a bit so I can’t try things out directly ATM. I think the first thing I’d try is to insert a newline character between the pronouciation and the translated text. Assuming the texfield text alignment is already “centered” and multiline is enabled, this will probably just work. Hopefully, all the text would be lined up automatically, and we won’t have to add more code to tweak the alignment at runtime.

Some slight adjustment will likely be needed so the 2nd line isn’t overlapping other UI elements.

Shizof commented 6 years ago

Yeah I made that mod 2 months ago, but it felt incomplete and I didn't know it's possible to edit the ui that way until you came and started doing ui work. Inserting a new line character would probably be enough. If there are two spaces, the split would need to be on the last one.

Odie commented 6 years ago

I tried this out.

Screenshot

The dragonscript label (top label) had its font size reduced. The bottom label was moved up slightly. But there still isn't much room for a 3rd row. Also, the bottom label is just barely legible on a Vive pro. It's likely completely unreadable on lower resolution headsets. This just means the bottom label needs to be made significantly larger to be usable in VR.

So, I think there are few different options to try fixing this:

  1. Change the size of the item card There is room in the overall layout. Moving the 3D magic model up a bit will allow the item card to be much larger.

  2. Move the title of the item card up to make room for more content As can be seen from the screenshot, there is a large top margin. I don't know how much of that space we can use until the layout looks broken or crowded. Going this route avoids impacting the the overall layout for the entire magic menu.

  3. Don't display the dragonscript at all As far as I can tell, the dragonscript is actually useful other than to bring some flavor to the game & menu. It is, however, taking up a large amount of space in the itemcard layout. It was larger than the label displaying the shout name and almost as much vertical space as the entirety of the effect description. So, if the actual pronunciation of the shout is important to you, maybe the right thing to do is to simply to not show it at all.

Screenshot 2

Well, let me know what you think.

Shizof commented 6 years ago

Wow that was fast. It's true that dragonscript doesn't have any use and definitely 3rd choice is the way to go if no other option is available, but if the second one is possible I'd prefer not losing it just yet. If the title actually can be over the rectangle, that'll leave all the space there.

Odie commented 6 years ago

Okay... I'll try to get to this tomorrow.

Odie commented 6 years ago

Btw, what do you think about having the dragon text fade out and replaced by the pronunciation after a short delay?

Shizof commented 6 years ago

Cool idea indeed.

Odie commented 6 years ago

Want to give this a go and see how you like it? This one has a 1.5 second delay, before the dragonscript is faded out and replaced by its pronunciation. The fade in/out is done over 0.5s.

SkyUI - VR - dragon pronunciation.zip

There is just a single updated itemcard.swf in there.

Shizof commented 6 years ago

It's very good! I'll make a new version of my mod so this works better.( Not really necessary anymore but I'll change stuff like R1n to Raan and N7 to Nir) You used "Full Name" I'm guessing right?

Odie commented 6 years ago

I’m not sure what you mean by “full name”. It’s just displaying whatever the content was, using the normal font instead of dragon script. =)

Odie commented 6 years ago

from Shizof on discord:

String replace is the way to go(edited)
Numbers are going to be replaced with the corresponding strings:(edited)
1: aa
2: ei
3: ii
4: ah
6: ur
7: ir
8: oo
9: ey
this is it
it works for dlcs and thunderchild shouts as well
only thing is if these numbers come as the first letters you need to capitalize the first letters.
for example 3z = Iiz and 4 = Ah
Other than that it's normal replace. D4 = Dah
Odie commented 6 years ago

Here's a version that implements the discussed string replacement. Seems to work okay. =)

SkyUI - VR - dragon pronunciation - 2.zip

Shizof commented 6 years ago

Yes. It works very well. Awesome job!

Odie commented 6 years ago

Great. This will go out with the next version then. I hope people won't be too disturbed by this unexpected addition.

Implemented by d4fed7c81a8e7794b53b1621378b580745704250