Our next free workshop event will be announced very soon! Explore Our Online Training Courses and Master Classes!

Drag The Lantern Illumination Effect In Articulate Storyline 360!

A Global Illumination and Gravity Effect Experiment for Articulate Storyline!

The special effects showcased in this demo were not built with Storyline’s own inbuilt features but are instead all JavaScript-based. I think it’s great to see more and more developers taking advantage of the Execute JavaScript trigger in Storyline these days to accomplish new and inventive ways for users to engage with their content!

The lighting effect is accomplished via a script that determines the proximity of the lantern object to any of the letters shown on screen, increasing the brightness as it moves closer to the centre of each letter. Each letter is actually written as its own text box in Storyline! This setup makes the global illumination effect possible, as each letter has its own calculated brightness value at any time.

You might also notice a flicker effect when the lantern is left idle! We can achieve this by scripting a maximum brightness value that changes randomly every 4 seconds, ramping up or down to that value over a short interval, which makes the lantern effect appear more realistic.

Finally, there’s the gravity effect on the lantern itself as it’s clicked and dragged. This is achieved through GSAP, a JavaScript-based animation library that I feel is greatly underutilised and underreported in Articulate Storyline, despite all the wonderful things it’s capable of within a Storyline project.

One of the coolest things about building animation sequences in GSAP is that we can incorporate the full range of event listener protocols available in JavaScript. So, as specific events occur (e.g., mouse down, mouse movement, and mouse up), we can set in motion various actions to create specific animations within the scene.

Whenever the mouse is in motion, and the click is held down, our script tracks the changes and calculates a counter-rotation value for the lantern, creating the fluid gravity effect you’ll see as you move the lantern across the scene.

I’ll note, however, that something odd happens on iOS: the effect works as expected but only after the lantern has been tapped or moved at least once. I’m not sure why this occurs, and I hope it’s a bug that might be ironed out at some point down the road.

For more sinister scares, be sure to check out my entry to last year’s Halloween-themed eLearning challenge, which I still claim is the scariest eLearning activity ever created! Let me know if you agree!

Happy Halloween everyone! 🎃

Learn how to build interactive content like this yourself in Storyline in just 2 days!

Join our next Advanced-level Articulate Storyline 360 workshop (In-person or Virtual).

Related Articulate Storyline 360 Innovations

Year

2024

Methodology

  • Articulate Storyline 360
  • GSAP
  • CSS and JavaScript

Further Info

The idea for this Halloween-themed Storyline demo was inspired by the work of Rive creator Bartek Radziejewski.

Recreate this effect in Storyline using our free project file: LINK

Inspiration

Rive
Halloween
ELH Challenges

Schedule a meeting

Why not book a consultation call with us? We’re here to assist you with any questions or concerns you may have.

Please note: All bookings are subject to confirmation. We reserve the right to reschedule based on availability.