Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » Changing size after character lenght?
- TobiNSpiller
-
Scratcher
40 posts
Changing size after character lenght?
How do you make sprites smaller for the longer amount of characters there is in a variable?
Last edited by TobiNSpiller (June 15, 2018 21:26:42)
- best-games-ever
-
Scratcher
500+ posts
Changing size after character lenght?
I think that can't happen with variables, you probably have to use lists.
- crisostimo
-
Scratcher
500+ posts
Changing size after character lenght?
Depends on what you are looking for, but something along the lines of:
set size to ((100) / (length of (My Variable))) %
- TobiNSpiller
-
Scratcher
40 posts
Changing size after character lenght?
Depends on what you are looking for, but something along the lines of:Yeah, it looks right besides it doesn't scale it exactly how I want it. It get's too small when the amount of characters gets longer.set size to ((100) / (length of (My Variable))) %
- deck26
-
Scratcher
1000+ posts
Changing size after character lenght?
So work out approximate sizes for different lengths and see if you can establish a relationship. Or use the equation above but add a constant so you have a mimum size.Depends on what you are looking for, but something along the lines of:Yeah, it looks right besides it doesn't scale it exactly how I want it. It get's too small when the amount of characters gets longer.set size to ((100) / (length of (My Variable))) %
For example.
set size to ([20] + ((80) / (length of (My Variable))) %
- cc_scratch_cc
-
Teacher
24 posts
Changing size after character lenght?
may you need
set size = 100% / sqrt(objAmount)
set size = 100% / sqrt(objAmount)
set size to ((100) / ([sqrt] of (amount))) %
- Discussion Forums
- » Help with Scripts
-
» Changing size after character lenght?