#Dialouge problems

1 messages · Page 1 of 1 (latest)

hearty condor
#

whenever the DialougeRenderer module does it job, since it only does only validate TextSize, but never with TextScaled, it would be obvious on what would happen. It won't adapt to the scale of the current size of the textlabel / parent / dialougebox.

and im confused on how to fix this . the main issue is with the TextService

#
local function getCharBounds(char, textSize, font, frameSize)
    return TextService:GetTextSize(char, textSize, font, frameSize)
end
#

heres what i should look like normally

#

vs when the device is more tinier than PC screens.

humble coral
humble coral
#

i dont think you can, you're going to have to write your own scaling

hearty condor
#

Since TextService is dependant on the TextSize in my case, that's the only solution that might work out for me but im not sure

humble coral
#

set textsize according to the size of the textbox

#

you could factor in text length too

hearty condor
#

Ill check it out, ill go play other games that has done the same dialouge things and find out if this isnt just a issue with me

#

Found out it's an issue everywhere thank god

leaden gull
#

indeed

hearty condor
#

Ill probably have to check out DevForums to find out on how to fix this

humble coral
hearty condor
#

does work when the screen size is small

humble coral
#

i didnt say to use it, i said it has something for text scaling in it. aka read the source code for it and take how they replace .TextScaled

hearty condor
#

oh

#

i see

#

alright

humble coral
#

i'm assuming it has something for it, it might be lazy tho

#

https://devforum.roblox.com/t/calculate-textscaled-size/378577/7

Doing this calculation yourself like that isn’t ideal because it means that every dialog will have a different font size, which results in poor UX. In addition, you’ll still have cases where if a dialog message is too long the resulting text will be unreadably small.

You should pick a font size you know will fit every message you’ll display - either a static size in pixels, or setting the font size based on the height of your dialog bubble using a script. In the future we might add more ways of setting the text size, but until then you have to use scripts to calculate it.
~ Roblox Staff

hearty condor
#

I found out in AutoScale Lite they used an UITextSizeConstraint

humble coral
hearty condor
#

yeah, they do automatically set it, in Default it would be 100

harsh spindle
#

damn almost 400 lines for dialogue 💀

hearty condor
#

it would be simple if it was just a type-writer effect

harsh spindle
hearty condor
#

i am

#

the issue isn't that

harsh spindle
#

hm damn, you must have a lot of effects then

hearty condor
#

its TextService from what i know so far

humble coral
#

only reason its not 1000 is probably coz it not finished and battle-tested yet

hearty condor
#

I wouldn't have any issues if it was just like InkGames where it can set the TextSize automatically (I asumme), but never change it once the screen resolution changes again untill the next line

#

But i don't know how they did that so that's what im just trying to figure out

humble coral
hearty condor
humble coral
#

invisible textbox hehe

harsh spindle
hearty condor
#

if ts fixes it im gonna jump

#

💔

harsh spindle
#

lowkey I don't even know what your problem is but good luck

hearty condor
#

and see how the text never scales

harsh spindle
#

oh you mean how it doesn't fit inside the textbox thingy

harsh spindle
# hearty condor yeah

you could like figure out how much one letter takes up then multiply by the number of letters but there's probably a smarter way to do it

harsh spindle
hearty condor
harsh spindle
leaden gull
#

hello there.

finite geyserBOT
#

studio** You are now Level 1! **studio

harsh spindle
hearty condor
#

hello realsword

leaden gull
#

especially for effects like shaking

harsh spindle
hearty condor
#

and not a type-writer effect

#

its a letter by letter textlabel calculated by TextService's GetTextSize which relies on TextSize (Will never change even with TextScaled on btw)

#

so im confused on how Ink Games did it

harsh spindle
hearty condor
#

So even if you have TextScaled On

#

it will Get the TextSize instead

harsh spindle
#

@hearty condor I found a forum page that talks about your exact problem

#

and this guy is changing the size based on the amount of letters like I suggested. so that's probably the idea here.

hearty condor
#

My problem is Scaling the Text

harsh spindle
hearty condor
#

I see, Some people used Frames as a reference of how the Text should be

hearty condor
#

i just had to divide the absolutesize.Y of the label by 2 (or any that i want)

#

💔

#

and that fixed the issue

#

crazy right?