What's the difference between "translate" and "translate_object_local"?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By terra

In Spatial nodes I suppose translate_object_local is supposed to translate the object in its own local coordinates considering its scale and rotation. In practice it works like this but in my tests it also behaves identically to translate, both translate the object using the object’s local coordinates. My question is regarding the latter: is Spatial’s “translate” supposed to be any different to translate_object_local? Is translate’s current implementation correct?

I made a simple test scene to apply both methods on two cube objects. One without rotation and another rotated. Both move the same with both translate and translate_object_local
http://www.mediafire.com/file/6lzbv6ov1ez5582/TranslateTest.tscn/file

:bust_in_silhouette: Reply From: OriginalAGP

Logically I would think that the local space one would move in the object’s axis before all worldspace transformations (so if you used its z axis and then rotated it it would still move forward. I tested it, too, and it doesn’t do that. So I second your question about its implementation.

I think this should be a comment, not a question.

lincolnpepper | 2019-08-02 13:40

:bust_in_silhouette: Reply From: terra

To answer myself, it seems like they don’t consider having two functions that do the same thing a bug:

We have global translate, local translate and translate that is the same as local translate. I don’t get it. To add to this, rotate and rotate local both exist, but rotate does work on parent coordinates.