diff --git a/CENTRAL 3D/Game/Assets/New Folder 3.meta b/CENTRAL 3D/Game/Assets/New Folder 3.meta deleted file mode 100644 index 767a8d17..00000000 --- a/CENTRAL 3D/Game/Assets/New Folder 3.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592333282, - "ResourceData": null, - "SOURCE": "Assets/New Folder 3", - "UID": 245527285, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/New Folder 4.meta b/CENTRAL 3D/Game/Assets/New Folder 4.meta deleted file mode 100644 index 6ed980da..00000000 --- a/CENTRAL 3D/Game/Assets/New Folder 4.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592333266, - "ResourceData": null, - "SOURCE": "Assets/New Folder 4", - "UID": 954293385, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/New Folder 5.meta b/CENTRAL 3D/Game/Assets/New Folder 5.meta deleted file mode 100644 index b9867fd8..00000000 --- a/CENTRAL 3D/Game/Assets/New Folder 5.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592333334, - "ResourceData": null, - "SOURCE": "Assets/New Folder 5", - "UID": 1400861507, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/Shaders/LinePoint.glsl.meta b/CENTRAL 3D/Game/Assets/Shaders/LinePoint.glsl.meta index a166cb5d..9d351f13 100644 --- a/CENTRAL 3D/Game/Assets/Shaders/LinePoint.glsl.meta +++ b/CENTRAL 3D/Game/Assets/Shaders/LinePoint.glsl.meta @@ -1,5 +1,5 @@ { - "DATE": 1592338820, + "DATE": 1592344668, "ResourceData": { "FORMAT": 36385 }, diff --git a/CENTRAL 3D/Game/Assets/Shaders/OutlineShader.glsl.meta b/CENTRAL 3D/Game/Assets/Shaders/OutlineShader.glsl.meta index 763f07a9..27b9b2f3 100644 --- a/CENTRAL 3D/Game/Assets/Shaders/OutlineShader.glsl.meta +++ b/CENTRAL 3D/Game/Assets/Shaders/OutlineShader.glsl.meta @@ -1,5 +1,5 @@ { - "DATE": 1592338820, + "DATE": 1592344668, "ResourceData": { "FORMAT": 36385 }, diff --git a/CENTRAL 3D/Game/Assets/Shaders/Standard.glsl.meta b/CENTRAL 3D/Game/Assets/Shaders/Standard.glsl.meta index d5ffa978..447bf7a3 100644 --- a/CENTRAL 3D/Game/Assets/Shaders/Standard.glsl.meta +++ b/CENTRAL 3D/Game/Assets/Shaders/Standard.glsl.meta @@ -1,5 +1,5 @@ { - "DATE": 1592338820, + "DATE": 1592344668, "ResourceData": { "FORMAT": 36385 }, diff --git a/CENTRAL 3D/Game/Assets/Shaders/ZDrawer.glsl.meta b/CENTRAL 3D/Game/Assets/Shaders/ZDrawer.glsl.meta index 550194c4..578a4d47 100644 --- a/CENTRAL 3D/Game/Assets/Shaders/ZDrawer.glsl.meta +++ b/CENTRAL 3D/Game/Assets/Shaders/ZDrawer.glsl.meta @@ -1,5 +1,5 @@ { - "DATE": 1592338820, + "DATE": 1592344668, "ResourceData": { "FORMAT": 36385 }, diff --git a/CENTRAL 3D/Game/Assets/TestFolder.meta b/CENTRAL 3D/Game/Assets/TestFolder.meta deleted file mode 100644 index 84ae9ae6..00000000 --- a/CENTRAL 3D/Game/Assets/TestFolder.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592338796, - "ResourceData": null, - "SOURCE": "Assets/TestFolder", - "UID": 480297008, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/TestFolder/.meta b/CENTRAL 3D/Game/Assets/TestFolder/.meta deleted file mode 100644 index c4bbe34e..00000000 --- a/CENTRAL 3D/Game/Assets/TestFolder/.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 4294967295, - "ResourceData": null, - "SOURCE": "Assets/TestFolder/", - "UID": 250070097, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/TestFolder/TestShader.glsl b/CENTRAL 3D/Game/Assets/TestFolder/TestShader.glsl deleted file mode 100644 index 67900705..00000000 --- a/CENTRAL 3D/Game/Assets/TestFolder/TestShader.glsl +++ /dev/null @@ -1,33 +0,0 @@ -#version 460 core -#define VERTEX_SHADER -#ifdef VERTEX_SHADER -layout (location = 0) in vec3 position; -layout(location = 1) in vec3 normal; -layout(location = 2) in vec3 color; -layout (location = 3) in vec2 texCoord; -uniform vec3 Color = vec3(1.0); -out vec3 ourColor; -out vec2 TexCoord; -uniform mat4 model_matrix; -uniform mat4 view; -uniform mat4 projection; -void main(){ -gl_Position = projection * view * model_matrix * vec4 (position, 1.0f); -ourColor = Color; -TexCoord = texCoord; -} -#endif //VERTEX_SHADER - -#define FRAGMENT_SHADER -#ifdef FRAGMENT_SHADER -uniform int Texture; -in vec3 ourColor; -in vec2 TexCoord; -out vec4 color; -uniform sampler2D ourTexture; -void main(){ -color = texture(ourTexture, TexCoord) * vec4(ourColor, 1); -if(Texture == -1) -color = vec4(ourColor, 1); -} -#endif //FRAGMENT_SHADER diff --git a/CENTRAL 3D/Game/Assets/TestFolder/TestShader.glsl.meta b/CENTRAL 3D/Game/Assets/TestFolder/TestShader.glsl.meta deleted file mode 100644 index 20491122..00000000 --- a/CENTRAL 3D/Game/Assets/TestFolder/TestShader.glsl.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592338371, - "ResourceData": null, - "SOURCE": "Assets/TestFolder/TestShader.glsl", - "UID": 208450965, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/TestFolder/sceeeene.scene.meta b/CENTRAL 3D/Game/Assets/TestFolder/sceeeene.scene.meta deleted file mode 100644 index 446e02f5..00000000 --- a/CENTRAL 3D/Game/Assets/TestFolder/sceeeene.scene.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592334951, - "ResourceData": null, - "SOURCE": "Assets/TestFolder/sceeeene.scene", - "UID": 1543182748, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Game/Assets/TestFolder/testmat2.mat.meta b/CENTRAL 3D/Game/Assets/TestFolder/testmat2.mat.meta deleted file mode 100644 index 9148db30..00000000 --- a/CENTRAL 3D/Game/Assets/TestFolder/testmat2.mat.meta +++ /dev/null @@ -1,7 +0,0 @@ -{ - "DATE": 1592334932, - "ResourceData": null, - "SOURCE": "Assets/TestFolder/testmat2.mat", - "UID": 1766568473, - "fileFormatVersion": 2 -} \ No newline at end of file diff --git a/CENTRAL 3D/Source/PanelProject.cpp b/CENTRAL 3D/Source/PanelProject.cpp index 4e418118..0e7038e7 100644 --- a/CENTRAL 3D/Source/PanelProject.cpp +++ b/CENTRAL 3D/Source/PanelProject.cpp @@ -323,14 +323,18 @@ void PanelProject::CreateResourceHandlingPopup() //EngineApp->resources->AddResourceToFolder(new_folder); // --- Create meta --- + std::string meta_path = new_folder->GetResourceFile(); + meta_path.pop_back(); ImporterMeta* IMeta = App->resources->GetImporter(); - ResourceMeta* meta = (ResourceMeta*)App->resources->CreateResourceGivenUID(Resource::ResourceType::META, new_folder->GetResourceFile(), new_folder->GetUID()); + ResourceMeta* meta = (ResourceMeta*)App->resources->CreateResourceGivenUID(Resource::ResourceType::META, meta_path, new_folder->GetUID()); if (meta) IMeta->Save(meta); IFolder->Save((ResourceFolder*)new_folder); + App->resources->AddResourceToFolder(new_folder); + ImGui::CloseCurrentPopup(); } diff --git a/CENTRAL 3D/Source/ResourceShader.cpp b/CENTRAL 3D/Source/ResourceShader.cpp index beb6bf96..0ef04e18 100644 --- a/CENTRAL 3D/Source/ResourceShader.cpp +++ b/CENTRAL 3D/Source/ResourceShader.cpp @@ -514,6 +514,7 @@ void ResourceShader::OnDelete() FreeMemory(); App->fs->Remove(resource_file.c_str()); + App->fs->Remove(original_file.c_str()); App->resources->RemoveResourceFromFolder(this); App->resources->ONResourceDestroyed(this);