Selected state in quiz working randomly

Hello all,

I am building a quiz. Each question has 4 answers possible (only 1 right), and 3 states: normal, hover, selected. My answer texts are on a layer (1 layer by answer), and there's a colored shape just behind each of them, on an other layers, which have the same state (normal, hover, selected).

I've created triggers for Hover (change state of shape 1 to Hover when mouse hover over button 1), and did the same for the Selected state (change state of shape 1 to selected when user clicks on Button 1). I've also added the Normal state if any of the other answer is selected.

Everything is working approximately fine when I preview my module (as in it's working most of the time, but would bug sometime).

My main issue is after the export: the Selected state of my shapes doesn't work at all. The Hover state is working fine, but when I select any answer, the shapes state is back to Normal instead of Selected. I've tried opening the file on both Edge and chrome, the result is the same.

Any idea of what might be wrong?

10 Replies
Alyssa Gomez

Hi Audrey!

The Hover and Selected states are built-in states. That means those states will automatically display when learners hover over or click on the object. You don't need to create a trigger to invoke those states.

Try deleting the "change state of" triggers, then republish the file. Also be sure to test the published output on the web to ensure everything is working correctly. Tempshare is a handy tool you can use if you don't have a web server available. 

Crystal Horn

Thanks for replying, Audrey. It sounds like you are using a button to trigger state changes on another shape. Built-in states will work automatically on the object itself like Alyssa says, but if you're controlling them with another object, like a button, you're right to have triggers.

I'd recommend using custom states with different names, e.g. ShapeHover, ShapeSelected. If that doesn't work, I'd like to take a look at your project file to investigate what's happening with your permission. You can share it publicly here, or send it to me privately by uploading it here.  I'll delete it when I'm done troubleshooting. 

Audrey Cueva

Hi Crystal, indeed, the trigger state is for my shapes under the Radio buttons. When previewing my file today, the Selected state didn't work at all, even though I didn't change anything yesterday... I've uploaded my file with your link and it sent it through your Support team I guess?

Thank you for your help :)

Audrey Cueva

This would be my very last resort. As the quiz has been built like this by the previous designer and there's 20 questions with 4 answers each, adding triggers was quicker at that time.

If there's no other solution, this is what I might end up doing, but now I'd also like to know what is wrong with my file in case it happens again :)

Crystal Horn

Hi again! To share with the community: I had a look at the file, and my recommendation is similar to Phil's. I would do away with the shapes, and apply the state changes directly to the radio buttons since they are meant to highlight the answer choices. The radio button fields were directly on top of the rectangular shapes, and it looked like the two were interfering.

Audrey Cueva

Hi Crystal! Thank you for your mail, all your tips are very useful :)

I actually was told later the didn't go that route because of the rounded edges/corners of the built-in radio button states, whereas we needed sharp ones. So I guess my last question is: is there a way to change the corners' shapes? Or should I create a shape directly in my radio buttons?