summaryrefslogtreecommitdiff
path: root/scene/audio/event_player.cpp
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2014-11-05 21:20:42 -0300
committerJuan Linietsky <reduzio@gmail.com>2014-11-05 21:20:42 -0300
commit0dbedd18fc62f700e92a4cf581e505d849bc47ad (patch)
tree8f2c85b4d9227e441fd35ab4873009faa656bcba /scene/audio/event_player.cpp
parentd14baf6e41bcdbe4968e0513beccc09dfb160ecd (diff)
SceneMainLoop -> SceneTree
-=-=-=-=-=-=-=-=-=-=-=-=-=- *YOUR SOURCE MIGHT NOT WORK* For mor information on fix: https://github.com/okamstudio/godot/wiki/devel_scene_tree Other stuff: -Shower of bullets demo -Fixes all around
Diffstat (limited to 'scene/audio/event_player.cpp')
-rw-r--r--scene/audio/event_player.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/scene/audio/event_player.cpp b/scene/audio/event_player.cpp
index e5b2be53ca..dc46f4711c 100644
--- a/scene/audio/event_player.cpp
+++ b/scene/audio/event_player.cpp
@@ -33,13 +33,13 @@ void EventPlayer::_notification(int p_what) {
switch(p_what) {
- case NOTIFICATION_ENTER_SCENE: {
+ case NOTIFICATION_ENTER_TREE: {
//set_idle_process(false); //don't annoy
- if (playback.is_valid() && autoplay && !get_scene()->is_editor_hint())
+ if (playback.is_valid() && autoplay && !get_tree()->is_editor_hint())
play();
} break;
- case NOTIFICATION_EXIT_SCENE: {
+ case NOTIFICATION_EXIT_TREE: {
stop(); //wathever it may be doing, stop
} break;
@@ -75,7 +75,7 @@ Ref<EventStream> EventPlayer::get_stream() const {
void EventPlayer::play() {
- ERR_FAIL_COND(!is_inside_scene());
+ ERR_FAIL_COND(!is_inside_tree());
if (playback.is_null()) {
return;
}
@@ -93,7 +93,7 @@ void EventPlayer::play() {
void EventPlayer::stop() {
- if (!is_inside_scene())
+ if (!is_inside_tree())
return;
if (playback.is_null())
return;
@@ -241,7 +241,7 @@ bool EventPlayer::is_paused() const {
void EventPlayer::_set_play(bool p_play) {
_play=p_play;
- if (is_inside_scene()) {
+ if (is_inside_tree()) {
if(_play)
play();
else