Jump to content

How to move arcade box with body using tweens


lucasg07
 Share

Recommended Posts

Hi,

I'm using the arcade physics engine. I'm trying to move a cloud left and right via tweens but the problem is the arcade box isn't moving with it. 
Does anyone know how to fix this?

image.thumb.png.eedff05e920eb59a5862d31371fab79c.png

createTweens() {
    this.scene.tweens.add({
      targets: this,
      x: this.distanceX,
      duration: this.speed,
      yoyo: true,
      loop: - 1
    });
  }

 

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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