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

library with this.stop() on first frame not working

Community Beginner ,
Jan 10, 2020 Jan 10, 2020

Copy link to clipboard

Copied

Got 2 almost identical symbols, and I want them to stop at the first frame. but only 1 work and 1 doesn't. Any idea? Thanks.

 

(lib.Cart_B = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{ENU:0,ESN:9});
	// timeline functions:
	this.frame_0 = function() {
		this.stop();
	}
	// Layer_1
	this.shape = new cjs.Shape();
	this.shape.graphics.f("#FFFFFF").s().p("............");
	this.shape.setTransform(0,4.175);
	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.f("#FFFFFF").s().p("............");
	this.shape_1.setTransform(0,4.175);
	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape}]}).to({state:[{t:this.shape_1}]},9).wait(11));
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-18.4,0,36.8,8.4);

(lib.Cart_A = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{ENU:0,ESN:9});
	// timeline functions:
	this.frame_0 = function() {
		this.stop();
	}	
	// Layer_1
	this.shape = new cjs.Shape();
	this.shape.graphics.f("#FFFFFF").s().p(".........");
	this.shape.setTransform(0,4.175);
	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.f("#FFFFFF").s().p("............");
	this.shape_1.setTransform(0,4.175);
	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape}]}).to({state:[{t:this.shape_1}]},9).wait(11));
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-18.8,0,37.7,8.4);
TOPICS
Code , Error

Views

170

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 ,
Jan 11, 2020 Jan 11, 2020

Copy link to clipboard

Copied

LATEST

Hi.

 

I can tell for sure by only looking at the code generated in the output.

 

Can you provide your FLA?

 

 

Regards,

JC

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