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

How do I use TimeLength for sound(s) in wait?

Asked by 9 years ago

I am trying to use this:

wait(theAudio.TimeLength); -- theAudio is a variable that is already defined.

This portion of the script doesn't work. I know it doesn't work b/c when I remove it, the script suddenly works as intended.

Thoughts? How can I use TimeLength in wait()?

1
TimeLength I believe is a "read-only" Property. rexbit 707 — 9y
0
What? What does that mean? I can't set wait to the TimeLength of a song? Arithmeticity 167 — 9y
1
@PerfectAnxiety | Read-only properties can be stored in a variable. "Read-only" means the property itself cannot be redefined. Thus, wait(theAudio.TimeLength) is totally acceptable in this situation. Redbullusa 1580 — 9y
1
We may need you to post the whole script to answer this question, though. Redbullusa 1580 — 9y
View all comments (3 more)
0
Oh god, I think it just worked. I just didn't test it online or I must have not tested it deeply, thanks guys!!!! Arithmeticity 167 — 9y
0
This property only works in side localscripts as I know.. I tried scripts and they keep returning weird results.. Nickoakz 231 — 9y
0
I used a local script and it worked! Arithmeticity 167 — 9y

Answer this question