Optimize Animation::_track_update_hash
Co-Authored-By: Silc Lizard (Tokage) Renew <tokage.it.lab@gmail.com> Co-Authored-By: Luo Zhihao <luo_zhihao@outlook.com> Co-Authored-By: Lukas Tenbrink <lukas.tenbrink@gmail.com>
This commit is contained in:
@@ -1062,9 +1062,9 @@ Animation::TrackType Animation::get_cache_type(TrackType p_type) {
|
||||
}
|
||||
|
||||
void Animation::_track_update_hash(int p_track) {
|
||||
NodePath track_path = tracks[p_track]->path;
|
||||
TrackType track_cache_type = get_cache_type(tracks[p_track]->type);
|
||||
tracks[p_track]->thash = StringName(String(track_path.get_concatenated_names()) + String(track_path.get_concatenated_subnames()) + itos(track_cache_type)).hash();
|
||||
const NodePath &track_path = tracks[p_track]->path;
|
||||
const TrackType track_cache_type = get_cache_type(tracks[p_track]->type);
|
||||
tracks[p_track]->thash = HashMapHasherDefault::hash(Pair<const NodePath &, TrackType>(track_path, track_cache_type));
|
||||
}
|
||||
|
||||
Animation::TypeHash Animation::track_get_type_hash(int p_track) const {
|
||||
|
||||
Reference in New Issue
Block a user