0 votes

I want to use the tween to animate some tiles fall from their position to another position, here is the code I use:

for tile in fallingTiles:
    self.fall_tween.interpolate_property(tile, "position.y", tile.position.y, tile.GridY * self.offset + self.y_position, 1, Tween.TRANS_BOUNCE, Tween.EASE_OUT)
self.fall_tween.start()
yield(self.fall_tween, "tween_completed")
print("falling complete")

the fall_tween is a child node and is loaded by onready var fall_tween = get_node("fall_tween")
It did print the "falling complete", I also checked the start position and finish position, is not same, but my tile didn't move.

in Engine by (74 points)

1 Answer

0 votes
Best answer

use "position:y" instead of "position.y"

by (9,760 points)
selected by

It works, thanks!

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.