Jump to content
Search Community

timelinemax and gaia

viaria test
Moderator Tag

Recommended Posts

hi,

i have a problem with inserting my game into my gaia site's opening.

the problem is after shapes come into places, cubes start rolling, that is the place timelineMax goes crazy. it is working alone normally but gaia site.

 

here is my game alone without gaia

http://gricreative.com/clients/toca/cube3/

 

and here is i made it my gaia site's homepage class.

http://gricreative.com/clients/toca/site/

 

do you have any idea?

Link to comment
Share on other sites

hi jack, i guess i got something.

my working example using timelinelite v 1.392

and other one that not working uses v 1.66 latest

 

i changed the path to old version and it gives verifing error.

 

VerifyError: Error #1053: com.greensock.TimelineLite -> addChild

Link to comment
Share on other sites

//so my code.

 

 goPlace(cubes[7], ["r","r","r","u","u","r","r"]);

	private function goPlace(c:CubeSprite, dirs:Array):void{
		var total:uint = dirs.length;
		var i:uint = 0;
		var sx:Number = c.x;
		var sy:Number = c.y;

		var timeline:TimelineMax = new TimelineMax({align:TweenAlign.SEQUENCE});

		for(i; i < total; ++i){
			switch(String(dirs[i])){
				case "l":
					sx -= SIZE;
					timeline.append(TweenMax.to(c, .5, {frame:60, x:sx, onInit:setRotation, onInitParams:[c, 180], ease:Linear.easeNone}));						
				break;
				case "r":
					sx += SIZE;
					timeline.append(TweenMax.to(c, .5, {frame:60, x:sx, onInit:setRotation, onInitParams:[c, 0], ease:Linear.easeNone}));						
				break;
				case "u":
					sy -= SIZE;
					timeline.append(TweenMax.to(c, .5, {frame:60, y:sy, onInit:setRotation, onInitParams:[c, -90], ease:Linear.easeNone}));						
				break;
				case "d":
					sy += SIZE;
					timeline.append(TweenMax.to(c, .5, {frame:60, y:sy, onInit:setRotation, onInitParams:[c, +90], ease:Linear.easeNone}));						
				break;
				default:
					trace("default dir: "+dirs[i]);
				break;
			}
		}

	}

	private function setRotation(c:CubeSprite, r:int = 0):void{
		c.gotoAndStop(1);
		c.rotation = r;
	}

Link to comment
Share on other sites

i solved it.

the problem is gaia changes tweenlite's overwriteManager default settings. so i changed it back to auto default mode . i hope something else will not explode.

 

jack thanks for interest.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...