Godot can't recognize the Vector2.clamped() function when exported to exe

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By raphaelkox
:warning: Old Version Published before Godot 3 was released.

Recently i noticed the clamped() function on Vector2 and started using it and everything
was fine in the editor.
After a working a bit, i decided to test a export to exe.

When i run the exported file, Godot says that the function don’t exist, flooding the
console with errors and not working correctly.

I searched around and couldn’t find anything on the subject.
Does anyone know what is wrong, or at least had the same problem?

Thanks in advance!

:bust_in_silhouette: Reply From: eska

Your export templates are probably outdated, I think Vector2.clamped was added in 2.1.1.
Editor and export templates should always be updated together so they’re based on the same version

You’re totally right, completely forgot the templates.

Thanks for the quick help!

raphaelkox | 2017-03-02 19:02