factory room decoration
This commit is contained in:
parent
b6c129897b
commit
dca81e4726
@ -85,6 +85,9 @@ func _ready():
|
||||
Daytime.increase_per_second = 100
|
||||
Pills._decrease_per_second = 0.8
|
||||
|
||||
if IsInFactory:
|
||||
Daytime.increase_per_second = 0
|
||||
|
||||
# setup collisions with Meldewesen
|
||||
var area = get_node("InteractArea") as Area
|
||||
assert(null != area)
|
||||
@ -229,6 +232,15 @@ func _on_area_entered (area: Area):
|
||||
IsOutside = true
|
||||
# TODO: move not change_scene!
|
||||
get_tree().change_scene("res://Level/World.tscn")
|
||||
elif area.is_in_group("LabyrinthEntry"):
|
||||
Logger.info("entering labyrinth")
|
||||
IsInFactory = false
|
||||
IsInLabyrinth = true
|
||||
# TODO: move not change_scene!
|
||||
get_tree().change_scene("res://Level/Labyrinth.tscn")
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
func _on_area_exited (area: Area):
|
||||
|
@ -12,10 +12,8 @@ func _ready():
|
||||
#Logger.set_logger_level(Logger.LOG_LEVEL_FINE)
|
||||
|
||||
_followPath = get_node("../") as PathFollow
|
||||
assert(null != _followPath)
|
||||
|
||||
_navPath = get_node("../../") as Path
|
||||
assert(null != _navPath)
|
||||
|
||||
var _interactArea = get_node("InteractArea") as Area
|
||||
assert(null != _interactArea)
|
||||
@ -24,7 +22,8 @@ func _ready():
|
||||
func _process(_delta):
|
||||
# TODO: movement
|
||||
#if current_target: # should not be needed -> handled per navigation path
|
||||
_followPath.offset += diffPerSecond * _delta
|
||||
if _followPath != null:
|
||||
_followPath.offset += diffPerSecond * _delta
|
||||
|
||||
|
||||
func _on_area_entered (area: Area):
|
||||
|
1318
Level/InFactory.tscn
1318
Level/InFactory.tscn
File diff suppressed because one or more lines are too long
@ -35,14 +35,14 @@ surfaces/0 = {
|
||||
|
||||
[sub_resource type="BoxShape" id=3]
|
||||
|
||||
[node name="Spatial" type="StaticBody" groups=[
|
||||
[node name="StraightPipe" type="StaticBody" groups=[
|
||||
"Pipes",
|
||||
]]
|
||||
collision_layer = 7
|
||||
collision_mask = 7
|
||||
script = ExtResource( 1 )
|
||||
mesh_path = NodePath("Mesh")
|
||||
color_cast_left = NodePath("ColorCast")
|
||||
mesh_path = NodePath("../StraightPipe/Mesh")
|
||||
color_cast_left = NodePath("../StraightPipe/ColorCast")
|
||||
|
||||
[node name="Mesh" type="MeshInstance" parent="."]
|
||||
transform = Transform( 0.2, 0, 0, 0, 0.2, 0, 0, 0, 0.2, 0, 0, 0 )
|
||||
|
Loading…
x
Reference in New Issue
Block a user