Merge pull request #10319 from neikeq/pr-engine-editor-hint
Adds Engine::is_editor_hint() method
This commit is contained in:
commit
541fdffc0a
52 changed files with 167 additions and 114 deletions
|
|
@ -29,6 +29,7 @@
|
|||
/*************************************************************************/
|
||||
#include "light.h"
|
||||
|
||||
#include "engine.h"
|
||||
#include "project_settings.h"
|
||||
#include "scene/resources/surface_tool.h"
|
||||
|
||||
|
|
@ -150,7 +151,7 @@ void Light::_update_visibility() {
|
|||
|
||||
#ifdef TOOLS_ENABLED
|
||||
if (editor_only) {
|
||||
if (!get_tree()->is_editor_hint()) {
|
||||
if (!Engine::get_singleton()->is_editor_hint()) {
|
||||
editor_ok = false;
|
||||
} else {
|
||||
editor_ok = (get_tree()->get_edited_scene_root() && (this == get_tree()->get_edited_scene_root() || get_owner() == get_tree()->get_edited_scene_root()));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue