I would like to build a slider that modifies dynamically the radius of say a circle.
The object circle is "Oval" what properties can I assign like radius, diameter, or??? I would expect to be able to mention its x,y position, color fill etc.
I'm sorry, i'm not a JS wiz so I'm not going to be able to help you out with this one beyond giving you a link to our JS best practices. Hopefully someone in the community will jump in and help you.
There are probably a number of ways you can do this. One way might be to assign states to the circle, increasing the size of the circle on each state. You could then simply write a couple of variables to control the state changes when you manipulate the slider. Alternative you could use layers and triggers. Placing a ever larger circle on a layer and set triggers to move between the layers as the slider is manipulate. Javascript is a great tool but so is Storyline, it can do almost everything you are able to imagine without Java Script, experiment and see, its easy to learn and you feel great when you start solving these problems in less time than you think.
4 Replies
Hey Dan,
I'm sorry, i'm not a JS wiz so I'm not going to be able to help you out with this one beyond giving you a link to our JS best practices. Hopefully someone in the community will jump in and help you.
There are probably a number of ways you can do this. One way might be to assign states to the circle, increasing the size of the circle on each state. You could then simply write a couple of variables to control the state changes when you manipulate the slider. Alternative you could use layers and triggers. Placing a ever larger circle on a layer and set triggers to move between the layers as the slider is manipulate. Javascript is a great tool but so is Storyline, it can do almost everything you are able to imagine without Java Script, experiment and see, its easy to learn and you feel great when you start solving these problems in less time than you think.
I may be wrong but I don't think you will be able to access/modify the properties of the oval in SL.
Joe's suggestion of creating an oval with multiple states is most likely the best solution IMO.
I've attached a basic example to show this method.
Dear All thank you for your replies and for the attention given to my topic of interest.
I wanted to create something more evolved but will simplify :)
All the best,
Dan
This post was removed by the author
This discussion is closed. You can start a new discussion or contact Articulate Support.