From a83fa69c29a654406c5615952a6a76c2ba2a647e Mon Sep 17 00:00:00 2001 From: Jens Becker Date: Sat, 25 Jul 2026 16:42:49 +0200 Subject: [PATCH] init --- .editorconfig | 4 + .gitattributes | 2 + .gitignore | 3 + .../.idea.your are an ai ceo/.idea/.gitignore | 15 ++++ .idea/.idea.your are an ai ceo/.idea/.name | 1 + .../.idea/encodings.xml | 4 + .../.idea/indexLayout.xml | 8 ++ .../.idea/libraries/GdSdk.xml | 9 ++ .idea/.idea.your are an ai ceo/.idea/vcs.xml | 6 ++ Main.tscn | 83 +++++++++++++++++++ Meeting.cs | 79 ++++++++++++++++++ Meeting.cs.uid | 1 + Meeting.tscn | 24 ++++++ MeetingControl.cs | 15 ++++ MeetingControl.cs.uid | 1 + MeetingControl.tscn | 16 ++++ TimeSlot.cs | 16 ++++ TimeSlot.cs.uid | 1 + TimeSlot.tscn | 7 ++ icon.svg | 1 + icon.svg.import | 43 ++++++++++ project.godot | 34 ++++++++ your are an ai ceo.csproj | 8 ++ your are an ai ceo.csproj.old | 8 ++ your are an ai ceo.sln | 19 +++++ 25 files changed, 408 insertions(+) create mode 100644 .editorconfig create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 .idea/.idea.your are an ai ceo/.idea/.gitignore create mode 100644 .idea/.idea.your are an ai ceo/.idea/.name create mode 100644 .idea/.idea.your are an ai ceo/.idea/encodings.xml create mode 100644 .idea/.idea.your are an ai ceo/.idea/indexLayout.xml create mode 100644 .idea/.idea.your are an ai ceo/.idea/libraries/GdSdk.xml create mode 100644 .idea/.idea.your are an ai ceo/.idea/vcs.xml create mode 100644 Main.tscn create mode 100644 Meeting.cs create mode 100644 Meeting.cs.uid create mode 100644 Meeting.tscn create mode 100644 MeetingControl.cs create mode 100644 MeetingControl.cs.uid create mode 100644 MeetingControl.tscn create mode 100644 TimeSlot.cs create mode 100644 TimeSlot.cs.uid create mode 100644 TimeSlot.tscn create mode 100644 icon.svg create mode 100644 icon.svg.import create mode 100644 project.godot create mode 100644 your are an ai ceo.csproj create mode 100644 your are an ai ceo.csproj.old create mode 100644 your are an ai ceo.sln diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..f28239b --- /dev/null +++ b/.editorconfig @@ -0,0 +1,4 @@ +root = true + +[*] +charset = utf-8 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..8ad74f7 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Normalize EOL for all files that Git considers text files. +* text=auto eol=lf diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..0af181c --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +# Godot 4+ specific ignores +.godot/ +/android/ diff --git a/.idea/.idea.your are an ai ceo/.idea/.gitignore b/.idea/.idea.your are an ai ceo/.idea/.gitignore new file mode 100644 index 0000000..d155a63 --- /dev/null +++ b/.idea/.idea.your are an ai ceo/.idea/.gitignore @@ -0,0 +1,15 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Rider ignored files +/projectSettingsUpdater.xml +/.idea.your are an ai ceo.iml +/contentModel.xml +/modules.xml +# Editor-based HTTP Client requests +/httpRequests/ +# Ignored default folder with query files +/queries/ +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml diff --git a/.idea/.idea.your are an ai ceo/.idea/.name b/.idea/.idea.your are an ai ceo/.idea/.name new file mode 100644 index 0000000..fefcc0d --- /dev/null +++ b/.idea/.idea.your are an ai ceo/.idea/.name @@ -0,0 +1 @@ +your are an ai ceo \ No newline at end of file diff --git a/.idea/.idea.your are an ai ceo/.idea/encodings.xml b/.idea/.idea.your are an ai ceo/.idea/encodings.xml new file mode 100644 index 0000000..df87cf9 --- /dev/null +++ b/.idea/.idea.your are an ai ceo/.idea/encodings.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/.idea/.idea.your are an ai ceo/.idea/indexLayout.xml b/.idea/.idea.your are an ai ceo/.idea/indexLayout.xml new file mode 100644 index 0000000..7b08163 --- /dev/null +++ b/.idea/.idea.your are an ai ceo/.idea/indexLayout.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/.idea.your are an ai ceo/.idea/libraries/GdSdk.xml b/.idea/.idea.your are an ai ceo/.idea/libraries/GdSdk.xml new file mode 100644 index 0000000..0059883 --- /dev/null +++ b/.idea/.idea.your are an ai ceo/.idea/libraries/GdSdk.xml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/.idea.your are an ai ceo/.idea/vcs.xml b/.idea/.idea.your are an ai ceo/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/.idea.your are an ai ceo/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/Main.tscn b/Main.tscn new file mode 100644 index 0000000..ac76cad --- /dev/null +++ b/Main.tscn @@ -0,0 +1,83 @@ +[gd_scene format=3 uid="uid://b2rl7r8oav3hy"] + +[ext_resource type="PackedScene" uid="uid://dciugg77wsy6p" path="res://Meeting.tscn" id="1_glv2v"] +[ext_resource type="Script" uid="uid://dldaxqajhnnva" path="res://TimeSlot.cs" id="2_r0du0"] +[ext_resource type="PackedScene" uid="uid://do8ll0kylvrcn" path="res://MeetingControl.tscn" id="2_uu6xs"] + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_sko1m"] +size = Vector2(575, 20) + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_ig7tw"] +size = Vector2(21.5, 1920) + +[node name="Main" type="Node2D" unique_id=287617203] + +[node name="MeetingControl" parent="." unique_id=11410047 instance=ExtResource("2_uu6xs")] +anchors_preset = 8 +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +offset_left = 631.0 +offset_top = 18.0 +offset_right = 960.0 +offset_bottom = 98.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_default_cursor_shape = 2 +metadata/_edit_use_anchors_ = true + +[node name="Control" type="Control" parent="." unique_id=1593899] +layout_mode = 3 +anchors_preset = 0 +offset_left = 114.0 +offset_top = 34.0 +offset_right = 514.0 +offset_bottom = 603.0 + +[node name="PanelContainer" type="PanelContainer" parent="Control" unique_id=1636973054] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -1.0 +offset_right = -1.0 +grow_horizontal = 2 +grow_vertical = 2 + +[node name="VBoxContainer" type="VBoxContainer" parent="Control/PanelContainer" unique_id=1658498861] +layout_mode = 2 + +[node name="TimeSlot" type="PanelContainer" parent="Control/PanelContainer/VBoxContainer" unique_id=1554329623] +custom_minimum_size = Vector2(0, 74) +layout_mode = 2 +script = ExtResource("2_r0du0") + +[node name="Box" type="StaticBody2D" parent="." unique_id=56956355] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Box" unique_id=220723577] +position = Vector2(843, 611) +shape = SubResource("RectangleShape2D_sko1m") + +[node name="CollisionShape2D4" type="CollisionShape2D" parent="Box" unique_id=416813543] +position = Vector2(844, -1289) +shape = SubResource("RectangleShape2D_sko1m") + +[node name="CollisionShape2D2" type="CollisionShape2D" parent="Box" unique_id=240246518] +position = Vector2(566.25, -339) +shape = SubResource("RectangleShape2D_ig7tw") + +[node name="CollisionShape2D3" type="CollisionShape2D" parent="Box" unique_id=297721234] +position = Vector2(1120, -339) +shape = SubResource("RectangleShape2D_ig7tw") + +[node name="Meeting" parent="." unique_id=796440984 instance=ExtResource("1_glv2v")] +position = Vector2(749, 176) + +[node name="Meeting2" parent="." unique_id=1691479453 instance=ExtResource("1_glv2v")] +position = Vector2(957, 231.99998) +rotation = -0.5541229 + +[node name="Meeting3" parent="." unique_id=673551448 instance=ExtResource("1_glv2v")] +position = Vector2(782.9999, 402.99997) +rotation = -0.18364333 diff --git a/Meeting.cs b/Meeting.cs new file mode 100644 index 0000000..3d5ea5c --- /dev/null +++ b/Meeting.cs @@ -0,0 +1,79 @@ +using System; +using Godot; + +public partial class Meeting : RigidBody2D +{ + private bool _mouseInside; + private bool _isDragging; + private Vector2 _dragTarget; + + public override void _Ready() + { + FreezeMode = FreezeModeEnum.Kinematic; + + MouseEntered += () => + { + _mouseInside = true; + CanSleep = false; + }; + MouseExited += () => + { + _mouseInside = false; + CanSleep = true; + }; + } + + public override void _UnhandledInput(InputEvent @event) + { + // TODO: probably memory problem + if (@event is InputEventMouse mouseEvent) + { + if (_mouseInside) + { + if (mouseEvent.IsPressed() && mouseEvent.ButtonMask == MouseButtonMask.Left) + { + GD.Print("Start Dragging"); + StartDragging(); + } + } + } + + if (_isDragging && @event is InputEventMouseButton { Pressed: false }) + { + GD.Print("Let me free"); + StopDragging(); + } + } + + public override void _PhysicsProcess(double delta) + { + _dragTarget = GetGlobalMousePosition(); + } + + public override void _IntegrateForces(PhysicsDirectBodyState2D state) + { + if (!_isDragging) + return; + + var t = state.Transform; + t.Origin = _dragTarget; + + state.Transform = t; + state.LinearVelocity = Vector2.Zero; + state.AngularVelocity = 0; + } + + private void StartDragging() + { + Freeze = true; + _isDragging = true; + CollisionLayer = 0; + } + + private void StopDragging() + { + Freeze = false; + _isDragging = false; + CollisionLayer = 1; + } +} diff --git a/Meeting.cs.uid b/Meeting.cs.uid new file mode 100644 index 0000000..126f9e4 --- /dev/null +++ b/Meeting.cs.uid @@ -0,0 +1 @@ +uid://cit20jyhj41rs diff --git a/Meeting.tscn b/Meeting.tscn new file mode 100644 index 0000000..0ec959c --- /dev/null +++ b/Meeting.tscn @@ -0,0 +1,24 @@ +[gd_scene format=3 uid="uid://dciugg77wsy6p"] + +[ext_resource type="Script" uid="uid://cit20jyhj41rs" path="res://Meeting.cs" id="1_1rolt"] +[ext_resource type="Texture2D" uid="uid://dyxftkkuf7h7w" path="res://icon.svg" id="1_2t4nr"] + +[sub_resource type="PhysicsMaterial" id="PhysicsMaterial_glv2v"] +bounce = 0.1 + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_boq60"] +size = Vector2(294, 72) + +[node name="Meeting" type="RigidBody2D" unique_id=796440984] +input_pickable = true +physics_material_override = SubResource("PhysicsMaterial_glv2v") +freeze_mode = 1 +continuous_cd = 2 +script = ExtResource("1_1rolt") + +[node name="Icon" type="Sprite2D" parent="." unique_id=1878852055] +scale = Vector2(2.3203125, 0.6015625) +texture = ExtResource("1_2t4nr") + +[node name="CollisionShape2D" type="CollisionShape2D" parent="." unique_id=235269066] +shape = SubResource("RectangleShape2D_boq60") diff --git a/MeetingControl.cs b/MeetingControl.cs new file mode 100644 index 0000000..64bc862 --- /dev/null +++ b/MeetingControl.cs @@ -0,0 +1,15 @@ +using Godot; + +public sealed partial class MeetingControlDragData : GodotObject { } + +public partial class MeetingControl : PanelContainer +{ + public override Variant _GetDragData(Vector2 atPosition) + { + GD.Print("CONTROL DRAG"); + var copy = Duplicate() as MeetingControl; + SetDragPreview(copy); + + return Variant.From(new MeetingControlDragData()); + } +} diff --git a/MeetingControl.cs.uid b/MeetingControl.cs.uid new file mode 100644 index 0000000..570d95a --- /dev/null +++ b/MeetingControl.cs.uid @@ -0,0 +1 @@ +uid://ctl23v8cgy4k3 diff --git a/MeetingControl.tscn b/MeetingControl.tscn new file mode 100644 index 0000000..4e6415b --- /dev/null +++ b/MeetingControl.tscn @@ -0,0 +1,16 @@ +[gd_scene format=3 uid="uid://do8ll0kylvrcn"] + +[ext_resource type="Script" uid="uid://ctl23v8cgy4k3" path="res://MeetingControl.cs" id="1_o5h3n"] +[ext_resource type="Texture2D" uid="uid://dyxftkkuf7h7w" path="res://icon.svg" id="1_o8u20"] + +[node name="MeetingControl" type="PanelContainer" unique_id=508053904] +custom_minimum_size = Vector2(10.74, 9.49) +offset_right = 329.0 +offset_bottom = 80.0 +size_flags_horizontal = 3 +script = ExtResource("1_o5h3n") + +[node name="Icon" type="Sprite2D" parent="." unique_id=1047834216] +position = Vector2(36.999996, 37) +scale = Vector2(0.390625, 0.390625) +texture = ExtResource("1_o8u20") diff --git a/TimeSlot.cs b/TimeSlot.cs new file mode 100644 index 0000000..2f2ef6a --- /dev/null +++ b/TimeSlot.cs @@ -0,0 +1,16 @@ +using Godot; + +public partial class TimeSlot : PanelContainer +{ + public override bool _CanDropData(Vector2 atPosition, Variant data) + { + GD.Print("DRAGGED OVERR!!!"); + return data.VariantType == Variant.Type.Object + && data.AsGodotObject() is MeetingControlDragData; + } + + public override void _DropData(Vector2 atPosition, Variant data) + { + GD.Print("DROP"); + } +} diff --git a/TimeSlot.cs.uid b/TimeSlot.cs.uid new file mode 100644 index 0000000..ba0ecb4 --- /dev/null +++ b/TimeSlot.cs.uid @@ -0,0 +1 @@ +uid://dldaxqajhnnva diff --git a/TimeSlot.tscn b/TimeSlot.tscn new file mode 100644 index 0000000..313ca9b --- /dev/null +++ b/TimeSlot.tscn @@ -0,0 +1,7 @@ +[gd_scene format=3 uid="uid://nnr6u0igggve"] + +[ext_resource type="Script" uid="uid://dldaxqajhnnva" path="res://TimeSlot.cs" id="1_50jir"] + +[node name="TimeSlot" type="PanelContainer" unique_id=979842204] +custom_minimum_size = Vector2(0, 74) +script = ExtResource("1_50jir") diff --git a/icon.svg b/icon.svg new file mode 100644 index 0000000..c6bbb7d --- /dev/null +++ b/icon.svg @@ -0,0 +1 @@ + diff --git a/icon.svg.import b/icon.svg.import new file mode 100644 index 0000000..4c7cd08 --- /dev/null +++ b/icon.svg.import @@ -0,0 +1,43 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dyxftkkuf7h7w" +path="res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://icon.svg" +dest_files=["res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/uastc_level=0 +compress/rdo_quality_loss=0.0 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/channel_remap/red=0 +process/channel_remap/green=1 +process/channel_remap/blue=2 +process/channel_remap/alpha=3 +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/project.godot b/project.godot new file mode 100644 index 0000000..9904eb0 --- /dev/null +++ b/project.godot @@ -0,0 +1,34 @@ +; Engine configuration file. +; It's best edited using the editor UI and not directly, +; since the parameters that go here are not all obvious. +; +; Format: +; [section] ; section goes between [] +; param=value ; assign values to parameters + +config_version=5 + +[application] + +config/name="your are an ai ceo" +run/main_scene="uid://b2rl7r8oav3hy" +config/features=PackedStringArray("4.7", "C#", "Forward Plus") +config/icon="res://icon.svg" + +[display] + +window/stretch/mode="canvas_items" +window/stretch/aspect="expand" + +[dotnet] + +project/assembly_name="your are an ai ceo" + +[physics] + +2d/run_on_separate_thread=true +3d/physics_engine="Jolt Physics" + +[rendering] + +rendering_device/driver.windows="d3d12" diff --git a/your are an ai ceo.csproj b/your are an ai ceo.csproj new file mode 100644 index 0000000..5a8f873 --- /dev/null +++ b/your are an ai ceo.csproj @@ -0,0 +1,8 @@ + + + net8.0 + net9.0 + true + yourareanaiceo + + \ No newline at end of file diff --git a/your are an ai ceo.csproj.old b/your are an ai ceo.csproj.old new file mode 100644 index 0000000..cdb59ee --- /dev/null +++ b/your are an ai ceo.csproj.old @@ -0,0 +1,8 @@ + + + net8.0 + net9.0 + true + yourareanaiceo + + \ No newline at end of file diff --git a/your are an ai ceo.sln b/your are an ai ceo.sln new file mode 100644 index 0000000..e620793 --- /dev/null +++ b/your are an ai ceo.sln @@ -0,0 +1,19 @@ +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 2012 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "your are an ai ceo", "your are an ai ceo.csproj", "{14ED9EF7-626E-4207-89C0-D22BC4CE0310}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + ExportDebug|Any CPU = ExportDebug|Any CPU + ExportRelease|Any CPU = ExportRelease|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {14ED9EF7-626E-4207-89C0-D22BC4CE0310}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {14ED9EF7-626E-4207-89C0-D22BC4CE0310}.Debug|Any CPU.Build.0 = Debug|Any CPU + {14ED9EF7-626E-4207-89C0-D22BC4CE0310}.ExportDebug|Any CPU.ActiveCfg = ExportDebug|Any CPU + {14ED9EF7-626E-4207-89C0-D22BC4CE0310}.ExportDebug|Any CPU.Build.0 = ExportDebug|Any CPU + {14ED9EF7-626E-4207-89C0-D22BC4CE0310}.ExportRelease|Any CPU.ActiveCfg = ExportRelease|Any CPU + {14ED9EF7-626E-4207-89C0-D22BC4CE0310}.ExportRelease|Any CPU.Build.0 = ExportRelease|Any CPU + EndGlobalSection +EndGlobal