summaryrefslogtreecommitdiffstats
path: root/scene/3d/spatial.cpp
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2015-03-22 11:52:07 -0300
committerJuan Linietsky <reduzio@gmail.com>2015-03-22 11:52:07 -0300
commit78694d85425b35d2c6c0e0a4b0ef3e57375553c6 (patch)
tree57c10798550be2ce3029eb77b0a9abe5fc370e4d /scene/3d/spatial.cpp
parent92ab362afae275ac26ba24db88395d6d4977515d (diff)
downloadredot-engine-78694d85425b35d2c6c0e0a4b0ef3e57375553c6.tar.gz
gui in 3D demo now uses area for input
Diffstat (limited to 'scene/3d/spatial.cpp')
-rw-r--r--scene/3d/spatial.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/scene/3d/spatial.cpp b/scene/3d/spatial.cpp
index edca62ece5..6e11855543 100644
--- a/scene/3d/spatial.cpp
+++ b/scene/3d/spatial.cpp
@@ -660,6 +660,12 @@ void Spatial::orthonormalize() {
}
+void Spatial::set_identity() {
+
+ set_transform(Transform());
+
+}
+
void Spatial::look_at(const Vector3& p_target, const Vector3& p_up_normal) {
@@ -735,6 +741,7 @@ void Spatial::_bind_methods() {
ObjectTypeDB::bind_method( _MD("translate","offset"),&Spatial::translate );
ObjectTypeDB::bind_method( _MD("global_translate","offset"),&Spatial::global_translate );
ObjectTypeDB::bind_method( _MD("orthonormalize"),&Spatial::orthonormalize );
+ ObjectTypeDB::bind_method( _MD("set_identity"),&Spatial::set_identity );
ObjectTypeDB::bind_method( _MD("look_at","target","up"),&Spatial::look_at );
ObjectTypeDB::bind_method( _MD("look_at_from_pos","pos","target","up"),&Spatial::look_at_from_pos );