Fix BehaviorTreeView::update_tree null data crash
This commit is contained in:
parent
25c72302ca
commit
dd837ff472
|
@ -98,6 +98,7 @@ inline void _item_set_elapsed_time(TreeItem *p_item, double p_elapsed) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void BehaviorTreeView::update_tree(const Ref<BehaviorTreeData> &p_data) {
|
void BehaviorTreeView::update_tree(const Ref<BehaviorTreeData> &p_data) {
|
||||||
|
ERR_FAIL_COND_MSG(p_data.is_null(), "Invalid data. View won't update.");
|
||||||
update_data = p_data;
|
update_data = p_data;
|
||||||
update_pending = true;
|
update_pending = true;
|
||||||
_notification(NOTIFICATION_PROCESS);
|
_notification(NOTIFICATION_PROCESS);
|
||||||
|
|
Loading…
Reference in New Issue