X hits on this document

PDF document

Rochester Institute of Technology - page 36 / 39

102 views

0 shares

0 downloads

0 comments

36 / 39

7. 2. Code Examples

Sequential part in the Kaksi story

value = 0 bg_mc.kaksi_mc.onRelease= function(){ this.stopDrag(); if(this.hitTest(bg_mc.hotspot_mc)){ value += 1; this._x = bg_mc.hotspot_mc._x; this._y = bg_mc.hotspot_mc._y-3; bg_mc.musician_mc.gotoAndStop(“walk”); } } bg_mc.sky_mc.sun_mc.onPress= function(){ bg_mc.directarrow1.removeMovieClip(); value += 1; bg_mc.sky_mc.sun_mc.enabled =false; bg_mc.sky_mc.sun_mc.gotoAndPlay(2); bg_mc.sky_mc.gotoAndPlay(2); bg_mc.kaksi_mc.gotoAndStop(“dance”)

}

b g _ m c . h o t s p o t 2 _ m c . o n R e l e a s e = f u n c t i o n ( ) {

if (value==3) { click_sound.setVolume(50); bg_mc.kaksi_mc.xSlideTo(185,20,”linear”) bg_mc.musician_mc.xSlideTo(185,20,”linear”); bg_mc.musician_mc.onTweenComplete=function(){ memopad.ySlideTo(-40, 0.5,”easeOutElastic”)} } } Count=0; bg_mc.ritualtree_mc.onPress=function(){ bg_mc.ritualtree_mc.ritualbranch_mc.gotoAndPlay();

Count++ for(i=0; i<leaveNum;i++) { bg_mc.ritualtree_mc[“leave”+i+”_mc”]._xscale +=30; bg_mc.ritualtree_mc[“leave”+i+”_mc”]._yscale +=30 if(bg_mc.ritualtree_mc[“leave”+i+”_mc”]._xscale>170) {bg_mc.ritualtree_mc[“leave”+i+”_mc”].scaleTo(300,5, “easeoutelastic”);}

} if(Count>3){makeRainGrass(); bg_mc.directarrow3.removeMovieClip(); value+=1; bg_mc.ritualtree_mc.enabled =false; bg_mc.ritualgrass_mc.alphaTo(100, 2, “linear”); bg_mc.ritualgrass_mc.onTweenComplete = function() bigBranchLeaves();

}

}

36

Storytelling of the Hahoe Mask

Document info
Document views102
Page views102
Page last viewedFri Dec 09 06:05:40 UTC 2016
Pages39
Paragraphs519
Words7675

Comments