add console element
This commit is contained in:
parent
5520b7ab38
commit
6648ac171b
|
@ -15,15 +15,16 @@ cull_mode = 2
|
|||
script = ExtResource("1_ullcc")
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="."]
|
||||
transform = Transform3D(1, 0, 0, 0, -4.37114e-08, -1, 0, 1, -4.37114e-08, 0, 0, 0)
|
||||
shape = SubResource("BoxShape3D_6xl4b")
|
||||
|
||||
[node name="MeshInstance3D" type="MeshInstance3D" parent="."]
|
||||
transform = Transform3D(1, 0, 0, 0, -4.37114e-08, 1, 0, -1, -4.37114e-08, 0.01, 0, 0)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 1.06581e-14, 0, -1.06581e-14, 1, 0.01, 0, 0)
|
||||
material_override = SubResource("StandardMaterial3D_087gr")
|
||||
mesh = SubResource("QuadMesh_chf50")
|
||||
|
||||
[node name="Label3D" type="Label3D" parent="."]
|
||||
transform = Transform3D(1, 0, 0, 0, -4.37114e-08, 1, 0, -1, -4.37114e-08, -0.477142, 0.00806178, -0.495248)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.477979, 0.492319, 0.001)
|
||||
pixel_size = 0.001
|
||||
text = "Texst
|
||||
aaa"
|
||||
|
|
24
app/lib/globals/console.gd
Normal file
24
app/lib/globals/console.gd
Normal file
|
@ -0,0 +1,24 @@
|
|||
extends Node
|
||||
|
||||
const console_scene = preload ("res://content/ui/console.tscn")
|
||||
var _console: Node3D = null
|
||||
|
||||
func _ready():
|
||||
get_node("/root/Main").tree_entered.connect(func():
|
||||
init_console()
|
||||
)
|
||||
|
||||
func init_console():
|
||||
_console = console_scene.instantiate()
|
||||
get_node("/root/Main").add_child(_console)
|
||||
var camera = get_node("/root/Main/XROrigin3D/XRCamera3D")
|
||||
|
||||
_console.global_position = camera.global_position + camera.global_transform.basis.z * - 1
|
||||
_console.global_transform.basis = Basis.looking_at(_console.global_position - camera.global_position)
|
||||
|
||||
func log(message):
|
||||
print(message, _console)
|
||||
if _console == null:
|
||||
init_console()
|
||||
|
||||
_console.log(message)
|
|
@ -28,6 +28,7 @@ AudioPlayer="*res://lib/globals/audio_player.gd"
|
|||
EventSystem="*res://lib/globals/event_system.gd"
|
||||
Store="*res://lib/globals/main_store.gd"
|
||||
House="*res://lib/globals/house_body.gd"
|
||||
console="*res://lib/globals/console.gd"
|
||||
|
||||
[display]
|
||||
|
||||
|
@ -72,6 +73,7 @@ renderer/rendering_method.mobile="gl_compatibility"
|
|||
textures/vram_compression/import_etc2_astc=true
|
||||
lights_and_shadows/directional_shadow/soft_shadow_filter_quality=4
|
||||
lights_and_shadows/directional_shadow/soft_shadow_filter_quality.mobile=4
|
||||
anti_aliasing/quality/msaa_3d=1
|
||||
viewport/transparent_background=true
|
||||
|
||||
[xr]
|
||||
|
|
Loading…
Reference in New Issue
Block a user