Construct Time #8: Better Slider Bars

5

Attached Files

The following files have been attached to this tutorial:

.c3p

betterslider.c3p

Download now 66.01 KB
.c3p

betterslider.c3p

Download now 65.97 KB

Stats

1,650 visits, 2,088 views

Tools

Translations

This tutorial hasn't been translated.

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Published on 29 Oct, 2020. Last updated 19 Apr, 2021

Hi everyone! This time I come with a brand new kind of thing. A fully fledged JS module!

There's not too much to explain, and I'm gonna be honest, it's pretty late right now and I'm too tired to write detailed explanations.

So instead, here's a cool gif

Basically, this is a slider that shows the value, allows you to fully customise its appearance using Sprite, Tiled Backgrounds or 9Patches. It has support for mouse, touch and mouse wheel to change the value, and you can double click to open a text input. You can also clamp values so they never leave the minimum and maximum values of the slider, or you can decide to let the value be as high as the user wants.

But most important of all: It requires 0 events to set up. In that gif, I have a single event for the rainbow effect, and that's it. Everything else is set up on the Slider object, on the other objects you'll need to set up, or is handled automatically by the JS module.

To Install

You'll need to copy the BetterSlider script in your project. You'll also need to copy the objects in the "COPY THOSE" layout, and paste them inside your project.

After that, you can use and place your BetterSlider object wherever you need (you only need that object placed in the layout). You can use all of the Slider ACEs and they should work fine. You can also change the instance variable at any point, including the object names!

Classic Script Mode

.C3P

betterslider.c3p

Download now 66.01 KB

Modules Script Mode

.C3P

betterslider.c3p

Download now 65.97 KB

Next Tutorial In Course

Construct Time #9: Mesh trails for Construct 02:38

Mesh trails, good trails, fast trails

  • 5 Comments

  • Order by
Want to leave a comment? Login or Register an account!