of     1   

spinywind
#182297733Sunday, January 24, 2016 9:36 AM GMT

Iv tried many methods but i cant get it to work. Like i said earlier on the forums, im new to scripting its hard for me to understand, i understand this and what it does but its hard for me to apply it to anything and im trying to learn, anyways heres the script and the problem So when i divide to values onto a text, depending on what u divide, there are so many digits as a decimal like 6.432467654312432552, is there a way to make it so only 3 digits are shown like this 4.52? Heres my script: Kills = script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats.Kills.Value Deaths = script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats.Deaths.Value while true do script.Parent.Text = ""..string.format("%.2f",tostring(Kills/Deaths)"); wait() end
Moronism
#182297921Sunday, January 24, 2016 9:43 AM GMT

It would seem that I added an unnecessary quotation mark near the end of the script segment I provided you with. This would be the correct version: "script.Parent.Text = ""..string.format("%.2f",tostring(Kills/Deaths));" For further reference, it would likely be an excellent idea to discuss any necessary adjustments within a single thread. That will ensure that the discussion can remain progressively organized to efficiently assist you.
spinywind
#182298250Sunday, January 24, 2016 9:56 AM GMT

it still did not work
Moronism
#182298274Sunday, January 24, 2016 9:57 AM GMT

"it still did not work" Could you describe your error to me please?
spinywind
#182298386Sunday, January 24, 2016 10:02 AM GMT

so it just says label which is the default text. So its not even dividing the Kills by deaths, something must be stopping the script.
Moronism
#182298420Sunday, January 24, 2016 10:03 AM GMT

"so it just says label which is the default text. So its not even dividing the Kills by deaths, something must be stopping the script" When you used my example, did you remove the quotation marks it was enclosed within?
spinywind
#182298475Sunday, January 24, 2016 10:06 AM GMT

yes i removed them
Moronism
#182298609Sunday, January 24, 2016 10:12 AM GMT

Hmm. Your problem intrigues me. Did you notice any errors within the output?
spinywind
#182298655Sunday, January 24, 2016 10:15 AM GMT

Oh there we go i fixed it, there was one error and i knew how to fix it (somehow). Ty for the help a lot i appreciate it
seanb117
#182299124Sunday, January 24, 2016 10:36 AM GMT

Kills = script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats.Kills Deaths = script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats.Deaths while true do script.Parent.Text = ""..string.format("%.2f",tostring(Kills.Value/Deaths.Value)"); wait() end Was probably how you fixed it.
spinywind
#182299225Sunday, January 24, 2016 10:40 AM GMT

Something is wrong with it again, it doesn't divide right. When i tested i had 4 kills, 1 death an it said my kd was 1.50... any ideas
BanTech
#182300577Sunday, January 24, 2016 11:44 AM GMT

Can you post the "fixed" script you wrote?

    of     1