difed inspector to shows deg instead of raians
This commit is contained in:
parent
bfd98c1cea
commit
a641df5b55
@ -1,3 +1,3 @@
|
||||
[COMPILE] g++ -std=c++20 -Wall -g -Isrc/include -Isrc/include/lua -Isrc/vendor -Isrc/vendor/imgui -Isrc/vendor/box2d -Isrc/vendor/xxhash -IC:/msys64/mingw64/include -IC:\msys64\mingw64\lib\libyaml-cpp.a -Isrc\vendor\imgui -MMD -MP -c src\src\Engine.cpp -o src\build\Engine.o
|
||||
[LINK] g++ src\build\Engine.o src\build\main.o src\build\Renderer.o src\build\Components\AnimationComponent.o src\build\Components\CameraComponent.o src\build\Components\LightComponent.o src\build\Components\ParticleComponent.o src\build\Components\PhysicsComponent.o src\build\Components\ScriptComponent.o src\build\Components\SpriteComponent.o src\build\Components\TextComonent.o src\build\Components\TilemapComponent.o src\build\core\utils\AssetManager.o src\build\core\utils\EngineConfig.o src\build\core\utils\ExceptionHandler.o src\build\core\utils\FileDialog.o src\build\core\utils\input.o src\build\core\utils\LoadingWindow.o src\build\core\utils\Logging.o src\build\core\utils\Profiler.o src\build\core\utils\Texture.o src\build\core\utils\utils.o src\build\editor\windows\AssetBrowser.o src\build\editor\windows\Inspector.o src\build\Entitys\Object.o src\build\utils\GameObjectsList.o src\build\utils\Shader.o src\build\utils\UID.o src\build\lapi.o src\build\lauxlib.o src\build\lbaselib.o src\build\lcode.o src\build\lcorolib.o src\build\lctype.o src\build\ldblib.o src\build\ldebug.o src\build\ldo.o src\build\ldump.o src\build\lfunc.o src\build\lgc.o src\build\linit.o src\build\liolib.o src\build\llex.o src\build\lmathlib.o src\build\lmem.o src\build\loadlib.o src\build\lobject.o src\build\lopcodes.o src\build\loslib.o src\build\lparser.o src\build\lstate.o src\build\lstring.o src\build\lstrlib.o src\build\ltable.o src\build\ltablib.o src\build\ltm.o src\build\lua.o src\build\luac.o src\build\lundump.o src\build\lutf8lib.o src\build\lvm.o src\build\lzio.o src\build\imgui.o src\build\imgui_demo.o src\build\imgui_draw.o src\build\imgui_impl_glfw.o src\build\imgui_impl_opengl3.o src\build\imgui_tables.o src\build\imgui_widgets.o src\build\aabb.o src\build\arena_allocator.o src\build\array.o src\build\bitset.o src\build\body.o src\build\broad_phase.o src\build\constraint_graph.o src\build\contact.o src\build\contact_solver.o src\build\core.o src\build\distance.o src\build\distance_joint.o src\build\dynamic_tree.o src\build\geometry.o src\build\hull.o src\build\id_pool.o src\build\island.o src\build\joint.o src\build\manifold.o src\build\math_functions.o src\build\motor_joint.o src\build\mouse_joint.o src\build\mover.o src\build\prismatic_joint.o src\build\revolute_joint.o src\build\sensor.o src\build\shape.o src\build\solver.o src\build\solver_set.o src\build\table.o src\build\timer.o src\build\types.o src\build\weld_joint.o src\build\wheel_joint.o src\build\world.o src\build\xxhash.o -o src\build\app.exe -LC:\msys64\mingw64\lib -lglfw3 -lglew32 -lopengl32 -lgdi32 -lyaml-cpp -lcomdlg32 -lssl -lcrypto
|
||||
[RUN] Executed app.exe successfully.
|
||||
[ERROR] Runtime crash
|
||||
Command 'src\build\app.exe' returned non-zero exit status 3489660927.
|
||||
|
@ -1,85 +1,110 @@
|
||||
engine_version: 0.1.0
|
||||
scene_name: test
|
||||
scene_hash: b4b8f6fe7881b1b5183673450e9a2b43fff7f5d24e88fbedf920edf09cd63fd2
|
||||
scene_hash: 2a85407931385c3ec75b04912f97447151603fb317700b3a5b33a0c86182db25
|
||||
format_version: 1
|
||||
objects:
|
||||
- name: Sprite Object
|
||||
position: [0, 0]
|
||||
- name: NewObject
|
||||
uid: dc6b14507c5f4cd6be29402f26a43bed
|
||||
id: 3
|
||||
position: [48.2000008, -72]
|
||||
rotation: 0
|
||||
layer: 0
|
||||
visable: true
|
||||
components:
|
||||
- type: CameraComponent
|
||||
fov: 45
|
||||
aspect: 1.76999998
|
||||
zoom: 1
|
||||
primary: true
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\49555.jpg
|
||||
normalMap: ""
|
||||
children:
|
||||
- name: NewObject
|
||||
position: [190, 189]
|
||||
layer: 0
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\49555.jpg
|
||||
normalMap: ""
|
||||
children: []
|
||||
- name: NewObject
|
||||
position: [0, 444]
|
||||
layer: 0
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\49555.jpg
|
||||
normalMap: ""
|
||||
children: []
|
||||
- name: World
|
||||
position: [-436, 248]
|
||||
- type: ParticleComponent
|
||||
maxParticles: 10000
|
||||
emissionRate: 10000
|
||||
lifeMin: 0.00999999978
|
||||
lifeMax: 0.800000012
|
||||
sizeMin: 5
|
||||
sizeMax: 10
|
||||
speedMin: 100
|
||||
speedMax: 300
|
||||
direction: [0, 0]
|
||||
spread: 6.28318548
|
||||
startColor: [0.0588235296, 0, 1, 1]
|
||||
endColor: [1, 0, 0.911765099, 0]
|
||||
loop: true
|
||||
burst: false
|
||||
roundness: 0
|
||||
- type: LightComponent
|
||||
color:
|
||||
- 1
|
||||
- 0
|
||||
- 0.941176414
|
||||
intensity: 1
|
||||
radius: 300
|
||||
falloff: 1
|
||||
type: 0
|
||||
children: []
|
||||
- name: NewObject
|
||||
uid: d395b3d1c59140298babbce87efbabc9
|
||||
id: 4
|
||||
position: [1028, 0]
|
||||
rotation: 0
|
||||
layer: 0
|
||||
components: []
|
||||
children:
|
||||
- name: Rocks
|
||||
position: [0, 0]
|
||||
layer: -1
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\ganges_river_pebbles_diff_1k.png
|
||||
normalMap: C:\Users\spenc\OneDrive\Pictures\ganges_river_pebbles_nor_gl_1k.png
|
||||
children: []
|
||||
- name: Bark
|
||||
position: [1024, 0]
|
||||
layer: -1
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\textures\bark_willow_02_diff_1k.png
|
||||
normalMap: C:\Users\spenc\OneDrive\Pictures\textures\bark_willow_02_nor_gl_1k.png
|
||||
children: []
|
||||
- name: Planks
|
||||
position: [0, 1024]
|
||||
layer: 0
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\textures\wood_floor_worn_diff_1k.png
|
||||
normalMap: C:\Users\spenc\OneDrive\Pictures\textures\wood_floor_worn_nor_gl_1k.png
|
||||
children: []
|
||||
- name: Metal
|
||||
position: [1024, 1024]
|
||||
layer: 0
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: C:\Users\spenc\OneDrive\Pictures\textures\metal_plate_diff_1k.png
|
||||
normalMap: C:\Users\spenc\OneDrive\Pictures\textures\metal_plate_nor_gl_1k.png
|
||||
children: []
|
||||
- name: Sun
|
||||
position: [-5000, -5000]
|
||||
layer: 1
|
||||
components:
|
||||
- type: LightComponent
|
||||
color:
|
||||
- 0.990196049
|
||||
- 0.943370163
|
||||
- 0.791186035
|
||||
intensity: 2.0999999
|
||||
radius: 100000000
|
||||
falloff: 0.100000001
|
||||
type: 0
|
||||
children: []
|
||||
visable: true
|
||||
components:
|
||||
- type: SpriteComponent
|
||||
texture: 4
|
||||
normalMap: 5
|
||||
renderType: Lit
|
||||
children: []
|
||||
color_correction:
|
||||
brightness: 1
|
||||
saturation: 1
|
||||
gamma: 1
|
||||
bloom: true
|
||||
intensity: 1.20000005
|
||||
threshold: 0.170000002
|
||||
Assets:
|
||||
- uaid: 5
|
||||
path: C:\Users\spenc\OneDrive\Pictures\textures\ganges_river_pebbles_nor_gl_1k.png
|
||||
filename: ganges_river_pebbles_nor_gl_1k.png
|
||||
filetype: png
|
||||
type: 0
|
||||
size: [1024, 1024]
|
||||
hash: 6711b00700d4c94a
|
||||
channels: 4
|
||||
format: GL_RGBA
|
||||
lastModified: 1744565594
|
||||
- uaid: 4
|
||||
path: C:\Users\spenc\OneDrive\Pictures\textures\ganges_river_pebbles_diff_1k.png
|
||||
filename: ganges_river_pebbles_diff_1k.png
|
||||
filetype: png
|
||||
type: 0
|
||||
size: [1024, 1024]
|
||||
hash: 0349580fcbf62155
|
||||
channels: 4
|
||||
format: GL_RGBA
|
||||
lastModified: 1744565605
|
||||
- uaid: 3
|
||||
path: C:\Users\spenc\OneDrive\Pictures\Pixel Holy Spell Effect 32x32 Pack 3\01.png
|
||||
filename: 01.png
|
||||
filetype: png
|
||||
type: 0
|
||||
size: [704, 576]
|
||||
hash: 82866fcf3324b785
|
||||
channels: 4
|
||||
format: GL_RGBA
|
||||
lastModified: 1687052107
|
||||
- uaid: 2
|
||||
path: C:\Users\spenc\OneDrive\Pictures\Pixel Holy Spell Effect 32x32 Pack 3\00.png
|
||||
filename: 00.png
|
||||
filetype: png
|
||||
type: 0
|
||||
size: [1216, 192]
|
||||
hash: 2b0b3c20179d6f12
|
||||
channels: 4
|
||||
format: GL_RGBA
|
||||
lastModified: 1687052065
|
||||
- uaid: 1
|
||||
path: C:\Users\spenc\OneDrive\Pictures\6656e7221e49a1774d2fb280357e56f8d25d9d95.png
|
||||
filename: 6656e7221e49a1774d2fb280357e56f8d25d9d95.png
|
||||
filetype: png
|
||||
type: 0
|
||||
size: [1024, 1024]
|
||||
hash: e8aaee6025f21557
|
||||
channels: 4
|
||||
format: GL_RGBA
|
||||
lastModified: 1744577923
|
@ -15,7 +15,6 @@
|
||||
|
||||
#include <iostream>
|
||||
|
||||
|
||||
void DrawInspectorUI(std::shared_ptr<Object> selected)
|
||||
{
|
||||
PROFILE_ENGINE_SCOPE("Engine::DrawInspectorUI");
|
||||
@ -382,7 +381,14 @@ void DrawInspectorUI(std::shared_ptr<Object> selected)
|
||||
ImGui::DragFloat("Speed Min", &settings.speedMin, 1.0f, 0.0f, 1000.0f);
|
||||
ImGui::DragFloat("Speed Max", &settings.speedMax, 1.0f, 0.0f, 1000.0f);
|
||||
ImGui::DragFloat2("Direction", &settings.direction.x, 0.01f);
|
||||
ImGui::DragFloat("Spread", &settings.spread, 0.01f, 0.0f, 3.14f);
|
||||
|
||||
{
|
||||
float spreadDeg = glm::degrees(settings.spread);
|
||||
if (ImGui::DragFloat("Spread", &spreadDeg, 0.5f, 0.0f, 360.0f))
|
||||
{
|
||||
settings.spread = glm::radians(spreadDeg);
|
||||
}
|
||||
}
|
||||
|
||||
ImGui::ColorEdit4("Start Color", &settings.startColor.r);
|
||||
ImGui::ColorEdit4("End Color", &settings.endColor.r);
|
||||
@ -475,8 +481,6 @@ void DrawInspectorUI(std::shared_ptr<Object> selected)
|
||||
{
|
||||
ImGui::SeparatorText("Atlas Preview");
|
||||
|
||||
|
||||
|
||||
ImTextureID texID = (ImTextureID)(uintptr_t)texture->GetID();
|
||||
core::types::Vec2 texSize = texture->GetSize();
|
||||
|
||||
@ -509,7 +513,6 @@ void DrawInspectorUI(std::shared_ptr<Object> selected)
|
||||
// Draw the atlas
|
||||
ImGui::Image(texID, imageSize);
|
||||
|
||||
|
||||
// Grid cell size in pixels
|
||||
float scaleX = imageSize.x / (float)texWidth;
|
||||
float scaleY = imageSize.y / (float)texHeight;
|
||||
@ -651,7 +654,6 @@ void DrawInspectorUI(std::shared_ptr<Object> selected)
|
||||
(x1 - x0 + 1) * (float)texelWidth * scaleX,
|
||||
(y1 - y0 + 1) * (float)texelHeight * scaleY);
|
||||
ImGui::Image(texID, imgSz, uv0, uv1);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -674,7 +676,6 @@ void DrawInspectorUI(std::shared_ptr<Object> selected)
|
||||
ImGui::Separator();
|
||||
}
|
||||
|
||||
|
||||
ImGui::Separator();
|
||||
if (ImGui::Button("Remove TilemapComponent"))
|
||||
selected->RemoveComponent<TilemapComponent>();
|
||||
|
Loading…
Reference in New Issue
Block a user