diff --git a/.github/workflows/build-prod.yml b/.github/workflows/build-prod.yml index 1bc165d..ced0f5d 100644 --- a/.github/workflows/build-prod.yml +++ b/.github/workflows/build-prod.yml @@ -62,6 +62,8 @@ jobs: sed -i 's/singleInstancePerTask/singleTask/g' ./android/build/AndroidManifest.xml + sed -i 's/BUILD_VERSION/${{ github.ref_name }}/g' ./android/build/AndroidManifest.xml + - name: export game id: export # Use latest version (see releases for all versions) diff --git a/README.md b/README.md index ac426b8..3f0158d 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,15 @@ Immersive Home is project to bring Smart Home and Mixed Reality technologies tog **Mixed Reality Headsets** - Meta Quest 2 / Pro / 3 +## Connecting to your Home Assistant Instance +Right now, as a temporary solution, the app will use whatever is saved into your clipboard to connect to your Home Assistant instance. +Format: `ws://:/api/websocket ` +Example `ws://192.168.0.31:8123/api/websocket eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiIzZjQ0ZGM2N2Y3YzY0MDc1OGZlMWI2ZjJlNmIxZjRkNSIsImlhdCI6MTY5ODAxMDcyOCwiZXhwIjoyMDEzMzcwNzI4fQ.K6ydLUC-4Q7BNIRCU1nWlI2s6sg9UCiOu-Lpedw2zJc` + +To generate a HASS token, login into your dashboard, click on your name (bottom left), scroll down and create a long-lived access token. + +You can check if you are properly connected by opening the settings tab in the app and looking at the bottom right corner. + # 🛠 Development In order to contribute to this project, you need the following to be setup before you can start working: @@ -118,6 +127,12 @@ The `Movable` node allows to move a node around in the room. It uses the grab ev The `Clickable` allows to access events of the parent using signals this node emits. +## Installing Locally +1. Make sure Git LFS is installed +2. Run `git clone https://github.com/Nitwel/Immersive-Home.git` in your terminal +3. Import the created `Immersive-Home` folder in Godot +4. Open the project in Godot 4.1.3 + ### Testing without a VR Headset In order to test without a headset, press the run project (F5) button in Godot and ignore the prompt that OpenXR failed to start. @@ -126,19 +141,16 @@ Click at the link to get a list of the supported controls. ## Building -1. Clone the repo from GitHub - - Make sure, Git LFS is installed -2. Open the project in Godot 4.1.3 -3. Possibly fix importing scenes error -4. Follow the following guide to setup exporting for android. [link](https://docs.godotengine.org/en/stable/tutorials/export/exporting_for_android.html) -5. Make sure to reuse any existing `debug.keystore` when updating an app -6. Don't forget to set the JAVA_HOME variable and restart Godot to take effect -7. Install the `Godot XR Android OpenXR Loaders` plugin in Godot -8. Configure the following in the android build template: +1. Possibly fix importing scenes error +2. Follow the following guide to setup exporting for android. [link](https://docs.godotengine.org/en/stable/tutorials/export/exporting_for_android.html) +3. Make sure to reuse any existing `debug.keystore` when updating an app +4. Don't forget to set the JAVA_HOME variable and restart Godot to take effect +5. Install the `Godot XR Android OpenXR Loaders` plugin in Godot +6. Configure the following in the android build template: - XRMode set to OpenXR - Check `Use Grandle Build` - Check `Godot OpenXR Meta` - In XRFeatures, select at least optional for passthrough - Ckeck Internet under the permissions - Under Resources > Filters to export, add `*.j2` -9. `` can be added to the `AndroidManifest.xml` to disable the boundary system. \ No newline at end of file +7. `` can be added to the `AndroidManifest.xml` to disable the boundary system. \ No newline at end of file diff --git a/assets/design.afdesign b/assets/design.afdesign index b194bf6..d8ce1f5 100644 --- a/assets/design.afdesign +++ b/assets/design.afdesign @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:73572171e36cd0fe5a0b2cf38e42d871f16b086b0e5d9c9084db451d88496dd0 -size 3271063 +oid sha256:8bc1c66cc868d68efe828c304c6ed348136cdfd8b814fe0f243954f328648997 +size 3586528 diff --git a/assets/meta/CoverArt-Landscape.png.import b/assets/meta/CoverArt-Landscape.png.import new file mode 100644 index 0000000..d3a4273 --- /dev/null +++ b/assets/meta/CoverArt-Landscape.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bj7l6xbthai84" +path="res://.godot/imported/CoverArt-Landscape.png-838d0cc063397794d98c537171909ab0.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/CoverArt-Landscape.png" +dest_files=["res://.godot/imported/CoverArt-Landscape.png-838d0cc063397794d98c537171909ab0.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/CoverArt-Mini-Landscape.png.import b/assets/meta/CoverArt-Mini-Landscape.png.import new file mode 100644 index 0000000..f94a4ca --- /dev/null +++ b/assets/meta/CoverArt-Mini-Landscape.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://4ho7auveslpl" +path="res://.godot/imported/CoverArt-Mini-Landscape.png-57b3f794ce8d721df950cf31a1cb6731.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/CoverArt-Mini-Landscape.png" +dest_files=["res://.godot/imported/CoverArt-Mini-Landscape.png-57b3f794ce8d721df950cf31a1cb6731.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/CoverArt-Portrait.png.import b/assets/meta/CoverArt-Portrait.png.import new file mode 100644 index 0000000..f9a062f --- /dev/null +++ b/assets/meta/CoverArt-Portrait.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://blxbtygswn3kd" +path="res://.godot/imported/CoverArt-Portrait.png-3caa622f8546bbdd37b0e780e2be3b60.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/CoverArt-Portrait.png" +dest_files=["res://.godot/imported/CoverArt-Portrait.png-3caa622f8546bbdd37b0e780e2be3b60.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/CoverArt-Square.png.import b/assets/meta/CoverArt-Square.png.import new file mode 100644 index 0000000..2a00f57 --- /dev/null +++ b/assets/meta/CoverArt-Square.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cq2r57mv6b3al" +path="res://.godot/imported/CoverArt-Square.png-4a3e669c3da7ec7787fa88bdef1e3dbf.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/CoverArt-Square.png" +dest_files=["res://.godot/imported/CoverArt-Square.png-4a3e669c3da7ec7787fa88bdef1e3dbf.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/Hero-Cover.png.import b/assets/meta/Hero-Cover.png.import new file mode 100644 index 0000000..63c7664 --- /dev/null +++ b/assets/meta/Hero-Cover.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bvcwq8shm6dt4" +path="res://.godot/imported/Hero-Cover.png-a37c2ac0e44cff1ea12e1a23f1df9d21.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/Hero-Cover.png" +dest_files=["res://.godot/imported/Hero-Cover.png-a37c2ac0e44cff1ea12e1a23f1df9d21.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/Screenshot 1.png.import b/assets/meta/Screenshot 1.png.import new file mode 100644 index 0000000..b7c7745 --- /dev/null +++ b/assets/meta/Screenshot 1.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://du0i6fyg1yyjq" +path="res://.godot/imported/Screenshot 1.png-4e14370c79c1580b9350ca40d2e9912d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/Screenshot 1.png" +dest_files=["res://.godot/imported/Screenshot 1.png-4e14370c79c1580b9350ca40d2e9912d.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/Screenshot 2.png.import b/assets/meta/Screenshot 2.png.import new file mode 100644 index 0000000..13bbea8 --- /dev/null +++ b/assets/meta/Screenshot 2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cyokkdunbhsk2" +path="res://.godot/imported/Screenshot 2.png-192d8533172ab5fd97651c1faf74178f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/Screenshot 2.png" +dest_files=["res://.godot/imported/Screenshot 2.png-192d8533172ab5fd97651c1faf74178f.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/Screenshot 3.png.import b/assets/meta/Screenshot 3.png.import new file mode 100644 index 0000000..497317c --- /dev/null +++ b/assets/meta/Screenshot 3.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://biv4vol8543xv" +path="res://.godot/imported/Screenshot 3.png-1abf1357b77ff44fd31e6100e0dad8c5.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/Screenshot 3.png" +dest_files=["res://.godot/imported/Screenshot 3.png-1abf1357b77ff44fd31e6100e0dad8c5.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/Screenshot 4.png.import b/assets/meta/Screenshot 4.png.import new file mode 100644 index 0000000..a9918f0 --- /dev/null +++ b/assets/meta/Screenshot 4.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dqulep5utpch6" +path="res://.godot/imported/Screenshot 4.png-7ce0a7854309a0941d4cb92c0db7ee80.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/Screenshot 4.png" +dest_files=["res://.godot/imported/Screenshot 4.png-7ce0a7854309a0941d4cb92c0db7ee80.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/Screenshot 5.png.import b/assets/meta/Screenshot 5.png.import new file mode 100644 index 0000000..329afcd --- /dev/null +++ b/assets/meta/Screenshot 5.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://tvoecd3eo1w" +path="res://.godot/imported/Screenshot 5.png-8283966445efc5a177e4c8b1871f8710.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/Screenshot 5.png" +dest_files=["res://.godot/imported/Screenshot 5.png-8283966445efc5a177e4c8b1871f8710.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/meta/logo.png.import b/assets/meta/logo.png.import new file mode 100644 index 0000000..42c15ec --- /dev/null +++ b/assets/meta/logo.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://6fishnd1cba0" +path="res://.godot/imported/logo.png-07ac03f94599d3012ec38356156e0d9f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/meta/logo.png" +dest_files=["res://.godot/imported/logo.png-07ac03f94599d3012ec38356156e0d9f.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/content/ui/keyboard/keyboard.gd b/content/ui/keyboard/keyboard.gd new file mode 100644 index 0000000..ca9b60e --- /dev/null +++ b/content/ui/keyboard/keyboard.gd @@ -0,0 +1,51 @@ +extends Node3D + +const button_scene = preload("res://content/ui/components/button/button.tscn") + +@onready var keys = $Keys +@onready var caps_button = $Caps +var key_list = [ + ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "~"], + ["Q", "W", "E", "R", "T", "Y", "U", "I", "O", "P", "/"], + ["A", "S", "D", "F", "G", "H", "J", "K", "L", ":", "\\"], + ["Z", "X", "C", "V", "B", "N", "M", ",", ".", "-"] +] + +var caps = false + +func _ready(): + for row in key_list: + for key in row: + print(key) + var button = create_key(key) + keys.add_child(button) + + keys.columns = key_list[0].size() + +func _on_click(event): + if event.target == caps_button: + caps = event.active + return + + var code = event.target.get_children()[event.target.get_child_count() - 1].text + + if caps: + code = code.to_upper() + else: + code = code.to_lower() + + Events.typed.emit(code) + print(code) + +func create_key(key: String): + var button = button_scene.instantiate() + + var label = Label3D.new() + label.text = key + label.pixel_size = 0.001 + label.position = Vector3(0, 0.012, 0) + label.rotate_x(deg_to_rad(-90)) + + button.add_child(label) + + return button diff --git a/content/ui/keyboard/keyboard.tscn b/content/ui/keyboard/keyboard.tscn new file mode 100644 index 0000000..721e0bd --- /dev/null +++ b/content/ui/keyboard/keyboard.tscn @@ -0,0 +1,23 @@ +[gd_scene load_steps=4 format=3 uid="uid://lrehk38exd5n"] + +[ext_resource type="Script" path="res://content/ui/keyboard/keyboard.gd" id="1_maojw"] +[ext_resource type="PackedScene" uid="uid://bsjqdvkt0u87c" path="res://content/ui/components/button/button.tscn" id="1_xdpwr"] +[ext_resource type="Script" path="res://content/ui/menu/grid.gd" id="3_mx544"] + +[node name="Keyboard" type="Node3D"] +script = ExtResource("1_maojw") + +[node name="Caps" parent="." instance=ExtResource("1_xdpwr")] +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0668889, 0, 0.03) +toggleable = true + +[node name="Label3D" type="Label3D" parent="Caps"] +transform = Transform3D(1, 0, 0, 0, -4.37114e-08, 1, 0, -1, -4.37114e-08, 0, 0.012, 0) +pixel_size = 0.001 +text = "caps" + +[node name="Keys" type="Node3D" parent="."] +script = ExtResource("3_mx544") +columns = 1 +depth_gap = 0.06 +size = Vector3(0.6, 1, 1) diff --git a/content/ui/menu/menu.tscn b/content/ui/menu/menu.tscn index e19416a..6f80042 100644 --- a/content/ui/menu/menu.tscn +++ b/content/ui/menu/menu.tscn @@ -15,6 +15,54 @@ [sub_resource type="BoxMesh" id="BoxMesh_08du6"] size = Vector3(0.3, 0.01, 0.3) +[sub_resource type="Animation" id="Animation_61md4"] +length = 0.001 +tracks/0/type = "bezier" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("AnimationContainer:scale:x") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"handle_modes": PackedInt32Array(0), +"points": PackedFloat32Array(1, -0.25, 0, 0.25, 0), +"times": PackedFloat32Array(0) +} +tracks/1/type = "bezier" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("AnimationContainer:scale:y") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"handle_modes": PackedInt32Array(0), +"points": PackedFloat32Array(1, -0.25, 0, 0.25, 0), +"times": PackedFloat32Array(0) +} +tracks/2/type = "bezier" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("AnimationContainer:scale:z") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"handle_modes": PackedInt32Array(0), +"points": PackedFloat32Array(1, -0.25, 0, 0.25, 0), +"times": PackedFloat32Array(0) +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("AnimationContainer:visible") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [true] +} + [sub_resource type="Animation" id="Animation_lkh72"] resource_name = "hide_menu" length = 0.4 @@ -98,54 +146,6 @@ tracks/6/keys = { "values": [true, false] } -[sub_resource type="Animation" id="Animation_61md4"] -length = 0.001 -tracks/0/type = "bezier" -tracks/0/imported = false -tracks/0/enabled = true -tracks/0/path = NodePath("AnimationContainer:scale:x") -tracks/0/interp = 1 -tracks/0/loop_wrap = true -tracks/0/keys = { -"handle_modes": PackedInt32Array(0), -"points": PackedFloat32Array(1, -0.25, 0, 0.25, 0), -"times": PackedFloat32Array(0) -} -tracks/1/type = "bezier" -tracks/1/imported = false -tracks/1/enabled = true -tracks/1/path = NodePath("AnimationContainer:scale:y") -tracks/1/interp = 1 -tracks/1/loop_wrap = true -tracks/1/keys = { -"handle_modes": PackedInt32Array(0), -"points": PackedFloat32Array(1, -0.25, 0, 0.25, 0), -"times": PackedFloat32Array(0) -} -tracks/2/type = "bezier" -tracks/2/imported = false -tracks/2/enabled = true -tracks/2/path = NodePath("AnimationContainer:scale:z") -tracks/2/interp = 1 -tracks/2/loop_wrap = true -tracks/2/keys = { -"handle_modes": PackedInt32Array(0), -"points": PackedFloat32Array(1, -0.25, 0, 0.25, 0), -"times": PackedFloat32Array(0) -} -tracks/3/type = "value" -tracks/3/imported = false -tracks/3/enabled = true -tracks/3/path = NodePath("AnimationContainer:visible") -tracks/3/interp = 1 -tracks/3/loop_wrap = true -tracks/3/keys = { -"times": PackedFloat32Array(0), -"transitions": PackedFloat32Array(1), -"update": 1, -"values": [true] -} - [sub_resource type="AnimationLibrary" id="AnimationLibrary_s30cd"] _data = { "RESET": SubResource("Animation_61md4"), diff --git a/content/ui/menu/room/room_menu.gd b/content/ui/menu/room/room_menu.gd index 0af5ed3..144b8f2 100644 --- a/content/ui/menu/room/room_menu.gd +++ b/content/ui/menu/room/room_menu.gd @@ -32,6 +32,10 @@ func _ready(): wall_corners.visible = false wall_edges.visible = false wall_mesh.mesh = generate_mesh() + + if wall_mesh.mesh == null: + return + var collisions = generate_collision(wall_mesh.mesh) for old_coll in wall_collisions.get_children(): diff --git a/export_presets_prod.cfg b/export_presets_prod.cfg index 2518add..9ba8701 100644 --- a/export_presets_prod.cfg +++ b/export_presets_prod.cfg @@ -31,7 +31,7 @@ architectures/arm64-v8a=true architectures/x86=false architectures/x86_64=false version/code=3 -version/name="v0.1.2" +version/name="BUILD_VERSION" package/unique_name="de.nitwel.$genname" package/name="Immersive Home" package/signed=true diff --git a/lib/globals/events.gd b/lib/globals/events.gd index 5abf48a..6fa7e02 100644 --- a/lib/globals/events.gd +++ b/lib/globals/events.gd @@ -10,4 +10,6 @@ signal on_grab_down(event: Dictionary) signal on_grab_move(event: Dictionary) signal on_grab_up(event: Dictionary) signal on_ray_enter(event: Dictionary) -signal on_ray_leave(event: Dictionary) \ No newline at end of file +signal on_ray_leave(event: Dictionary) + +signal typed(key: String) \ No newline at end of file diff --git a/lib/home_adapters/adapter.gd b/lib/home_adapters/adapter.gd index 430d702..e330a4d 100644 --- a/lib/home_adapters/adapter.gd +++ b/lib/home_adapters/adapter.gd @@ -24,7 +24,16 @@ const methods = [ var adapter: Node func _init(type: ADAPTER_TYPES): - adapter = adapters[type].new() + + var clipboard := DisplayServer.clipboard_get() + + if clipboard != null && clipboard.find(" ") != -1: + var clip_url = clipboard.split(" ")[0] + var clip_token = clipboard.split(" ")[1] + adapter = adapters[type].new(clip_url, clip_token) + else: + adapter = adapters[type].new() + add_child(adapter) for method in methods: diff --git a/lib/home_adapters/hass_ws/hass.gd b/lib/home_adapters/hass_ws/hass.gd index 74becec..7479829 100644 --- a/lib/home_adapters/hass_ws/hass.gd +++ b/lib/home_adapters/hass_ws/hass.gd @@ -5,11 +5,10 @@ var socket := WebSocketPeer.new() # in seconds var request_timeout := 10.0 -var url := "ws://192.168.33.33:8123/api/websocket" -var token := "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiIzZjQ0ZGM2N2Y3YzY0MDc1OGZlMWI2ZjJlNmIxZjRkNSIsImlhdCI6MTY5ODAxMDcyOCwiZXhwIjoyMDEzMzcwNzI4fQ.K6ydLUC-4Q7BNIRCU1nWlI2s6sg9UCiOu-Lpedw2zJc" - # var url := "wss://8ybjhqcinfcdyvzu.myfritz.net:8123/api/websocket" -# var token := "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJjNjU0ZDE3NDc2ZGM0NzU1OGY5NjIzMmM5ZjdjYzE2YSIsImlhdCI6MTY5OTgyMzcxOCwiZXhwIjoyMDE1MTgzNzE4fQ.XHlfnXUd16HaV9XjYrxzuNg23nFFeoEsIsaMVXwRkd8" +var url := "" +var token := "" + var LOG_MESSAGES := false