• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Script only runs once

Explorer ,
Apr 11, 2023 Apr 11, 2023

Copy link to clipboard

Copied

Hi

I found the solution for this problem earlier but cant find it again so I will ask here:)
I have created a slide out/in menu with the scripts below.

They work as they should but only once. 

The first script are on a hamburger menu that slide the menu in to the right. The last are an X button inside a group that slide the menu out to the left.

This work only once.  Could anyone point me to the solution that I no more remember 🙂

mysk83_2-1681221495536.png

 

 

mysk83_0-1681221389016.png

 

Views

298

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Apr 12, 2023 Apr 12, 2023

Actionscript is no longer important since it was used for SWF output. But I think you mean an advanced action, which will be converted to JavaScript on runtime.

Did you read the blog post for which I posted the link? It has a step-by-step workflow. You need to create custom effects using a precise motion path. than make that custom effect available to be used in an advanced action. The advanced actions themselves are explained in the blog post. I don't think you have followed the workflow as exp

...

Votes

Translate

Translate
People's Champ ,
Apr 11, 2023 Apr 11, 2023

Copy link to clipboard

Copied

I don't see that you are toggling a variable to know which on to execute. Or are those two different action attached to 2 different buttons?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 11, 2023 Apr 11, 2023

Copy link to clipboard

Copied

This is for two buttons yes : )

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 11, 2023 Apr 11, 2023

Copy link to clipboard

Copied

Indeed, I would use a Boolean variable to check the status. The problem you have however is due to the use of default motion paths from the Entrance and Exit category. You need to create custom effects using the Motion path category so that you can define the exact start and end points of the motion paths. Have a look at this blog post which describes the exact workflow:

https://blog.lilybiri.com/sliding-menu

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 11, 2023 Apr 11, 2023

Copy link to clipboard

Copied

U have a post for every problem. Love it 🙂

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Will I be able to trigger this using actionscript? As I understand it, using motion path I work with the timeline and not actions?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

I tried to move the pause script and it now works but a new strange problem. The slide out menu show 100% on first click on the burger menu.
Second click 50%

Third click 10%

Last click it do not show at all.

So its like it slide out les and les for every click?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Please read my previous answer: you need to follow the explained workflow in detail. I suspect you didn't create a custom effect nor prepare it for use in the advanced action. What do you mean by 'pause script', please?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Actionscript is no longer important since it was used for SWF output. But I think you mean an advanced action, which will be converted to JavaScript on runtime.

Did you read the blog post for which I posted the link? It has a step-by-step workflow. You need to create custom effects using a precise motion path. than make that custom effect available to be used in an advanced action. The advanced actions themselves are explained in the blog post. I don't think you have followed the workflow as explained.

If you want more details about preparing a custom effect for use in an advanced action, here is another blog post link:

https://blog.lilybiri.com/how-to-use-custom-effect-in-actions

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

I will reread it again : ) Thank you 🙂

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Lovely. Now it works. Powerfull stuff.)

But ass always with captivate we have some bugs. It did work for a while. But now when I try to add the effect. After I save the action the custom effect I choosed jump backs to custom line. I have tried to create new actions but it do the same every thime: (

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Please show a screenshot of the actions. Did you follow the workflow to make the custom effect available as described in the last post for which I posted a link?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

It looks like captivate change to standard name for the imported effects so it works now 🙂

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Is there a way to set the exact position of start and end of the animasjon? I see that they move more and more for everytime I open and close the menu

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Ill answer myselfe here. I could open the xml file and edit it there: )

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

I always use guides (a vertical and a horizontal one) and let the motion path snap to the intersection:

https://blog.lilybiri.com/guides-rule

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

Thats smart. I changed the x and y inside the xml file so now its perfect 🙂

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 12, 2023 Apr 12, 2023

Copy link to clipboard

Copied

LATEST

Sure that is another way, but I mostly have guides set up to help with design.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Help resources