Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6d50a76cff | ||
|
|
1d8d47a248 |
No files matched your search
@@ -2,6 +2,12 @@
|
|||||||
|
|
||||||
- 11.2.2024
|
- 11.2.2024
|
||||||
|
|
||||||
|
## Optat se
|
||||||
|
|
||||||
|
- Udělám pár technických vylepšení a jinak se zaměřím na DX portálů - gizma, guidy, procedural mesh
|
||||||
|
- Téma DP do IS?
|
||||||
|
- Kdy se odevzdává DP?
|
||||||
|
|
||||||
## Poznámky k implementaci
|
## Poznámky k implementaci
|
||||||
|
|
||||||
### 5 roomka
|
### 5 roomka
|
||||||
@@ -12,6 +18,11 @@ venkovního úhlu. Protože reálně jsem od něj mega daleko, takže portálov
|
|||||||
### Island level
|
### Island level
|
||||||
|
|
||||||
- Dolní collider jsem musel hodně zvětšit aby skrz něj hráč neproletěl během 1 physics framu
|
- Dolní collider jsem musel hodně zvětšit aby skrz něj hráč neproletěl během 1 physics framu
|
||||||
|
- Horní jsem musel trochu potočit, jinak se hráč objevil zrcadlově??
|
||||||
|
- Zapnout/Vypnout tadyto *proporční* teleportování? V MC se člověk objeví asi uprostřed nether
|
||||||
|
portálu i když je kde chce
|
||||||
|
- Kdybych chtěl mesh do dveří (oblouk), možná by bylo jednodušší udělat masku než spešl mesh.
|
||||||
|
Viewport je čtveratý tak jako tak.
|
||||||
|
|
||||||
### Semafor
|
### Semafor
|
||||||
|
|
||||||
@@ -20,3 +31,4 @@ venkovního úhlu. Protože reálně jsem od něj mega daleko, takže portálov
|
|||||||
- Zkusil jsem vymodelovat vlastní mesh v blenderu. Moc to nefunguje, Godot je asi zmatený z toho
|
- Zkusil jsem vymodelovat vlastní mesh v blenderu. Moc to nefunguje, Godot je asi zmatený z toho
|
||||||
že on má Y-up a Blender používá Z-up. V portal repu je k tomu poznámka ale nepochopil jsem to asi.
|
že on má Y-up a Blender používá Z-up. V portal repu je k tomu poznámka ale nepochopil jsem to asi.
|
||||||
- Divně se na ten mesh pak projektuje ta textura kamery??
|
- Divně se na ten mesh pak projektuje ta textura kamery??
|
||||||
|
- Možná by stálo za to udělat procedurální mesh. Nejběžnější tvar portálu bude asi obdélník
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
extends VBoxContainer
|
||||||
|
|
||||||
|
|
||||||
|
func _ready() -> void:
|
||||||
|
toggle_hud() # This should hide the HUD by default
|
||||||
|
|
||||||
|
func _process(delta: float) -> void:
|
||||||
|
if Input.is_action_just_pressed("ui_cancel"):
|
||||||
|
toggle_hud()
|
||||||
|
|
||||||
|
func toggle_hud() -> void:
|
||||||
|
|
||||||
|
var should_show = Input.mouse_mode == Input.MOUSE_MODE_CAPTURED
|
||||||
|
|
||||||
|
if should_show:
|
||||||
|
Input.mouse_mode = Input.MOUSE_MODE_VISIBLE
|
||||||
|
show()
|
||||||
|
else:
|
||||||
|
Input.mouse_mode = Input.MOUSE_MODE_CAPTURED
|
||||||
|
hide()
|
||||||
|
|
||||||
|
func _on_menu_button_pressed() -> void:
|
||||||
|
var err = get_tree().change_scene_to_file("res://menu.tscn")
|
||||||
|
if err != OK:
|
||||||
|
print("Failed to switch scenes: ", error_string(err))
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
uid://dys441ih752an
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
[gd_scene load_steps=2 format=3 uid="uid://b5x7fmpwck335"]
|
||||||
|
|
||||||
|
[ext_resource type="Script" uid="uid://dys441ih752an" path="res://hud.gd" id="1_37p78"]
|
||||||
|
|
||||||
|
[node name="HUD" type="VBoxContainer"]
|
||||||
|
script = ExtResource("1_37p78")
|
||||||
|
|
||||||
|
[node name="MenuButton" type="Button" parent="."]
|
||||||
|
unique_name_in_owner = true
|
||||||
|
layout_mode = 2
|
||||||
|
text = "Back to Menu"
|
||||||
|
|
||||||
|
[connection signal="pressed" from="MenuButton" to="." method="_on_menu_button_pressed"]
|
||||||
+6
-1
@@ -1,10 +1,11 @@
|
|||||||
[gd_scene load_steps=10 format=3 uid="uid://27pb62xwsqd8"]
|
[gd_scene load_steps=11 format=3 uid="uid://27pb62xwsqd8"]
|
||||||
|
|
||||||
[ext_resource type="MeshLibrary" uid="uid://bedqgubx1g1uf" path="res://prototypes.tres" id="1_mqqdr"]
|
[ext_resource type="MeshLibrary" uid="uid://bedqgubx1g1uf" path="res://prototypes.tres" id="1_mqqdr"]
|
||||||
[ext_resource type="Script" uid="uid://d2bvvjsibau8c" path="res://addons/simple-portal-system/scripts/portal.gd" id="2_b14t7"]
|
[ext_resource type="Script" uid="uid://d2bvvjsibau8c" path="res://addons/simple-portal-system/scripts/portal.gd" id="2_b14t7"]
|
||||||
[ext_resource type="ArrayMesh" uid="uid://bqilnvlfws6xh" path="res://portal-mesh.tres" id="2_cgnft"]
|
[ext_resource type="ArrayMesh" uid="uid://bqilnvlfws6xh" path="res://portal-mesh.tres" id="2_cgnft"]
|
||||||
[ext_resource type="PackedScene" uid="uid://cgdlowfuuorvi" path="res://player.tscn" id="3_b0o0q"]
|
[ext_resource type="PackedScene" uid="uid://cgdlowfuuorvi" path="res://player.tscn" id="3_b0o0q"]
|
||||||
[ext_resource type="Script" uid="uid://bkv7t4hw21byg" path="res://addons/simple-portal-system/scripts/simple_portal_teleport.gd" id="4_snwvi"]
|
[ext_resource type="Script" uid="uid://bkv7t4hw21byg" path="res://addons/simple-portal-system/scripts/simple_portal_teleport.gd" id="4_snwvi"]
|
||||||
|
[ext_resource type="PackedScene" uid="uid://b5x7fmpwck335" path="res://hud.tscn" id="6_phjvl"]
|
||||||
|
|
||||||
[sub_resource type="ProceduralSkyMaterial" id="ProceduralSkyMaterial_b0o0q"]
|
[sub_resource type="ProceduralSkyMaterial" id="ProceduralSkyMaterial_b0o0q"]
|
||||||
sky_horizon_color = Color(0.662243, 0.671743, 0.686743, 1)
|
sky_horizon_color = Color(0.662243, 0.671743, 0.686743, 1)
|
||||||
@@ -23,6 +24,10 @@ size = Vector3(2, 2, 0.5)
|
|||||||
|
|
||||||
[node name="level_3rooms" type="Node3D"]
|
[node name="level_3rooms" type="Node3D"]
|
||||||
|
|
||||||
|
[node name="HUD" parent="." instance=ExtResource("6_phjvl")]
|
||||||
|
offset_right = 137.0
|
||||||
|
offset_bottom = 23.0
|
||||||
|
|
||||||
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
||||||
environment = SubResource("Environment_snwvi")
|
environment = SubResource("Environment_snwvi")
|
||||||
|
|
||||||
|
|||||||
+19
-14
@@ -1,10 +1,11 @@
|
|||||||
[gd_scene load_steps=11 format=3 uid="uid://dpatwnepecl8r"]
|
[gd_scene load_steps=12 format=3 uid="uid://dpatwnepecl8r"]
|
||||||
|
|
||||||
[ext_resource type="MeshLibrary" uid="uid://bedqgubx1g1uf" path="res://prototypes.tres" id="1_7nma7"]
|
[ext_resource type="MeshLibrary" uid="uid://bedqgubx1g1uf" path="res://prototypes.tres" id="1_7nma7"]
|
||||||
[ext_resource type="PackedScene" uid="uid://cgdlowfuuorvi" path="res://player.tscn" id="2_7nma7"]
|
[ext_resource type="PackedScene" uid="uid://cgdlowfuuorvi" path="res://player.tscn" id="2_7nma7"]
|
||||||
[ext_resource type="ArrayMesh" uid="uid://bqilnvlfws6xh" path="res://portal-mesh.tres" id="3_ok2r5"]
|
[ext_resource type="ArrayMesh" uid="uid://bqilnvlfws6xh" path="res://portal-mesh.tres" id="3_ok2r5"]
|
||||||
[ext_resource type="Script" uid="uid://d2bvvjsibau8c" path="res://addons/simple-portal-system/scripts/portal.gd" id="4_n2ayn"]
|
[ext_resource type="Script" uid="uid://d2bvvjsibau8c" path="res://addons/simple-portal-system/scripts/portal.gd" id="4_n2ayn"]
|
||||||
[ext_resource type="Script" uid="uid://bkv7t4hw21byg" path="res://addons/simple-portal-system/scripts/simple_portal_teleport.gd" id="5_dfyqt"]
|
[ext_resource type="Script" uid="uid://bkv7t4hw21byg" path="res://addons/simple-portal-system/scripts/simple_portal_teleport.gd" id="5_dfyqt"]
|
||||||
|
[ext_resource type="PackedScene" uid="uid://b5x7fmpwck335" path="res://hud.tscn" id="6_00lyl"]
|
||||||
|
|
||||||
[sub_resource type="ProceduralSkyMaterial" id="ProceduralSkyMaterial_lquwl"]
|
[sub_resource type="ProceduralSkyMaterial" id="ProceduralSkyMaterial_lquwl"]
|
||||||
|
|
||||||
@@ -19,7 +20,11 @@ sky = SubResource("Sky_7mycd")
|
|||||||
[sub_resource type="BoxShape3D" id="BoxShape3D_1bvp3"]
|
[sub_resource type="BoxShape3D" id="BoxShape3D_1bvp3"]
|
||||||
size = Vector3(2, 2.5, 0.2)
|
size = Vector3(2, 2.5, 0.2)
|
||||||
|
|
||||||
[node name="Main" type="Node3D"]
|
[node name="Level_5_rooms" type="Node3D"]
|
||||||
|
|
||||||
|
[node name="HUD" parent="." instance=ExtResource("6_00lyl")]
|
||||||
|
offset_right = 114.0
|
||||||
|
offset_bottom = 39.0
|
||||||
|
|
||||||
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
||||||
environment = SubResource("Environment_272bh")
|
environment = SubResource("Environment_272bh")
|
||||||
@@ -28,9 +33,9 @@ environment = SubResource("Environment_272bh")
|
|||||||
mesh_library = ExtResource("1_7nma7")
|
mesh_library = ExtResource("1_7nma7")
|
||||||
cell_size = Vector3(1, 1, 1)
|
cell_size = Vector3(1, 1, 1)
|
||||||
data = {
|
data = {
|
||||||
"cells": PackedInt32Array(0, 0, 0, 1, 0, 0, 2, 0, 0, 3, 0, 0, 4, 0, 0, 5, 0, 0, 0, 65535, 0, 0, 65534, 0, 0, 65533, 0, 0, 65532, 0, 0, 65531, 0, 0, 65530, 0, 1, 65529, 0, 2, 65529, 0, 3, 65529, 0, 3, 65530, 0, 4, 65530, 0, 5, 65530, 0, 5, 65531, 0, 5, 65532, 0, 5, 65533, 0, 5, 65534, 0, 5, 65535, 0, 4, 65535, 0, 3, 65535, 0, 2, 65535, 0, 2, 65534, 0, 1, 65534, 0, 2, 65533, 0, 3, 65533, 0, 4, 65534, 0, 3, 65534, 0, 1, 65535, 0, 65535, 0, 0, 2, 65532, 0, 1, 65532, 0, 1, 65531, 0, 1, 65530, 0, 1, 65533, 0, 4, 65533, 0, 3, 65532, 0, 3, 65531, 0, 2, 65531, 0, 2, 65530, 0, 4, 65532, 0, 4, 65531, 0, 4, 65529, 0, 5, 65529, 0, 0, 65529, 0, 65535, 65529, 0, 65534, 65529, 0, 65532, 65530, 0, 65531, 65531, 0, 65530, 65531, 0, 65530, 65532, 0, 65530, 65535, 0, 65530, 0, 0, 65531, 0, 0, 65534, 0, 0, 65534, 65535, 0, 65534, 65534, 0, 65533, 65534, 0, 65532, 65534, 0, 65531, 65534, 0, 65531, 65535, 0, 65532, 0, 0, 65533, 0, 0, 65532, 65535, 0, 65533, 65535, 0, 65535, 65535, 0, 65533, 65533, 0, 65534, 65533, 0, 65534, 65532, 0, 65534, 65531, 0, 65535, 65533, 0, 65535, 65532, 0, 65535, 65531, 0, 65535, 65530, 0, 65535, 65534, 0, 65532, 65533, 0, 65531, 65533, 0, 65530, 65534, 0, 65530, 65533, 0, 65531, 65532, 0, 65532, 65531, 0, 65534, 65530, 0, 65533, 65530, 0, 65533, 65531, 0, 65533, 65532, 0, 65532, 65532, 0, 65533, 65529, 0, 65532, 65529, 0, 65531, 65529, 0, 65530, 65529, 0, 65530, 65530, 0, 65531, 65530, 0, 131066, 0, 2, 131067, 0, 2, 131068, 0, 2, 131069, 0, 2, 131070, 0, 2, 131071, 0, 2, 65536, 0, 2, 65537, 0, 2, 65538, 0, 2, 65539, 0, 2, 65540, 0, 2, 65541, 0, 2, 65541, 65535, 2, 65541, 65534, 2, 65541, 65533, 2, 65541, 65532, 2, 65541, 65531, 2, 65541, 65530, 2, 65541, 65529, 2, 65540, 65529, 2, 65539, 65529, 2, 65538, 65529, 2, 65537, 65529, 2, 131070, 65529, 2, 131069, 65529, 2, 131068, 65529, 2, 131067, 65529, 2, 131066, 65529, 2, 131066, 65530, 2, 131066, 65531, 2, 131066, 65534, 2, 131066, 65535, 2, 10, 65529, 0, 10, 65530, 0, 10, 65531, 0, 10, 65532, 0, 10, 65533, 0, 10, 65534, 0, 10, 65535, 0, 10, 0, 0, 11, 0, 0, 12, 0, 0, 13, 0, 0, 14, 0, 0, 15, 0, 0, 16, 0, 0, 17, 0, 0, 18, 0, 0, 19, 0, 0, 20, 0, 0, 21, 0, 0, 21, 65535, 0, 21, 65534, 0, 21, 65533, 0, 21, 65532, 0, 21, 65531, 0, 21, 65530, 0, 21, 65529, 0, 20, 65529, 0, 19, 65529, 0, 18, 65529, 0, 17, 65529, 0, 16, 65529, 0, 15, 65529, 0, 14, 65529, 0, 13, 65529, 0, 12, 65529, 0, 11, 65529, 0, 11, 65530, 0, 11, 65531, 0, 11, 65532, 0, 11, 65533, 0, 11, 65534, 0, 11, 65535, 0, 12, 65535, 0, 15, 65535, 0, 16, 65535, 0, 17, 65535, 0, 18, 65535, 0, 19, 65535, 0, 20, 65535, 0, 20, 65534, 0, 20, 65533, 0, 20, 65532, 0, 20, 65531, 0, 20, 65530, 0, 19, 65530, 0, 18, 65530, 0, 17, 65530, 0, 16, 65530, 0, 15, 65530, 0, 14, 65530, 0, 13, 65530, 0, 12, 65530, 0, 12, 65531, 0, 12, 65532, 0, 12, 65533, 0, 12, 65534, 0, 13, 65535, 0, 14, 65535, 0, 14, 65534, 0, 13, 65533, 0, 13, 65532, 0, 13, 65531, 0, 14, 65531, 0, 15, 65531, 0, 16, 65531, 0, 16, 65532, 0, 17, 65532, 0, 18, 65532, 0, 19, 65532, 0, 19, 65531, 0, 19, 65533, 0, 18, 65533, 0, 17, 65534, 0, 16, 65534, 0, 15, 65534, 0, 13, 65534, 0, 18, 65534, 0, 19, 65534, 0, 14, 65533, 0, 14, 65532, 0, 15, 65533, 0, 16, 65533, 0, 17, 65533, 0, 15, 65532, 0, 17, 65531, 0, 18, 65531, 0, 26, 0, 0, 37, 65529, 0, 36, 65529, 0, 35, 65529, 0, 34, 65529, 0, 33, 65529, 0, 32, 65529, 0, 31, 65529, 0, 31, 65530, 0, 30, 65530, 0, 29, 65530, 0, 30, 65529, 0, 29, 65529, 0, 28, 65529, 0, 27, 65529, 0, 26, 65529, 0, 26, 65530, 0, 26, 65531, 0, 26, 65532, 0, 26, 65533, 0, 26, 65534, 0, 26, 65535, 0, 27, 65530, 0, 27, 65531, 0, 27, 65532, 0, 27, 65533, 0, 27, 65534, 0, 27, 65535, 0, 27, 0, 0, 28, 65530, 0, 28, 65531, 0, 28, 65532, 0, 28, 65533, 0, 28, 65534, 0, 28, 65535, 0, 28, 0, 0, 29, 65531, 0, 29, 65532, 0, 29, 65533, 0, 29, 65534, 0, 29, 65535, 0, 29, 0, 0, 30, 65531, 0, 30, 65532, 0, 30, 65533, 0, 30, 65534, 0, 30, 65535, 0, 30, 0, 0, 31, 65531, 0, 31, 65532, 0, 31, 65533, 0, 31, 65534, 0, 31, 65535, 0, 31, 0, 0, 32, 65530, 0, 32, 65531, 0, 32, 65532, 0, 32, 65533, 0, 32, 65534, 0, 32, 65535, 0, 32, 0, 0, 33, 65530, 0, 33, 65531, 0, 33, 65532, 0, 33, 65533, 0, 33, 65534, 0, 33, 65535, 0, 33, 0, 0, 34, 65530, 0, 34, 65531, 0, 34, 65532, 0, 34, 65533, 0, 34, 65534, 0, 34, 65535, 0, 34, 0, 0, 35, 65530, 0, 35, 65531, 0, 35, 65532, 0, 35, 65533, 0, 35, 65534, 0, 35, 65535, 0, 35, 0, 0, 36, 65530, 0, 36, 65531, 0, 36, 65532, 0, 36, 65533, 0, 36, 65534, 0, 36, 65535, 0, 36, 0, 0, 37, 65530, 0, 37, 65531, 0, 37, 65532, 0, 37, 65533, 0, 37, 65534, 0, 37, 65535, 0, 37, 0, 0, 65530, 5, 0, 65530, 6, 0, 65530, 7, 0, 65530, 8, 0, 65530, 9, 0, 65530, 10, 0, 65530, 11, 0, 65531, 5, 0, 65531, 6, 0, 65531, 7, 0, 65531, 8, 0, 65531, 9, 0, 65531, 10, 0, 65531, 11, 0, 65532, 5, 0, 65532, 6, 0, 65532, 7, 0, 65532, 8, 0, 65532, 9, 0, 65532, 10, 0, 65532, 11, 0, 65533, 5, 0, 65533, 6, 0, 65533, 7, 0, 65533, 8, 0, 65533, 9, 0, 65533, 10, 0, 65533, 11, 0, 65534, 5, 0, 65534, 6, 0, 65534, 7, 0, 65534, 8, 0, 65534, 9, 0, 65534, 10, 0, 65534, 11, 0, 65535, 5, 0, Line truncated
|
"cells": PackedInt32Array(0, 0, 0, 1, 0, 0, 2, 0, 0, 3, 0, 0, 4, 0, 0, 5, 0, 0, 0, 65535, 0, 0, 65534, 0, 0, 65533, 0, 0, 65532, 0, 0, 65531, 0, 0, 65530, 0, 1, 65529, 0, 2, 65529, 0, 3, 65529, 0, 3, 65530, 0, 4, 65530, 0, 5, 65530, 0, 5, 65531, 0, 5, 65532, 0, 5, 65533, 0, 5, 65534, 0, 5, 65535, 0, 4, 65535, 0, 3, 65535, 0, 2, 65535, 0, 2, 65534, 0, 1, 65534, 0, 2, 65533, 0, 3, 65533, 0, 4, 65534, 0, 3, 65534, 0, 1, 65535, 0, 65535, 0, 0, 2, 65532, 0, 1, 65532, 0, 1, 65531, 0, 1, 65530, 0, 1, 65533, 0, 4, 65533, 0, 3, 65532, 0, 3, 65531, 0, 2, 65531, 0, 2, 65530, 0, 4, 65532, 0, 4, 65531, 0, 4, 65529, 0, 5, 65529, 0, 0, 65529, 0, 65535, 65529, 0, 65534, 65529, 0, 65532, 65530, 0, 65531, 65531, 0, 65530, 65531, 0, 65530, 65532, 0, 65530, 65535, 0, 65530, 0, 0, 65531, 0, 0, 65534, 0, 0, 65534, 65535, 0, 65534, 65534, 0, 65533, 65534, 0, 65532, 65534, 0, 65531, 65534, 0, 65531, 65535, 0, 65532, 0, 0, 65533, 0, 0, 65532, 65535, 0, 65533, 65535, 0, 65535, 65535, 0, 65533, 65533, 0, 65534, 65533, 0, 65534, 65532, 0, 65534, 65531, 0, 65535, 65533, 0, 65535, 65532, 0, 65535, 65531, 0, 65535, 65530, 0, 65535, 65534, 0, 65532, 65533, 0, 65531, 65533, 0, 65530, 65534, 0, 65530, 65533, 0, 65531, 65532, 0, 65532, 65531, 0, 65534, 65530, 0, 65533, 65530, 0, 65533, 65531, 0, 65533, 65532, 0, 65532, 65532, 0, 65533, 65529, 0, 65532, 65529, 0, 65531, 65529, 0, 65530, 65529, 0, 65530, 65530, 0, 65531, 65530, 0, 131066, 0, 2, 131067, 0, 2, 131068, 0, 2, 131069, 0, 2, 131070, 0, 2, 131071, 0, 2, 65536, 0, 2, 65537, 0, 2, 65538, 0, 2, 65539, 0, 2, 65540, 0, 2, 65541, 0, 2, 65541, 65535, 2, 65541, 65534, 2, 65541, 65533, 2, 65541, 65532, 2, 65541, 65531, 2, 65541, 65530, 2, 65541, 65529, 2, 65540, 65529, 2, 65539, 65529, 2, 65538, 65529, 2, 65537, 65529, 2, 131070, 65529, 2, 131069, 65529, 2, 131068, 65529, 2, 131067, 65529, 2, 131066, 65529, 2, 131066, 65530, 2, 131066, 65531, 2, 131066, 65534, 2, 131066, 65535, 2, 10, 65529, 0, 10, 65530, 0, 10, 65531, 0, 10, 65532, 0, 10, 65533, 0, 10, 65534, 0, 10, 65535, 0, 10, 0, 0, 11, 0, 0, 12, 0, 0, 13, 0, 0, 14, 0, 0, 15, 0, 0, 16, 0, 0, 17, 0, 0, 18, 0, 0, 19, 0, 0, 20, 0, 0, 21, 0, 0, 21, 65535, 0, 21, 65534, 0, 21, 65533, 0, 21, 65532, 0, 21, 65531, 0, 21, 65530, 0, 21, 65529, 0, 20, 65529, 0, 19, 65529, 0, 18, 65529, 0, 17, 65529, 0, 16, 65529, 0, 15, 65529, 0, 14, 65529, 0, 13, 65529, 0, 12, 65529, 0, 11, 65529, 0, 11, 65530, 0, 11, 65531, 0, 11, 65532, 0, 11, 65533, 0, 11, 65534, 0, 11, 65535, 0, 12, 65535, 0, 15, 65535, 0, 16, 65535, 0, 17, 65535, 0, 18, 65535, 0, 19, 65535, 0, 20, 65535, 0, 20, 65534, 0, 20, 65533, 0, 20, 65532, 0, 20, 65531, 0, 20, 65530, 0, 19, 65530, 0, 18, 65530, 0, 17, 65530, 0, 16, 65530, 0, 15, 65530, 0, 14, 65530, 0, 13, 65530, 0, 12, 65530, 0, 12, 65531, 0, 12, 65532, 0, 12, 65533, 0, 12, 65534, 0, 13, 65535, 0, 14, 65535, 0, 14, 65534, 0, 13, 65533, 0, 13, 65532, 0, 13, 65531, 0, 14, 65531, 0, 15, 65531, 0, 16, 65531, 0, 16, 65532, 0, 17, 65532, 0, 18, 65532, 0, 19, 65532, 0, 19, 65531, 0, 19, 65533, 0, 18, 65533, 0, 17, 65534, 0, 16, 65534, 0, 15, 65534, 0, 13, 65534, 0, 18, 65534, 0, 19, 65534, 0, 14, 65533, 0, 14, 65532, 0, 15, 65533, 0, 16, 65533, 0, 17, 65533, 0, 15, 65532, 0, 17, 65531, 0, 18, 65531, 0, 26, 0, 0, 37, 65529, 0, 36, 65529, 0, 35, 65529, 0, 34, 65529, 0, 33, 65529, 0, 32, 65529, 0, 31, 65529, 0, 31, 65530, 0, 30, 65530, 0, 29, 65530, 0, 30, 65529, 0, 29, 65529, 0, 28, 65529, 0, 27, 65529, 0, 26, 65529, 0, 26, 65530, 0, 26, 65531, 0, 26, 65532, 0, 26, 65533, 0, 26, 65534, 0, 26, 65535, 0, 27, 65530, 0, 27, 65531, 0, 27, 65532, 0, 27, 65533, 0, 27, 65534, 0, 27, 65535, 0, 27, 0, 0, 28, 65530, 0, 28, 65531, 0, 28, 65532, 0, 28, 65533, 0, 28, 65534, 0, 28, 65535, 0, 28, 0, 0, 29, 65531, 0, 29, 65532, 0, 29, 65533, 0, 29, 65534, 0, 29, 65535, 0, 29, 0, 0, 30, 65531, 0, 30, 65532, 0, 30, 65533, 0, 30, 65534, 0, 30, 65535, 0, 30, 0, 0, 31, 65531, 0, 31, 65532, 0, 31, 65533, 0, 31, 65534, 0, 31, 65535, 0, 31, 0, 0, 32, 65530, 0, 32, 65531, 0, 32, 65532, 0, 32, 65533, 0, 32, 65534, 0, 32, 65535, 0, 32, 0, 0, 33, 65530, 0, 33, 65531, 0, 33, 65532, 0, 33, 65533, 0, 33, 65534, 0, 33, 65535, 0, 33, 0, 0, 34, 65530, 0, 34, 65531, 0, 34, 65532, 0, 34, 65533, 0, 34, 65534, 0, 34, 65535, 0, 34, 0, 0, 35, 65530, 0, 35, 65531, 0, 35, 65532, 0, 35, 65533, 0, 35, 65534, 0, 35, 65535, 0, 35, 0, 0, 36, 65530, 0, 36, 65531, 0, 36, 65532, 0, 36, 65533, 0, 36, 65534, 0, 36, 65535, 0, 36, 0, 0, 37, 65530, 0, 37, 65531, 0, 37, 65532, 0, 37, 65533, 0, 37, 65534, 0, 37, 65535, 0, 37, 0, 0, 65530, 5, 0, 65530, 6, 0, 65530, 7, 0, 65530, 8, 0, 65530, 9, 0, 65530, 10, 0, 65530, 11, 0, 65531, 5, 0, 65531, 6, 0, 65531, 7, 0, 65531, 8, 0, 65531, 9, 0, 65531, 10, 0, 65531, 11, 0, 65532, 5, 0, 65532, 6, 0, 65532, 7, 0, 65532, 8, 0, 65532, 9, 0, 65532, 10, 0, 65532, 11, 0, 65533, 5, 0, 65533, 6, 0, 65533, 7, 0, 65533, 8, 0, 65533, 9, 0, 65533, 10, 0, 65533, 11, 0, 65534, 5, 0, 65534, 6, 0, 65534, 7, 0, 65534, 8, 0, 65534, 9, 0, 65534, 10, 0, 65534, 11, 0, 65535, 5, 0, Line truncated
|
||||||
}
|
}
|
||||||
metadata/_editor_floor_ = Vector3(0, 3, 0)
|
metadata/_editor_floor_ = Vector3(0, 2, 0)
|
||||||
|
|
||||||
[node name="OmniLight3D_white" type="OmniLight3D" parent="."]
|
[node name="OmniLight3D_white" type="OmniLight3D" parent="."]
|
||||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, -3)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, -3)
|
||||||
@@ -64,7 +69,7 @@ omni_range = 4.0
|
|||||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.28597, -3)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.28597, -3)
|
||||||
|
|
||||||
[node name="P_white_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_white_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(-4.80825e-08, 0, 1.1, 0, 1.1, 0, -1.1, 0, -4.80825e-08, -5.5, 2, -3)
|
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, -5.5, 2, -3)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -83,7 +88,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_white_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_white_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(1.1, 0, 0, 0, 1.1, 0, 0, 0, 1.1, 0, 2, -6.5)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, -6.5)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -102,7 +107,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_green_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_green_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(-4.80825e-08, 0, 1.1, 0, 1.1, 0, -1.1, 0, -4.80825e-08, 10.5, 2, -3)
|
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, 10.5, 2, -3)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -121,7 +126,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_green_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_green_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(1.1, 0, 0, 0, 1.1, 0, 0, 0, 1.1, 16, 2, -6.5)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 16, 2, -6.5)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -140,7 +145,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_orange_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_orange_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(-4.80825e-08, 0, 1.1, 0, 1.1, 0, -1.1, 0, -4.80825e-08, 26.5, 2, -3)
|
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, 26.5, 2, -3)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -159,7 +164,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_orange_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_orange_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(1.1, 0, 0, 0, 1.1, 0, 0, 0, 1.1, 32, 2, -6.5)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 32, 2, -6.5)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -178,7 +183,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_purple_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_purple_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(-4.80825e-08, 0, 1.1, 0, 1.1, 0, -1.1, 0, -4.80825e-08, -5.5, 2, 9)
|
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, -5.5, 2, 9)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -197,7 +202,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_purple_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_purple_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(1.1, 0, 0, 0, 1.1, 0, 0, 0, 1.1, 0, 2, 5.5)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 5.5)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -216,7 +221,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_red_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_red_short" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(-4.80825e-08, 0, 1.1, 0, 1.1, 0, -1.1, 0, -4.80825e-08, 10.5, 2, 9)
|
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, 10.5, 2, 9)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
@@ -235,7 +240,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.1)
|
|||||||
shape = SubResource("BoxShape3D_1bvp3")
|
shape = SubResource("BoxShape3D_1bvp3")
|
||||||
|
|
||||||
[node name="P_red_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
[node name="P_red_wide" type="MeshInstance3D" parent="." node_paths=PackedStringArray("exit_portal")]
|
||||||
transform = Transform3D(1.1, 0, 0, 0, 1.1, 0, 0, 0, 1.1, 16, 2, 5.5)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 16, 2, 5.5)
|
||||||
mesh = ExtResource("3_ok2r5")
|
mesh = ExtResource("3_ok2r5")
|
||||||
script = ExtResource("4_n2ayn")
|
script = ExtResource("4_n2ayn")
|
||||||
disable_viewport_distance = 100.0
|
disable_viewport_distance = 100.0
|
||||||
|
|||||||
+2
-17
@@ -8,6 +8,7 @@
|
|||||||
[ext_resource type="Script" uid="uid://d2bvvjsibau8c" path="res://addons/simple-portal-system/scripts/portal.gd" id="5_wg85y"]
|
[ext_resource type="Script" uid="uid://d2bvvjsibau8c" path="res://addons/simple-portal-system/scripts/portal.gd" id="5_wg85y"]
|
||||||
[ext_resource type="Script" uid="uid://bkv7t4hw21byg" path="res://addons/simple-portal-system/scripts/simple_portal_teleport.gd" id="6_3fidx"]
|
[ext_resource type="Script" uid="uid://bkv7t4hw21byg" path="res://addons/simple-portal-system/scripts/simple_portal_teleport.gd" id="6_3fidx"]
|
||||||
[ext_resource type="ArrayMesh" uid="uid://bqilnvlfws6xh" path="res://portal-mesh.tres" id="7_hwdx8"]
|
[ext_resource type="ArrayMesh" uid="uid://bqilnvlfws6xh" path="res://portal-mesh.tres" id="7_hwdx8"]
|
||||||
|
[ext_resource type="PackedScene" uid="uid://b5x7fmpwck335" path="res://hud.tscn" id="9_2wcgd"]
|
||||||
|
|
||||||
[sub_resource type="Environment" id="Environment_7knre"]
|
[sub_resource type="Environment" id="Environment_7knre"]
|
||||||
background_mode = 1
|
background_mode = 1
|
||||||
@@ -20,9 +21,6 @@ size = Vector3(2, 1, 2)
|
|||||||
[sub_resource type="BoxShape3D" id="BoxShape3D_2wcgd"]
|
[sub_resource type="BoxShape3D" id="BoxShape3D_2wcgd"]
|
||||||
size = Vector3(2, 2.5, 8.79824)
|
size = Vector3(2, 2.5, 8.79824)
|
||||||
|
|
||||||
[sub_resource type="ViewportTexture" id="ViewportTexture_hwdx8"]
|
|
||||||
viewport_path = NodePath("SubViewport")
|
|
||||||
|
|
||||||
[node name="Main" type="Node3D"]
|
[node name="Main" type="Node3D"]
|
||||||
|
|
||||||
[node name="DirectionalLight3D" type="DirectionalLight3D" parent="."]
|
[node name="DirectionalLight3D" type="DirectionalLight3D" parent="."]
|
||||||
@@ -302,17 +300,4 @@ fade_out_color = Color(0.590126, 0.615058, 0.699408, 1)
|
|||||||
exit_cull_mask = 1048573
|
exit_cull_mask = 1048573
|
||||||
exit_portal = NodePath("../P_bottom")
|
exit_portal = NodePath("../P_bottom")
|
||||||
|
|
||||||
[node name="SubViewport" type="SubViewport" parent="."]
|
[node name="HUD" parent="." instance=ExtResource("9_2wcgd")]
|
||||||
size = Vector2i(512, 288)
|
|
||||||
|
|
||||||
[node name="Camera3D" type="Camera3D" parent="SubViewport"]
|
|
||||||
transform = Transform3D(-0.00436047, 0.491726, -0.870739, 0, 0.870747, 0.491731, 0.999991, 0.00214418, -0.00379687, -34.9621, 17.276, -0.665714)
|
|
||||||
fov = 52.5
|
|
||||||
|
|
||||||
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
|
||||||
|
|
||||||
[node name="TextureRect" type="TextureRect" parent="CanvasLayer"]
|
|
||||||
visible = false
|
|
||||||
offset_right = 512.0
|
|
||||||
offset_bottom = 288.0
|
|
||||||
texture = SubResource("ViewportTexture_hwdx8")
|
|
||||||
@@ -7,15 +7,9 @@ const JUMP_VELOCITY = 4.5
|
|||||||
const MOUSE_SENSITIVITY = 0.005
|
const MOUSE_SENSITIVITY = 0.005
|
||||||
|
|
||||||
|
|
||||||
func _ready() -> void:
|
|
||||||
Input.mouse_mode = Input.MOUSE_MODE_CAPTURED
|
|
||||||
|
|
||||||
func _process(delta: float) -> void:
|
|
||||||
if Input.is_action_just_pressed("ui_cancel"):
|
|
||||||
Input.mouse_mode = Input.MOUSE_MODE_VISIBLE
|
|
||||||
|
|
||||||
func _unhandled_input(event: InputEvent) -> void:
|
func _unhandled_input(event: InputEvent) -> void:
|
||||||
if event is InputEventMouseMotion:
|
if event is InputEventMouseMotion:
|
||||||
|
if Input.mouse_mode == Input.MOUSE_MODE_CAPTURED:
|
||||||
rotate_y(-event.screen_relative.x * MOUSE_SENSITIVITY)
|
rotate_y(-event.screen_relative.x * MOUSE_SENSITIVITY)
|
||||||
camera.rotate_x(-event.screen_relative.y * MOUSE_SENSITIVITY)
|
camera.rotate_x(-event.screen_relative.y * MOUSE_SENSITIVITY)
|
||||||
camera.rotation.x = clamp(camera.rotation.x, deg_to_rad(-80), deg_to_rad(80))
|
camera.rotation.x = clamp(camera.rotation.x, deg_to_rad(-80), deg_to_rad(80))
|
||||||
|
|||||||
Reference in new issue
Block a user