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

action for slideshow buttons next prev

Contributor ,
Aug 24, 2024 Aug 24, 2024

hello there

i made a frame sequence that progresses every 5 frames....

but i dont know the action script for this sequence, oly for every 1 frame

does anybody has the action for 5 by 5?

leo240861267932_0-1724514302335.png

 

2.2K
Translate
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
Contributor ,
Aug 24, 2024 Aug 24, 2024

where do i place 

explain me here

nextfromfile.addEventListener(MouseEvent.CLICK, advanceFiveF);

function advanceFiveF(e:MouseEvent):void{

if(currentFrame+5>totalFrames){

gotoAndStop((currentFrame+5)%totalFrames);

} else {

gotoAndStop(currentFrame+5);

}

}

Translate
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 ,
Aug 24, 2024 Aug 24, 2024

nextfromfile.addEventListener(MouseEvent.CLICK, advanceFiveF);

function advanceFiveF(e:MouseEvent):void{

trace("s")

if(currentFrame+5>totalFrames){

gotoAndStop((currentFrame+5)%totalFrames);

} else {

gotoAndStop(currentFrame+5);

}

}

Translate
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
Contributor ,
Aug 24, 2024 Aug 24, 2024

thats ok

this one works

what does not work is this one

prevfromfile.addEventListener(MouseEvent.CLICK, retreatFiveF);

function retreatFiveF(e:MouseEvent):void{

if(currentFrame-5<1){

gotoAndStop(totalFrames+currentFrame-5);

} else {

gotoAndStop(currentFrame-5);

}

}

 

Translate
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 ,
Aug 24, 2024 Aug 24, 2024

prevfromfile.addEventListener(MouseEvent.CLICK, retreatFiveF);

function retreatFiveF(e:MouseEvent):void{

trace("@");

if(currentFrame-5<1){

gotoAndStop(totalFrames+currentFrame-5);

} else {

gotoAndStop(currentFrame-5);

}

}

Translate
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
Contributor ,
Aug 24, 2024 Aug 24, 2024

nevermind man

i guess its a bug

i have one more question

is my home button action correct?

it works only in the first slide in frame 5 to the beginnin frame 1

the other frames 5 by 5 does not work

is this correct

leo240861267932_0-1724519516792.png

 

Translate
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 ,
Aug 24, 2024 Aug 24, 2024

the code is ok.

Translate
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
Contributor ,
Aug 24, 2024 Aug 24, 2024

isnt there another alternative for home button? another script?

Translate
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 ,
Aug 24, 2024 Aug 24, 2024

different script won't fix the problems you're seeing.

Translate
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
Contributor ,
Aug 24, 2024 Aug 24, 2024

ok man 

just passing by to say thanks for the support 

 

Translate
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 ,
Aug 24, 2024 Aug 24, 2024
LATEST

you're welcome.

Translate
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