Skip to content

Commit

Permalink
Minor flow changes
Browse files Browse the repository at this point in the history
  • Loading branch information
ashpect committed Sep 21, 2022
1 parent 713f0fd commit 301edf8
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 28 deletions.
4 changes: 2 additions & 2 deletions editor/editor.app.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
}
},
"InputSystem": {
"height": 991,
"height": 1017,
"inputSchemes": {
"Editor": {
"bools": [
Expand Down Expand Up @@ -91,7 +91,7 @@
},
"PhysicsSystem": {},
"UISystem": {
"height": 991,
"height": 1017,
"width": 1920
}
},
Expand Down
2 changes: 1 addition & 1 deletion editor/editor_system.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ void EditorSystem::drawDefaultUI(float deltaMilliseconds)
ImGui::Separator();
if (ImGui::BeginMenu("Create Scene"))
{
static unsigned int inputBaseID = 0;
static SceneID inputBaseID = 0;
ImGui::InputText("Scene Name", &newSceneName, ImGuiInputTextFlags_AlwaysInsertMode);
ImGui::InputScalar("Scene BaseID", ImGuiDataType_U32, &inputBaseID);
Scene::SetBaseID(inputBaseID);
Expand Down
30 changes: 15 additions & 15 deletions imgui.ini
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[Window][Rootex Editor]
Pos=0,0
Size=1920,991
Size=1920,1017
Collapsed=0

[Window][Output]
Pos=0,620
Size=1114,371
Pos=0,636
Size=1114,381
Collapsed=0
DockId=0x00000003,0

Expand Down Expand Up @@ -33,19 +33,19 @@ Collapsed=0
DockId=0x0000000D,0

[Window][Toolbar]
Pos=1116,620
Size=333,371
Pos=1116,636
Size=333,381
Collapsed=0
DockId=0x00000004,0

[Window][Viewport]
Pos=0,28
Size=1449,590
Size=1449,606
Collapsed=0
DockId=0x00000008,0

[Window][Inspector]
Pos=1451,409
Pos=1451,435
Size=469,582
Collapsed=0
DockId=0x00000009,0
Expand Down Expand Up @@ -155,7 +155,7 @@ Collapsed=0

[Window][Scene]
Pos=1451,28
Size=469,379
Size=469,405
Collapsed=0
DockId=0x00000007,0

Expand All @@ -170,13 +170,13 @@ Size=750,643
Collapsed=0

[Window][Load Scene]
Pos=1117,620
Pos=1119,620
Size=30,58
Collapsed=0

[Window][Save]
Pos=1233,626
Size=262,110
Pos=1249,634
Size=257,110
Collapsed=0

[Window][Style Editor]
Expand All @@ -191,7 +191,7 @@ Collapsed=0

[Window][File Editor]
Pos=0,28
Size=1449,590
Size=1449,606
Collapsed=0
DockId=0x00000008,1

Expand All @@ -201,13 +201,13 @@ Size=241,158
Collapsed=0

[Window][Content Browser]
Pos=0,620
Size=1114,371
Pos=0,636
Size=1114,381
Collapsed=0
DockId=0x00000003,1

[Docking][Data]
DockSpace ID=0x654E7FDC Window=0xDC8952A0 Pos=0,28 Size=1920,963 Split=X
DockSpace ID=0x654E7FDC Window=0xDC8952A0 Pos=0,28 Size=1920,989 Split=X
DockNode ID=0x00000001 Parent=0x654E7FDC SizeRef=1932,1359 Split=Y Selected=0x995B0CF8
DockNode ID=0x00000008 Parent=0x00000001 SizeRef=1932,596 Selected=0x995B0CF8
DockNode ID=0x0000000A Parent=0x00000001 SizeRef=1932,375 Split=X Selected=0xCB7211A8
Expand Down
9 changes: 1 addition & 8 deletions rootex/framework/scene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,6 @@ Ptr<Scene> Scene::Create(const JSON::json& sceneData, const bool assignNewIDs)
}
else
{
/*thisSceneID = std::max(std::max(BaseID, NextSceneID), SceneIDOffset);
NextSceneID = std::max(BaseID, SceneIDOffset);*/
NextSceneID = std::max(std::max(BaseID, NextSceneID), SceneIDOffset);
thisSceneID = NextSceneID;
}
Expand Down Expand Up @@ -320,11 +318,6 @@ void Scene::setName(const String& name)
m_FullName = name + " # " + std::to_string(m_ID);
}

void Scene::setm_BaseID(const SceneID& input)
{
m_BaseID = BaseID;
}

JSON::json Scene::getJSON() const
{
JSON::json j;
Expand Down Expand Up @@ -356,7 +349,7 @@ Scene::Scene(SceneID id, const String& name, const SceneSettings& settings, Impo
, m_Entity(this)
{
setName(m_Name);
setm_BaseID(BaseID);
setm_BaseID();
s_Scenes.push_back(this);
}

Expand Down
4 changes: 2 additions & 2 deletions rootex/framework/scene.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class Scene

public:
static void ResetNextID();
static void Scene::SetBaseID(const SceneID& inputBaseID) { BaseID = inputBaseID; }
static void SetBaseID(const SceneID& inputBaseID) { BaseID = inputBaseID; }

static Ptr<Scene> Create(const JSON::json& sceneData, const bool assignNewIDs);
static Ptr<Scene> CreateFromFile(const String& sceneFile);
Expand All @@ -82,7 +82,7 @@ class Scene
bool removeChild(Scene* toRemove);

void setName(const String& name);
void setm_BaseID(const SceneID& input);
void Scene::setm_BaseID(){ m_BaseID = BaseID; }

JSON::json getJSON() const;
bool& getIsScenePaused() { return m_IsScenePaused; }
Expand Down

0 comments on commit 301edf8

Please sign in to comment.