Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do you fix text not showing up in TextBox?

Asked by 5 years ago
Edited 5 years ago

So I'm making a GUI that shows some cool geeky information like their account age for example. But I've fell into yet another pit. Here's the script:

01local plr = game.Players.LocalPlayer or game.Players.PlayerAdded:Wait()
02local char = plr.Character or plr.CharacterAdded:Wait()
03local plrname = char.Name
04local plrageraw = plr.AccountAge / 365
05local plrid = plr.UserId
06 
07 
08local plragebox = script.Parent.UserAge
09local plridbox = script.Parent.UserID
10local plrsessionbox = script.Parent.UserSessionTime
11 
12function PlayerAge()
13    local updated = 0
14    local us = "Info has updated"
15    local ss = "during this session."
View all 72 lines...

Explorer

GUI in-game in Studio

Output

So I can't find out what's wrong with the "Session" part. There's no error in the output and I've looked over it and it appears to be normal. The other two parts of the GUI works just fine. I might be missing something but like I said, it appears to be normal. I am a bit new at coding in Lua. I've tried putting the local variables [sec, min, hr] outside the function, but I expected it not to work and of course, it didn't work.

Thanks in advance! :)

0
You have while true do in your PlayerAge() function so your PlayerSession() was never activated. 9mze 193 — 5y

Answer this question