ScratchData LogoScratchData
Back to zetermadsen's profile

Slider

ZEzetermadsen•Created December 16, 2020
Slider
0
0
3 views
View on Scratch

Instructions

Something that I made so I can use it in a future project. Basically is the slider variable but made bigger and customizeable. Simply set the maximum for the slider and the minimum and it will calculate based on the size of the slider. It does take ten seconds or so for it to figure out the scaling, but you can change the bar sprite's length, center, or size as you wish. The center is the x position, and the Y position is set to 0, you can change it in the code if you want to.

Description

To figure out the value, I used the linear equation (y2-y1) / (x2-x1). In this case it is (maximum-minimum) / (rightEdge - leftEdge).

Project Details

Project ID465030093
CreatedDecember 16, 2020
Last ModifiedDecember 24, 2020
SharedDecember 17, 2020
Visibilityvisible
CommentsAllowed