ทำวัตถุให้ลงมาทีละชิ้นโดยเวลาต่าง

เริ่มโพสต์โดย iNokjung, 27 พ.ย. 2011, 02:48 น.

0 สมาชิก และ 1 บุคคลทั่วไป กำลังเปิดอ่านโพสต์นี้

iNokjung

เอาโค้ดนี้ไปใส่ทุกวัตถุที่หล่นลงมามันเลยหล่นมาพร้อมกัน อยากให้มันค่อยๆ หล่นลงมาทีละชิ้นทำไงดีค่ะ
onClipEvent(enterFrame)

{
      this._rotation += 5;                               
      this._y += 9;
   
      if(this._y > Stage.height)
      {
      this._y =- 5;
      this._x =random(Stage.width);
      }
      if (this.hitTest(_root.bin1))
   {
      
      _root.score++;
      unloadMovie (this);

   }
}

SMF 2.1.7 © 2026, Simple Machines