summaryrefslogtreecommitdiff
path: root/scene/animation
diff options
context:
space:
mode:
Diffstat (limited to 'scene/animation')
-rw-r--r--scene/animation/animation_player.cpp8
-rw-r--r--scene/animation/animation_tree.cpp7
-rw-r--r--scene/animation/tween.cpp2
3 files changed, 9 insertions, 8 deletions
diff --git a/scene/animation/animation_player.cpp b/scene/animation/animation_player.cpp
index 2c19307c52..0c1798a876 100644
--- a/scene/animation/animation_player.cpp
+++ b/scene/animation/animation_player.cpp
@@ -605,7 +605,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float
}
if (p_seeked) {
- //find whathever should be playing
+ //find whatever should be playing
int idx = a->track_find_key(i, p_time);
if (idx < 0) {
continue;
@@ -634,7 +634,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float
nc->audio_playing = true;
playing_caches.insert(nc);
- if (len && end_ofs > 0) { //force a end at a time
+ if (len && end_ofs > 0) { //force an end at a time
nc->audio_len = len - start_ofs - end_ofs;
} else {
nc->audio_len = 0;
@@ -665,7 +665,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float
nc->audio_playing = true;
playing_caches.insert(nc);
- if (len && end_ofs > 0) { //force a end at a time
+ if (len && end_ofs > 0) { //force an end at a time
nc->audio_len = len - start_ofs - end_ofs;
} else {
nc->audio_len = 0;
@@ -1343,7 +1343,7 @@ void AnimationPlayer::_stop_playing_caches() {
}
void AnimationPlayer::_node_removed(Node *p_node) {
- clear_caches(); // nodes contained here ar being removed, clear the caches
+ clear_caches(); // nodes contained here are being removed, clear the caches
}
void AnimationPlayer::clear_caches() {
diff --git a/scene/animation/animation_tree.cpp b/scene/animation/animation_tree.cpp
index 26a13f33c9..4b4d3943c9 100644
--- a/scene/animation/animation_tree.cpp
+++ b/scene/animation/animation_tree.cpp
@@ -1009,7 +1009,7 @@ void AnimationTree::_process_graph(float p_delta) {
TrackCacheAudio *t = static_cast<TrackCacheAudio *>(track);
if (seeked) {
- //find whathever should be playing
+ //find whatever should be playing
int idx = a->track_find_key(i, time);
if (idx < 0) {
continue;
@@ -1038,7 +1038,7 @@ void AnimationTree::_process_graph(float p_delta) {
t->playing = true;
playing_caches.insert(t);
- if (len && end_ofs > 0) { //force a end at a time
+ if (len && end_ofs > 0) { //force an end at a time
t->len = len - start_ofs - end_ofs;
} else {
t->len = 0;
@@ -1069,7 +1069,7 @@ void AnimationTree::_process_graph(float p_delta) {
t->playing = true;
playing_caches.insert(t);
- if (len && end_ofs > 0) { //force a end at a time
+ if (len && end_ofs > 0) { //force an end at a time
t->len = len - start_ofs - end_ofs;
} else {
t->len = 0;
@@ -1337,6 +1337,7 @@ void AnimationTree::_tree_changed() {
}
void AnimationTree::_update_properties_for_node(const String &p_base_path, Ref<AnimationNode> node) {
+ ERR_FAIL_COND(node.is_null());
if (!property_parent_map.has(p_base_path)) {
property_parent_map[p_base_path] = HashMap<StringName, StringName>();
}
diff --git a/scene/animation/tween.cpp b/scene/animation/tween.cpp
index eb35979a47..2030808724 100644
--- a/scene/animation/tween.cpp
+++ b/scene/animation/tween.cpp
@@ -1115,7 +1115,7 @@ real_t Tween::tell() const {
// For each interpolation...
for (const List<InterpolateData>::Element *E = interpolates.front(); E; E = E->next()) {
- // Get the data and figure out if it's position is further along than the previous ones
+ // Get the data and figure out if its position is further along than the previous ones
const InterpolateData &data = E->get();
if (data.elapsed > pos) {
// Save it if so