Worked in AS2 not in AS3!
May 18, 2017
Hello,
I spent a long time trying to figure out how to add a key press trigger to an object and use the mouse when needed in a game I created. It worked flawlessly and now since I upgraded to AS3 I am no longer able to use those triggers unless I click on the object first, then hit the key. This won't work for the game. Did Articulate change anything that wouldn't allow you to attach key triggers to objects? I can't show the story file because my company owns it, but can give you a snippet of how I did it.
Change state of CAR1 to Hidden when user presses the UP arrow.
Change state of CAR2 to Normal when user presses the UP arrow.
and so forth
In order to get the mouse to work as well I created another slide and used it as a lightbox. If the screen was clicked the lightbox was activated and immediately closed. This is similar to clicking the screen to reactivate. The slide would jump back to what you were on seamlessly (the lightbox isn't seen or a millisecond viewed).
Any insight would be appreciated!
15 Replies
Actually here is a cleaned up version I could share. Works in AS2, not AS3 anymore unless you click the object and hit the key. No collision detection has been added yet. This was one of the main reasons I wanted to upgrade to AS3.
Sorry for the multiple messages, but I know this is NOT how Storyline works, but it was a work around that was needed for this type of game because of answering questions and using your mouse and keyboard at the same time.
Hey Brian! Do you have the copy that works in SL2 as that would certainly assist as well to see the comparison? If you cannot share here in the forums, you can share here privately.
The same version was used on both so no coding was different. Not sure if that helps you. Thanks.
Brian E.W. McNulty
Accenture Federal Services
Instructional Design Associate Manager
14850 Conference Center Drive
Chantilly, Virginia 20151
Office: 1-703-457-2462[X]
Mobile: 571-234-3523
brian.mcnulty@accenturefederal.com
The story file is attached above.
Hi Brian - Looks like you responded via e-mail and that does not allow attachments to come through, but does include your signature. You are welcome to pop in and edit that if needed. Here is a quick Peek video here if you need help.
I cannot open the file you shared previously in SL2 to see it working and in action, so that's what I was hoping to see.
Sorry, here is an SL2 version of the story file. The main file I am working with incorporates up, down, left and right movements with the key. Thanks.
Thanks Brian - I was able to see that working as expected in SL2 and then not working in SL3 as you described.
I've opened a case (01077139) on your behalf with our support engineering team to take a closer look. You should be hearing from someone soon and I'll follow along as well.
I've experienced a similar issue with a game I'm developing in SL3. My character is moved using the arrows keys, but I first have to click on him to get him to move at all.
Thanks Michael - I'll update here when I have an update on Brian's case.
If you wish to work directly with our support engineers, you can reach them here as well.
Hello Michael - Looks like the issue that Brian shared above has been escalated to our QA Team to take a closer look.
This article explains how we tackle these bugs.
I'm adding this thread to the report so that we can fully track user impact and so that we can update here as well when applicable.
Hi Leslie,
I was wondering if there was an update with the issues of using keyboard key triggers with SL3. Thank you.
I have been looking at this behavior as I ran into something similar. It looks as if the focus is not initially on the screen as in SL2, seems to be a focus issue.
I tried several things to try to get the focus on the screen (invisible hotspot over full screen with a dummy action on hover, which thus triggers when the screen loads) , nothing seemed to work.
The only workaround I can see right now is JavaScript which if you want to go that route, Matthew Bibby is well versed in and has examples of in this forum. Example below could be harvested for your purpose, but yes it takes JavaScript.
https://community.articulate.com/discussions/articulate-storyline/freeform-shortcut-key-how-to-use-tab#reply-432555
Hello,
So you are telling me Articulate won't fix an issue that is sold as a feature to work? If it worked in the previous version, it should still work and I spent a lot of time as other have making the triggers work in numerous games and interactivity. Please let me know if you will continue investigating the issue in order to fix it and a timeframe to do so. Thank you.
Hi Brian,
The issue is reported and with our team for further investigation. In the meantime, you could use the steps that Matthew created in Javascript or instruct users about the need to click on the slide to capture the focus (that one is probably less than ideal).
I’ll let you know as soon as we have an update on this issue. Thanks so much again for letting us know about this, and I’m sorry if it’s slowing you down.
This discussion is closed. You can start a new discussion or contact Articulate Support.