berikut action script yang digunakan dalam video :
benar_mc.visible=false;
salah_mc.visible=false;
var orig1X:Number=item1_mc.x;
var orig1Y:Number=item1_mc.y;
var orig2X:Number=item2_mc.x;
var orig2Y:Number=item2_mc.y;
var orig3X:Number=item3_mc.x;
var orig3Y:Number=item3_mc.y;
item1_mc.addEventListener(MouseEvent.MOUSE_DOWN,dragTheObject);
item1_mc.addEventListener(MouseEvent.MOUSE_UP,item1Release);
item2_mc.addEventListener(MouseEvent.MOUSE_DOWN,dragTheObject);
item2_mc.addEventListener(MouseEvent.MOUSE_UP,item2Release);
item3_mc.addEventListener(MouseEvent.MOUSE_DOWN,dragTheObject);
item3_mc.addEventListener(MouseEvent.MOUSE_UP,item3Release);
cek_btn.addEventListener(MouseEvent.CLICK,checkAnswers);
reset_btn.addEventListener(MouseEvent.CLICK,reset);
function dragTheObject(event:MouseEvent):void{
var item=MovieClip(event.target);
item.startDrag();
var topPos:uint=this.numChildren-1;
}
function item1Release(event:MouseEvent):void{
var item:MovieClip=MovieClip(event.target);
item.stopDrag();
if (dropZone1_mc.hitTestObject(item)){
item.x=dropZone1_mc.x+20;
item.y=dropZone1_mc.y+27;
}
else{
item.x=orig1X;
item.y=orig1Y;
}
}
function item2Release(event:MouseEvent):void{
var item:MovieClip=MovieClip(event.target);
item.stopDrag();
if (dropZone2_mc.hitTestObject(item)){
item.x=dropZone2_mc.x+20;
item.y=dropZone2_mc.y+20;
}
else{
item.x=orig2X;
item.y=orig2Y;
}
}
function item3Release(event:MouseEvent):void{
var item:MovieClip=MovieClip(event.target);
item.stopDrag();
if (dropZone3_mc.hitTestObject(item)){
item.x=dropZone3_mc.x+20;
item.y=dropZone3_mc.y+19;
}
else{
item.x=orig3X;
item.y=orig3Y;
}
}
function checkAnswers(event:MouseEvent):void{
if(dropZone1_mc.hitTestObject(item1_mc)&&
dropZone2_mc.hitTestObject(item2_mc)&&
dropZone3_mc.hitTestObject(item3_mc)){
salah_mc.visible=false;
benar_mc.visible=true;
}
else {
salah_mc.visible=true;
benar_mc.visible=false;
}}
function reset(event:MouseEvent):void{
item1_mc.x=orig1X;
item1_mc.y=orig1Y;
item2_mc.x=orig2X;
item2_mc.y=orig2Y;
item3_mc.x=orig3X;
item3_mc.y=orig3Y;
benar_mc.visible=false;
salah_mc.visible=false;
}
terimakasih sudah menonton video ini.
As reported by Stanford Medical, It is in fact the ONLY reason women in this country live 10 years longer and weigh an average of 42 pounds less than us.
ReplyDelete(And realistically, it is not related to genetics or some secret diet and really, EVERYTHING around "how" they eat.)
BTW, I said "HOW", and not "WHAT"...
TAP on this link to discover if this little test can help you discover your real weight loss potential
Fast Air Private Ambulance Service in Mumbai
ReplyDeleteOxygen We respond promptly, Ambulance Service In Mumbai is maintained by our every day of the week help to ensure that each call is responded to so that you'll get the most state of the art information about the Ambulance's arrival in your space. See customer comments and recognitions from those that have utilized our services. This can help you with concluding the second response time. Ambulance costs: Another point to consider while picking the ambulance services we offer is the expense regardless. All services that are given will not be free. Costs will move contingent upon the service, the space of the trade, and the sort of Ambulance needed by you.
https://www.dialaids.com/ambulance-serivce-in-mumbai.html
https://ulozto.net/tamhle/bv6yeHnYtK7g#!ZGIyAQR2AmSyLzVlAwV0ZwSvMGp4BJp3F3EXDIyBrK5grQqyAt==
ReplyDelete