diff options
Diffstat (limited to 'demos/3d/mousepick_test/mousepick.gd')
-rw-r--r-- | demos/3d/mousepick_test/mousepick.gd | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/demos/3d/mousepick_test/mousepick.gd b/demos/3d/mousepick_test/mousepick.gd deleted file mode 100644 index 674ec7ff6f..0000000000 --- a/demos/3d/mousepick_test/mousepick.gd +++ /dev/null @@ -1,24 +0,0 @@ - -extends RigidBody - -# Member variables -var gray_mat = FixedMaterial.new() -var selected = false - - -func _input_event(camera, event, pos, normal, shape): - if (event.type==InputEvent.MOUSE_BUTTON and event.pressed): - if (not selected): - get_node("mesh").set_material_override(gray_mat) - else: - get_node("mesh").set_material_override(null) - - selected = not selected - - -func _mouse_enter(): - get_node("mesh").set_scale(Vector3(1.1, 1.1, 1.1)) - - -func _mouse_exit(): - get_node("mesh").set_scale(Vector3(1, 1, 1)) |