Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tweens affect Transform relative to parcel coordinates #1062

Closed
nearnshaw opened this issue Jan 3, 2024 · 2 comments · Fixed by decentraland/unity-renderer#6037
Closed
Assignees
Labels
bug Something isn't working
Milestone

Comments

@nearnshaw
Copy link
Member

nearnshaw commented Jan 3, 2024

After making a tween, the transform position seems to be affected in a weird way. Even thought we see the position where we expect, if we query the Transform component, we get very weird numbers.

This example scene was broken by changing utils.path to using the Tween component. You can now only push each box once. See in the video that we're logging the position of the item before moving and after moving. Even though the item moves just a couple of meters, the end position is something completely absurd.

Screen.Recording.2024-01-03.at.17.53.51.mov

We go for example from (8 , 0.16 , 7) to (-36 , 0.1599999964237213 , 85)
What's weird is that the item does still look like it's in the right place

Find the scene here:
https://github.com/decentraland/sdk7-goerli-plaza/tree/main/push-box-puzzle

The scene was in coordinates 84,-5
I tried changing the coordinates of the scene to 0,0 and suddenly everything was fixed!!! The only thing I changed since the last video was the coordinates in scene.json.

Screen.Recording.2024-01-03.at.18.01.03.mov

That would also explain why I haven't been able to reproduce this issue in the Playground, because there we're always in 0,0
Here is a scene that works perfectly well:
link

I have a strong feeling that this also explains the problems we have with tweens + trigger areas

@nearnshaw nearnshaw converted this from a draft issue Jan 3, 2024
@nearnshaw nearnshaw added the bug Something isn't working label Jan 3, 2024
@nearnshaw nearnshaw added this to the Workspace milestone Jan 3, 2024
@nearnshaw nearnshaw moved this from Todo to In Progress in Creators Tools Jan 4, 2024
@github-project-automation github-project-automation bot moved this from In Progress to Done in Creators Tools Jan 4, 2024
@pravusjif
Copy link
Member

tackled at decentraland/unity-renderer#6037, will reach production with next explorer's release and subsequent SDK release

@pravusjif
Copy link
Member

Fix released with @dcl/[email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants