Compare commits
6 Commits
ui_fixes
...
f63c9fa141
| Author | SHA1 | Date | |
|---|---|---|---|
| f63c9fa141 | |||
| 498115107e | |||
| 922c771185 | |||
| 3512145a66 | |||
| c22fffdfc1 | |||
| 238dd4a124 |
@@ -87,8 +87,6 @@ const RIVER_NEIGHBOUR_OFFSETS: Dictionary = {
|
||||
@export_range(1, 6, 1) var lamppost_search_radius_cells: int = 3
|
||||
##max allowed distance between lamppost pairs
|
||||
@export var lamppost_max_wire_distance: float = 35.0
|
||||
##minimum horizontal distance between generated wires and the railway centerline
|
||||
@export var lamppost_rail_clearance_distance: float = 4.0
|
||||
##if true wire connections blocked by colliders are discarded
|
||||
@export var lamppost_obstacle_check_enabled: bool = true
|
||||
|
||||
@@ -1425,25 +1423,6 @@ func _get_wire_sample_point(p1: Vector3, p2: Vector3, t: float) -> Vector3:
|
||||
point.y -= gravity
|
||||
return point
|
||||
|
||||
func _is_wire_too_close_to_rail(p1: Vector3, p2: Vector3) -> bool:
|
||||
if rail_path == null or rail_path.curve == null:
|
||||
return false
|
||||
if lamppost_rail_clearance_distance <= 0.0:
|
||||
return false
|
||||
|
||||
var clearance_sq: float = lamppost_rail_clearance_distance * lamppost_rail_clearance_distance
|
||||
var samples: int = 10
|
||||
for i in range(samples + 1):
|
||||
var t: float = float(i) / float(samples)
|
||||
var wire_point: Vector3 = _get_wire_sample_point(p1, p2, t)
|
||||
var rail_local_point: Vector3 = rail_path.to_local(wire_point)
|
||||
var closest_rail_point: Vector3 = rail_path.to_global(rail_path.curve.get_closest_point(rail_local_point))
|
||||
var horizontal_delta := Vector2(wire_point.x - closest_rail_point.x, wire_point.z - closest_rail_point.z)
|
||||
if horizontal_delta.length_squared() < clearance_sq:
|
||||
return true
|
||||
|
||||
return false
|
||||
|
||||
func _collect_wire_excluded_rids(root: Node, excluded_rids: Array[RID]) -> void:
|
||||
if root == null:
|
||||
return
|
||||
@@ -1462,9 +1441,6 @@ func _get_wire_excluded_rids(excluded_roots: Array) -> Array[RID]:
|
||||
return excluded_rids
|
||||
|
||||
func _is_wire_path_blocked(p1: Vector3, p2: Vector3, excluded_roots: Array = []) -> bool:
|
||||
if _is_wire_too_close_to_rail(p1, p2):
|
||||
return true
|
||||
|
||||
if not lamppost_obstacle_check_enabled:
|
||||
return false
|
||||
|
||||
|
||||
@@ -1,16 +1,7 @@
|
||||
extends Path3D
|
||||
|
||||
const STEAM_DISTANCE_STAT: String = "stat_distance_km"
|
||||
const DISTANCE_KM_PER_UNIT: float = 0.01
|
||||
const STATION_STOP_GROUP: StringName = &"railway_station"
|
||||
const TRACK_ZERO_SPACING_FIX_DISTANCE: float = 45.0
|
||||
const TRACK_ZERO_SPACING_BLEND_DISTANCE: float = 18.0
|
||||
const TRACK_ZERO_SPACING_SEARCH_EXTRA: float = 35.0
|
||||
const TRACK_ZERO_SPACING_SEARCH_STEP: float = 0.5
|
||||
const TRACK_ZERO_SPACING_TARGET_RATIO: float = 0.97
|
||||
const TRACK_ZERO_SPACING_MIN_DISTANCE: float = 1.0
|
||||
|
||||
enum TrainStartMode { RANDOM_POSITION, SPECIFIED_STATION, SPECIFIED_POSITION }
|
||||
enum TrainFacingDirection { KEEP_PATH_DIRECTION, LOCOMOTIVE_LEFT, LOCOMOTIVE_RIGHT }
|
||||
|
||||
@export_group("Train")
|
||||
##train speed
|
||||
@@ -40,15 +31,6 @@ enum TrainFacingDirection { KEEP_PATH_DIRECTION, LOCOMOTIVE_LEFT, LOCOMOTIVE_RIG
|
||||
##swing of the train during the ran
|
||||
@export_range(0.0, 1.0) var basic_swing: float = 0.1
|
||||
|
||||
@export_group("Train Start")
|
||||
@export_enum("random_position", "specified_station", "specified_position") var train_start_mode: int = TrainStartMode.RANDOM_POSITION
|
||||
@export_range(0, 64, 1, "or_greater") var train_start_stop_index: int = 1
|
||||
@export var train_start_position: float = 0.0
|
||||
@export var train_start_delay_seconds: float = 0.0
|
||||
@export var train_start_after_delay: bool = true
|
||||
@export var train_start_acceleration_seconds: float = 4.0
|
||||
@export_enum("keep_path_direction", "locomotive_left", "locomotive_right") var train_facing_direction: int = TrainFacingDirection.KEEP_PATH_DIRECTION
|
||||
|
||||
@export_group("Rails Bulding")
|
||||
##distance between sleepers of the rails
|
||||
@export var sleepers_distance: float = 1.0
|
||||
@@ -66,10 +48,6 @@ enum TrainFacingDirection { KEEP_PATH_DIRECTION, LOCOMOTIVE_LEFT, LOCOMOTIVE_RIG
|
||||
@export_group("Train Stops")
|
||||
##if true the train stop the ran on stops
|
||||
@export var enable_stops: bool = true
|
||||
##if true the train only stops on markers with a generated station nearby
|
||||
@export var require_station_for_stop: bool = true
|
||||
##max horizontal distance between a stop marker and a station chunk
|
||||
@export var station_stop_detection_radius: float = 35.0
|
||||
##time of stop
|
||||
@export var stop_time: float = 4.0
|
||||
##distance when the train start to brake
|
||||
@@ -101,17 +79,19 @@ var next_stop_index: int = 0
|
||||
var stop_multiply: float = 1.0
|
||||
var is_restarting: bool = false
|
||||
var tween_restart: Tween
|
||||
var environment_config: EnvironmentConfig
|
||||
var wagon_instances: Array[Node3D] = []
|
||||
var wagon_progress_offsets: Array[float] = []
|
||||
var _pending_steam_distance_km: float = 0.0
|
||||
var _initial_is_inmotion: bool = true
|
||||
var _is_photo_mode_active: bool = false
|
||||
var _train_direction_sign: float = 1.0
|
||||
|
||||
func _ready() -> void:
|
||||
randomize()
|
||||
GameState.on_enable_photo_mode_request.connect(func(): _is_photo_mode_active = true)
|
||||
GameState.on_disable_photo_mode_request.connect(func(): _is_photo_mode_active = false)
|
||||
|
||||
_cache_environment_config()
|
||||
_initial_is_inmotion = is_inmotion
|
||||
|
||||
if curve != null and curve.get_baked_length() > 0:
|
||||
@@ -123,6 +103,24 @@ func _ready() -> void:
|
||||
else:
|
||||
print("WARNING: Draw Path3D for rails!")
|
||||
|
||||
func _cache_environment_config() -> void:
|
||||
var parent_node: Node = get_parent()
|
||||
if parent_node != null:
|
||||
var day_night_node := parent_node.get_node_or_null("DayNight") as EnvironmentManagerRoot
|
||||
if day_night_node != null:
|
||||
environment_config = day_night_node.environment_config
|
||||
return
|
||||
|
||||
var current_scene: Node = get_tree().current_scene
|
||||
if current_scene == null:
|
||||
return
|
||||
|
||||
for child in current_scene.get_children():
|
||||
var environment_manager := child as EnvironmentManagerRoot
|
||||
if environment_manager != null:
|
||||
environment_config = environment_manager.environment_config
|
||||
return
|
||||
|
||||
func _apply_initial_train_start() -> void:
|
||||
if train_instance == null or curve == null:
|
||||
return
|
||||
@@ -131,65 +129,35 @@ func _apply_initial_train_start() -> void:
|
||||
if total_length <= 0.0:
|
||||
return
|
||||
|
||||
match train_start_mode:
|
||||
TrainStartMode.RANDOM_POSITION:
|
||||
train_progress = randf() * total_length
|
||||
_update_next_stop_index_from_progress()
|
||||
TrainStartMode.SPECIFIED_STATION:
|
||||
if stop_offset.is_empty():
|
||||
train_progress = wrapf(train_progress, 0.0, total_length)
|
||||
_update_next_stop_index_from_progress()
|
||||
else:
|
||||
var stop_index: int = clampi(train_start_stop_index, 0, stop_offset.size() - 1)
|
||||
train_progress = stop_offset[stop_index]
|
||||
_set_next_stop_index_from_current(stop_index)
|
||||
TrainStartMode.SPECIFIED_POSITION:
|
||||
train_progress = wrapf(train_start_position, 0.0, total_length)
|
||||
_update_next_stop_index_from_progress()
|
||||
#start from a random position
|
||||
if environment_config != null and environment_config.train_start_from_random_position:
|
||||
train_progress = randf() * total_length
|
||||
_update_next_stop_index_from_progress()
|
||||
elif environment_config != null and not stop_offset.is_empty():
|
||||
#start from a specific stop
|
||||
var stop_index: int = clampi(environment_config.train_start_stop_index, 0, stop_offset.size() - 1)
|
||||
train_progress = stop_offset[stop_index]
|
||||
_set_next_stop_index_from_current(stop_index)
|
||||
else:
|
||||
train_progress = wrapf(train_progress, 0.0, total_length)
|
||||
_update_next_stop_index_from_progress()
|
||||
|
||||
_apply_train_facing_direction(total_length)
|
||||
_update_next_stop_index_from_progress()
|
||||
_snap_train_to_progress()
|
||||
|
||||
func _apply_train_facing_direction(total_length: float) -> void:
|
||||
_train_direction_sign = 1.0
|
||||
if train_facing_direction == TrainFacingDirection.KEEP_PATH_DIRECTION or curve == null:
|
||||
return
|
||||
if total_length <= 0.0:
|
||||
return
|
||||
|
||||
var center_progress: float = wrapf(train_progress, 0.0, total_length)
|
||||
var center_position: Vector3 = to_global(curve.sample_baked(center_progress, true))
|
||||
var forward_progress: float = wrapf(center_progress + 2.0, 0.0, total_length)
|
||||
var forward_position: Vector3 = to_global(curve.sample_baked(forward_progress, true))
|
||||
var forward_direction: Vector3 = forward_position - center_position
|
||||
if forward_direction.length_squared() <= 0.0001 or is_zero_approx(forward_direction.x):
|
||||
return
|
||||
|
||||
var desired_x_sign: float = -1.0 if train_facing_direction == TrainFacingDirection.LOCOMOTIVE_LEFT else 1.0
|
||||
if forward_direction.x * desired_x_sign < 0.0:
|
||||
_train_direction_sign = -1.0
|
||||
|
||||
if not is_zero_approx(train_speed):
|
||||
train_speed = absf(train_speed) * _train_direction_sign
|
||||
|
||||
func _apply_train_start_delay() -> void:
|
||||
if not _initial_is_inmotion:
|
||||
return
|
||||
|
||||
var should_start_after_delay: bool = train_start_after_delay
|
||||
var start_delay_seconds: float = maxf(train_start_delay_seconds, 0.0)
|
||||
var start_delay_seconds: float = 0.0
|
||||
if environment_config != null:
|
||||
start_delay_seconds = maxf(environment_config.train_start_delay_seconds, 0.0)
|
||||
if start_delay_seconds <= 0.0:
|
||||
if not should_start_after_delay:
|
||||
is_inmotion = false
|
||||
return
|
||||
|
||||
is_inmotion = false
|
||||
await get_tree().create_timer(start_delay_seconds).timeout
|
||||
if not is_inside_tree():
|
||||
return
|
||||
if not should_start_after_delay:
|
||||
return
|
||||
|
||||
is_inmotion = _initial_is_inmotion
|
||||
|
||||
@@ -234,9 +202,13 @@ func _snap_train_to_progress() -> void:
|
||||
|
||||
train_progress = wrapf(train_progress, 0.0, total_length)
|
||||
var center_position: Vector3 = to_global(curve.sample_baked(train_progress, true))
|
||||
var prog_forward: float = wrapf(train_progress + 2.0, 0.0, total_length)
|
||||
var forward_position: Vector3 = to_global(curve.sample_baked(prog_forward, true))
|
||||
|
||||
train_instance.global_position = center_position
|
||||
_orient_vehicle_to_track(train_instance, train_progress, total_length)
|
||||
if center_position.distance_to(forward_position) > 0.01:
|
||||
train_instance.look_at(forward_position, Vector3.UP)
|
||||
train_instance.rotate_y(PI)
|
||||
|
||||
if cameras:
|
||||
cameras.global_position = center_position
|
||||
@@ -302,9 +274,6 @@ func build_rails() -> void:
|
||||
rail_piece.add_child(rail_dx)
|
||||
|
||||
func _plan_stops() -> void:
|
||||
stop_offset.clear()
|
||||
stops_position.clear()
|
||||
|
||||
var current_stops = []
|
||||
for child in get_children():
|
||||
if child is Marker3D:
|
||||
@@ -318,58 +287,8 @@ func _plan_stops() -> void:
|
||||
stop_offset.append(data["offset"])
|
||||
stops_position.append(data["position"])
|
||||
|
||||
func _advance_next_stop_index(go_forward: bool) -> void:
|
||||
if stop_offset.is_empty():
|
||||
next_stop_index = 0
|
||||
return
|
||||
|
||||
if go_forward:
|
||||
next_stop_index += 1
|
||||
if next_stop_index >= stop_offset.size():
|
||||
next_stop_index = 0
|
||||
else:
|
||||
next_stop_index -= 1
|
||||
if next_stop_index < 0:
|
||||
next_stop_index = stop_offset.size() - 1
|
||||
|
||||
func _find_next_valid_stop(go_forward: bool) -> bool:
|
||||
if stop_offset.is_empty():
|
||||
return false
|
||||
|
||||
for i in range(stop_offset.size()):
|
||||
if _is_stop_valid(next_stop_index):
|
||||
return true
|
||||
_advance_next_stop_index(go_forward)
|
||||
|
||||
return false
|
||||
|
||||
func _is_stop_valid(stop_index: int) -> bool:
|
||||
if not require_station_for_stop:
|
||||
return true
|
||||
if stop_index < 0 or stop_index >= stops_position.size():
|
||||
return false
|
||||
|
||||
return _has_station_near_position(stops_position[stop_index])
|
||||
|
||||
func _has_station_near_position(stop_position: Vector3) -> bool:
|
||||
var radius_sq := station_stop_detection_radius * station_stop_detection_radius
|
||||
for station in get_tree().get_nodes_in_group(STATION_STOP_GROUP):
|
||||
var station_node := station as Node3D
|
||||
if station_node == null or not is_instance_valid(station_node):
|
||||
continue
|
||||
|
||||
var delta := station_node.global_position - stop_position
|
||||
var horizontal_dist_sq := delta.x * delta.x + delta.z * delta.z
|
||||
if horizontal_dist_sq <= radius_sq:
|
||||
return true
|
||||
|
||||
return false
|
||||
|
||||
func _input(event: InputEvent) -> void:
|
||||
if _is_photo_mode_active: return
|
||||
if EnvironmentManagerRoot.is_keyboard_input_blocked(get_tree()):
|
||||
return
|
||||
|
||||
if event is InputEventKey and event.pressed and not event.echo:
|
||||
if event.keycode == KEY_T:
|
||||
_goto_next_stop()
|
||||
@@ -400,9 +319,6 @@ func _test_manual_fireworks() -> void:
|
||||
func _goto_next_stop() -> void:
|
||||
if stop_offset.size() == 0 or stop_ongoing or is_restarting:
|
||||
return
|
||||
if not _find_next_valid_stop(train_speed >= 0.0):
|
||||
return
|
||||
|
||||
var target_offset = stop_offset[next_stop_index]
|
||||
train_progress = target_offset
|
||||
_execute_stop(train_speed >= 0)
|
||||
@@ -412,7 +328,6 @@ func _physics_process(delta: float) -> void:
|
||||
train_move(delta)
|
||||
|
||||
func input_controls_management(delta: float) -> void:
|
||||
if EnvironmentManagerRoot.is_keyboard_input_blocked(get_tree()): return
|
||||
if not is_inmotion or _is_photo_mode_active: return
|
||||
if Input.is_action_pressed("train_speed_up"):
|
||||
train_speed += manual_acceleration * delta
|
||||
@@ -429,31 +344,23 @@ func train_move(delta: float) -> void:
|
||||
|
||||
if not stop_ongoing:
|
||||
var last_progress = train_progress
|
||||
var has_valid_stop := false
|
||||
|
||||
if enable_stops and stop_offset.size() > 0 and not is_restarting:
|
||||
has_valid_stop = _find_next_valid_stop(train_speed >= 0.0)
|
||||
if has_valid_stop:
|
||||
var target_offset = stop_offset[next_stop_index]
|
||||
var dist = target_offset - train_progress
|
||||
dist = wrapf(dist + total_length / 2.0, 0.0, total_length) - total_length / 2.0
|
||||
|
||||
if abs(dist) < brake_distance and sign(dist) == sign(train_speed):
|
||||
var t = abs(dist) / brake_distance
|
||||
stop_multiply = max(smoothstep(0.0, 1.0, t), 0.05)
|
||||
else:
|
||||
stop_multiply = 1.0
|
||||
var target_offset = stop_offset[next_stop_index]
|
||||
var dist = target_offset - train_progress
|
||||
dist = wrapf(dist + total_length / 2.0, 0.0, total_length) - total_length / 2.0
|
||||
|
||||
if abs(dist) < brake_distance and sign(dist) == sign(train_speed):
|
||||
var t = abs(dist) / brake_distance
|
||||
stop_multiply = max(smoothstep(0.0, 1.0, t), 0.05)
|
||||
else:
|
||||
stop_multiply = 1.0
|
||||
|
||||
var current_speed = train_speed * stop_multiply
|
||||
var next_progress: float = train_progress + current_speed * delta
|
||||
var wrapped_forward: bool = current_speed > 0.0 and next_progress >= total_length
|
||||
var wrapped_back: bool = current_speed < 0.0 and next_progress < 0.0
|
||||
train_progress = wrapf(next_progress, 0.0, total_length)
|
||||
train_progress += current_speed * delta
|
||||
_track_steam_distance(abs(current_speed) * delta)
|
||||
|
||||
if enable_stops and stop_offset.size() > 0 and has_valid_stop:
|
||||
if enable_stops and stop_offset.size() > 0:
|
||||
var target_offset = stop_offset[next_stop_index]
|
||||
var exceeded_forward = (current_speed > 0 and last_progress < target_offset and train_progress >= target_offset)
|
||||
var exceeded_back = (current_speed < 0 and last_progress > target_offset and train_progress <= target_offset)
|
||||
@@ -462,9 +369,11 @@ func train_move(delta: float) -> void:
|
||||
train_progress = target_offset
|
||||
_execute_stop(current_speed > 0)
|
||||
|
||||
if wrapped_forward:
|
||||
if train_progress > total_length:
|
||||
train_progress -= total_length
|
||||
if stop_offset.size() > 0: next_stop_index = 0
|
||||
elif wrapped_back:
|
||||
elif train_progress < 0:
|
||||
train_progress += total_length
|
||||
if stop_offset.size() > 0: next_stop_index = stop_offset.size() - 1
|
||||
|
||||
var center_position = to_global(curve.sample_baked(train_progress, true))
|
||||
@@ -475,7 +384,8 @@ func train_move(delta: float) -> void:
|
||||
|
||||
if center_position.distance_to(forward_position) > 0.01:
|
||||
train_instance.global_position = center_position
|
||||
_orient_vehicle_to_track(train_instance, train_progress, total_length)
|
||||
train_instance.look_at(forward_position, Vector3.UP)
|
||||
train_instance.rotate_y(PI)
|
||||
|
||||
if cameras:
|
||||
cameras.global_position = center_position
|
||||
@@ -513,22 +423,44 @@ func _track_steam_distance(distance_units: float) -> void:
|
||||
|
||||
# Always track the global distance in our save file (for UI and persistency)
|
||||
GameState.save_data.total_distance_km += distance_units * DISTANCE_KM_PER_UNIT
|
||||
StatsManager.add_distance_km(distance_units * DISTANCE_KM_PER_UNIT)
|
||||
|
||||
func _execute_stop(go_forward: bool = true) -> void:
|
||||
if not _find_next_valid_stop(go_forward):
|
||||
stop_multiply = 1.0
|
||||
# Steam specific logic
|
||||
if not SteamManager.is_on_steam:
|
||||
return
|
||||
|
||||
stop_ongoing = true
|
||||
stop_multiply = 0.0
|
||||
_pending_steam_distance_km += distance_units * DISTANCE_KM_PER_UNIT
|
||||
var whole_km: int = int(floor(_pending_steam_distance_km))
|
||||
if whole_km <= 0:
|
||||
return
|
||||
|
||||
var current_stop_index = next_stop_index
|
||||
StatsManager.add_int("stat_stop_number", 1)
|
||||
_pending_steam_distance_km -= float(whole_km)
|
||||
var total_distance_km: int = StatsManager.get_int(STEAM_DISTANCE_STAT) + whole_km
|
||||
StatsManager.set_int(STEAM_DISTANCE_STAT, total_distance_km)
|
||||
_check_distance_achievements(total_distance_km)
|
||||
StatsManager.store()
|
||||
|
||||
_advance_next_stop_index(go_forward)
|
||||
#Check achievements
|
||||
func _check_distance_achievements(total_distance_km: int) -> void:
|
||||
if total_distance_km >= 100:
|
||||
AchievementManager.unlock("ACH_DISTANCE_100")
|
||||
if total_distance_km >= 200:
|
||||
AchievementManager.unlock("ACH_DISTANCE_200")
|
||||
|
||||
func _execute_stop(go_forward: bool = true) -> void:
|
||||
stop_ongoing = true
|
||||
stop_multiply = 0.0
|
||||
|
||||
var current_stop_index = next_stop_index
|
||||
|
||||
if go_forward:
|
||||
next_stop_index += 1
|
||||
if next_stop_index >= stop_offset.size():
|
||||
next_stop_index = 0
|
||||
else:
|
||||
next_stop_index -= 1
|
||||
if next_stop_index < 0:
|
||||
next_stop_index = stop_offset.size() - 1
|
||||
|
||||
if fireworks_scene != null:
|
||||
var marker_position = stops_position[current_stop_index]
|
||||
var firework_number = randi_range(5, 8)
|
||||
@@ -667,10 +599,6 @@ func _snap_wagons_to_progress(total_length: float = 0.0) -> void:
|
||||
if total_length <= 0.0:
|
||||
return
|
||||
|
||||
var previous_progress: float = wrapf(train_progress, 0.0, total_length)
|
||||
var previous_position: Vector3 = to_global(curve.sample_baked(previous_progress, true))
|
||||
var previous_wagon_offset: float = 0.0
|
||||
|
||||
for i in range(wagon_instances.size()):
|
||||
var wagon: Node3D = wagon_instances[i]
|
||||
if not is_instance_valid(wagon):
|
||||
@@ -680,101 +608,17 @@ func _snap_wagons_to_progress(total_length: float = 0.0) -> void:
|
||||
if i < wagon_progress_offsets.size():
|
||||
wagon_offset = wagon_progress_offsets[i]
|
||||
|
||||
var wagon_progress: float = train_progress - wagon_offset * _train_direction_sign
|
||||
var segment_spacing: float = maxf(wagon_offset - previous_wagon_offset, 0.1)
|
||||
var wagon_progress: float = train_progress - wagon_offset
|
||||
|
||||
var vehicle_progress: float = wrapf(wagon_progress, 0.0, total_length)
|
||||
var center_position: Vector3 = to_global(curve.sample_baked(vehicle_progress, true))
|
||||
var zero_spacing_fix_weight: float = _get_zero_spacing_fix_weight(previous_progress, vehicle_progress, total_length)
|
||||
if zero_spacing_fix_weight > 0.0:
|
||||
var target_distance: float = _get_zero_spacing_target_distance(segment_spacing)
|
||||
var corrected_progress: float = _find_zero_spacing_progress(previous_progress, previous_position, segment_spacing, target_distance, total_length)
|
||||
vehicle_progress = _lerp_progress_on_track(vehicle_progress, corrected_progress, zero_spacing_fix_weight, total_length)
|
||||
center_position = to_global(curve.sample_baked(vehicle_progress, true))
|
||||
var prog_forward: float = wrapf(vehicle_progress + 2.0, 0.0, total_length)
|
||||
var forward_position: Vector3 = to_global(curve.sample_baked(prog_forward, true))
|
||||
|
||||
wagon.global_position = center_position
|
||||
_orient_vehicle_to_track(wagon, vehicle_progress, total_length)
|
||||
|
||||
previous_progress = vehicle_progress
|
||||
previous_position = center_position
|
||||
previous_wagon_offset = wagon_offset
|
||||
|
||||
func _orient_vehicle_to_track(vehicle: Node3D, progress: float, total_length: float) -> void:
|
||||
if vehicle == null or curve == null or total_length <= 0.0:
|
||||
return
|
||||
|
||||
var center_progress: float = wrapf(progress, 0.0, total_length)
|
||||
var center_position: Vector3 = to_global(curve.sample_baked(center_progress, true))
|
||||
var forward_progress: float = wrapf(center_progress + 2.0 * _train_direction_sign, 0.0, total_length)
|
||||
var forward_position: Vector3 = to_global(curve.sample_baked(forward_progress, true))
|
||||
if center_position.distance_to(forward_position) <= 0.01:
|
||||
return
|
||||
|
||||
vehicle.look_at(forward_position, Vector3.UP)
|
||||
vehicle.rotate_y(PI)
|
||||
|
||||
func _get_zero_spacing_fix_weight(previous_progress: float, vehicle_progress: float, total_length: float) -> float:
|
||||
var distance_to_zero: float = minf(
|
||||
_get_progress_distance_to_zero(previous_progress, total_length),
|
||||
_get_progress_distance_to_zero(vehicle_progress, total_length)
|
||||
)
|
||||
var full_fix_distance: float = maxf(TRACK_ZERO_SPACING_FIX_DISTANCE - TRACK_ZERO_SPACING_BLEND_DISTANCE, 0.0)
|
||||
return 1.0 - smoothstep(full_fix_distance, TRACK_ZERO_SPACING_FIX_DISTANCE, distance_to_zero)
|
||||
|
||||
func _get_progress_distance_to_zero(progress: float, total_length: float) -> float:
|
||||
var wrapped_progress: float = wrapf(progress, 0.0, total_length)
|
||||
return minf(wrapped_progress, total_length - wrapped_progress)
|
||||
|
||||
func _get_zero_spacing_target_distance(segment_spacing: float) -> float:
|
||||
return minf(maxf(segment_spacing * TRACK_ZERO_SPACING_TARGET_RATIO, TRACK_ZERO_SPACING_MIN_DISTANCE), segment_spacing)
|
||||
|
||||
func _find_zero_spacing_progress(previous_progress: float, previous_position: Vector3, segment_spacing: float, minimum_distance: float, total_length: float) -> float:
|
||||
var start_distance: float = minf(minimum_distance, segment_spacing)
|
||||
var best_progress: float = wrapf(previous_progress - start_distance * _train_direction_sign, 0.0, total_length)
|
||||
var search_limit: float = minf(maxf(segment_spacing, minimum_distance) + TRACK_ZERO_SPACING_SEARCH_EXTRA, total_length)
|
||||
var search_distance: float = start_distance
|
||||
var previous_search_distance: float = start_distance
|
||||
|
||||
while search_distance <= search_limit:
|
||||
var candidate_progress: float = wrapf(previous_progress - search_distance * _train_direction_sign, 0.0, total_length)
|
||||
var candidate_position: Vector3 = to_global(curve.sample_baked(candidate_progress, true))
|
||||
best_progress = candidate_progress
|
||||
if previous_position.distance_to(candidate_position) >= minimum_distance:
|
||||
if is_equal_approx(search_distance, start_distance):
|
||||
return candidate_progress
|
||||
|
||||
return _refine_zero_spacing_progress(
|
||||
previous_progress,
|
||||
previous_position,
|
||||
previous_search_distance,
|
||||
search_distance,
|
||||
minimum_distance,
|
||||
total_length
|
||||
)
|
||||
|
||||
previous_search_distance = search_distance
|
||||
search_distance += TRACK_ZERO_SPACING_SEARCH_STEP
|
||||
|
||||
return best_progress
|
||||
|
||||
func _refine_zero_spacing_progress(previous_progress: float, previous_position: Vector3, min_search_distance: float, max_search_distance: float, minimum_distance: float, total_length: float) -> float:
|
||||
var low_distance: float = min_search_distance
|
||||
var high_distance: float = max_search_distance
|
||||
|
||||
for i in range(8):
|
||||
var mid_distance: float = (low_distance + high_distance) * 0.5
|
||||
var mid_progress: float = wrapf(previous_progress - mid_distance, 0.0, total_length)
|
||||
var mid_position: Vector3 = to_global(curve.sample_baked(mid_progress, true))
|
||||
if previous_position.distance_to(mid_position) >= minimum_distance:
|
||||
high_distance = mid_distance
|
||||
else:
|
||||
low_distance = mid_distance
|
||||
|
||||
return wrapf(previous_progress - high_distance, 0.0, total_length)
|
||||
|
||||
func _lerp_progress_on_track(from_progress: float, to_progress: float, weight: float, total_length: float) -> float:
|
||||
var wrapped_delta: float = wrapf(to_progress - from_progress + total_length * 0.5, 0.0, total_length) - total_length * 0.5
|
||||
return wrapf(from_progress + wrapped_delta * clampf(weight, 0.0, 1.0), 0.0, total_length)
|
||||
if center_position.distance_to(forward_position) > 0.01:
|
||||
wagon.look_at(forward_position, Vector3.UP)
|
||||
wagon.rotate_y(PI)
|
||||
|
||||
func _get_vehicle_length(vehicle: Node3D) -> float:
|
||||
var bounds: AABB = _get_node_local_bounds(vehicle, vehicle)
|
||||
|
||||
@@ -115,21 +115,21 @@ func on_change_camera_request(camera_index: int) -> void:
|
||||
var next_cam = array_camera[camera_index]
|
||||
set_camera(next_cam)
|
||||
|
||||
#func _unhandled_input(event: InputEvent) -> void:
|
||||
#var current_cam = get_viewport().get_camera_3d()
|
||||
#var is_photo_mode = current_cam != null and not current_cam in array_camera
|
||||
#if is_photo_mode:
|
||||
#return
|
||||
#
|
||||
#if event is InputEventKey and event.pressed and not event.echo:
|
||||
#match event.keycode:
|
||||
#KEY_1:
|
||||
#if array_camera.size() > 0: set_camera(array_camera[0])
|
||||
#KEY_2:
|
||||
#if array_camera.size() > 1: set_camera(array_camera[1])
|
||||
#KEY_3:
|
||||
#if array_camera.size() > 2: set_camera(array_camera[2])
|
||||
#KEY_4:
|
||||
#if array_camera.size() > 3: set_camera(array_camera[3])
|
||||
#KEY_5:
|
||||
#if array_camera.size() > 4: set_camera(array_camera[4])
|
||||
func _unhandled_input(event: InputEvent) -> void:
|
||||
var current_cam = get_viewport().get_camera_3d()
|
||||
var is_photo_mode = current_cam != null and not current_cam in array_camera
|
||||
if is_photo_mode:
|
||||
return
|
||||
|
||||
if event is InputEventKey and event.pressed and not event.echo:
|
||||
match event.keycode:
|
||||
KEY_1:
|
||||
if array_camera.size() > 0: set_camera(array_camera[0])
|
||||
KEY_2:
|
||||
if array_camera.size() > 1: set_camera(array_camera[1])
|
||||
KEY_3:
|
||||
if array_camera.size() > 2: set_camera(array_camera[2])
|
||||
KEY_4:
|
||||
if array_camera.size() > 3: set_camera(array_camera[3])
|
||||
KEY_5:
|
||||
if array_camera.size() > 4: set_camera(array_camera[4])
|
||||
|
||||
@@ -30,7 +30,6 @@ func _ready() -> void:
|
||||
UIEvents.toggle_pause_daytime.connect(_on_toggle_pause_daytime)
|
||||
UIEvents.time_option_item_changed.connect(_time_option_changed)
|
||||
|
||||
paused = environment_config.start_day_time_paused
|
||||
current_time = environment_config.start_time
|
||||
update_time(current_time)
|
||||
|
||||
@@ -91,30 +90,11 @@ func _time_option_changed(index: int) -> void:
|
||||
|
||||
_time_tween = create_tween()
|
||||
|
||||
var start_time = current_time
|
||||
|
||||
# Gestione logica lineare: Notte(0.0) - Mattina(0.25) - Giorno(0.45) - Tramonto(0.8) - Notte(1.0)
|
||||
# Per evitare di attraversare fasi intermedie opposte, forziamo il percorso su questo segmento.
|
||||
|
||||
if index == TIME_OPTION_NIGHT:
|
||||
# Da Mattina a Notte -> andiamo a 0.0. Dal Giorno in poi -> andiamo a 1.0.
|
||||
if start_time < environment_config.day:
|
||||
target_time = 0.0
|
||||
else:
|
||||
target_time = 1.0
|
||||
else:
|
||||
# Se partiamo da Notte (valori vicini a 0.0 o 1.0)
|
||||
if start_time < 0.1 or start_time > 0.9:
|
||||
if index == TIME_OPTION_SUNRISE:
|
||||
# Per andare a Mattina, partiamo dal lato 0.0
|
||||
if start_time > 0.9:
|
||||
start_time -= 1.0
|
||||
else:
|
||||
# Per andare a Giorno o Tramonto, partiamo dal lato 1.0
|
||||
if start_time < 0.1:
|
||||
start_time += 1.0
|
||||
|
||||
_time_tween.tween_method(set_time, start_time, target_time, time_transition_duration)
|
||||
# Always move forward in time for a natural transition
|
||||
if target_time < current_time:
|
||||
target_time += 1.0
|
||||
|
||||
_time_tween.tween_method(set_time, current_time, target_time, time_transition_duration)
|
||||
|
||||
func _on_set_day_time(value: float) -> void:
|
||||
set_time(value)
|
||||
|
||||
@@ -7,14 +7,6 @@ const DYNAMIC_ENVIRONMENT_UPDATES_PER_FRAME: int = 32 #how many update of the en
|
||||
|
||||
@export var environment_config: EnvironmentConfig
|
||||
|
||||
@export_group("Input")
|
||||
@export var block_keyboard_input: bool = false:
|
||||
set(value):
|
||||
if block_keyboard_input == value:
|
||||
return
|
||||
block_keyboard_input = value
|
||||
_apply_keyboard_input_block()
|
||||
|
||||
@export_group("Camera")
|
||||
@export var camera: Camera3D
|
||||
@export var camera_pivot: Node3D
|
||||
@@ -48,24 +40,8 @@ var day_tween: Tween
|
||||
var day_time: float = 0.0
|
||||
var pending_environment_nodes: Dictionary = {}
|
||||
var weather_shader_no_noise: Material
|
||||
var _blocked_keyboard_events_by_action: Dictionary = {}
|
||||
|
||||
static func is_keyboard_input_blocked(tree: SceneTree) -> bool:
|
||||
if tree == null:
|
||||
return false
|
||||
|
||||
for node in tree.get_nodes_in_group("keyboard_input_blocker"):
|
||||
var environment_manager := node as EnvironmentManagerRoot
|
||||
if environment_manager != null and environment_manager.block_keyboard_input:
|
||||
return true
|
||||
|
||||
return false
|
||||
|
||||
func _enter_tree() -> void:
|
||||
add_to_group("keyboard_input_blocker")
|
||||
|
||||
func _ready() -> void:
|
||||
_apply_keyboard_input_block()
|
||||
|
||||
#connect shader when new node is added
|
||||
get_tree().node_added.connect(_on_tree_node_added)
|
||||
@@ -111,51 +87,9 @@ func _ready() -> void:
|
||||
func _process(_delta: float) -> void:
|
||||
_process_pending_environment_nodes()
|
||||
|
||||
func _input(event: InputEvent) -> void:
|
||||
if block_keyboard_input and event is InputEventKey:
|
||||
get_viewport().set_input_as_handled()
|
||||
|
||||
func _exit_tree() -> void:
|
||||
_restore_keyboard_action_events()
|
||||
remove_from_group("keyboard_input_blocker")
|
||||
|
||||
func flush_pending_environment_nodes() -> void:
|
||||
_process_pending_environment_nodes(-1)
|
||||
|
||||
func _apply_keyboard_input_block() -> void:
|
||||
if block_keyboard_input:
|
||||
_remove_keyboard_action_events()
|
||||
else:
|
||||
_restore_keyboard_action_events()
|
||||
|
||||
func _remove_keyboard_action_events() -> void:
|
||||
if not _blocked_keyboard_events_by_action.is_empty():
|
||||
return
|
||||
|
||||
for action in InputMap.get_actions():
|
||||
var keyboard_events: Array[InputEvent] = []
|
||||
for event in InputMap.action_get_events(action):
|
||||
if event is InputEventKey:
|
||||
keyboard_events.append(event)
|
||||
|
||||
if keyboard_events.is_empty():
|
||||
continue
|
||||
|
||||
_blocked_keyboard_events_by_action[action] = keyboard_events
|
||||
Input.action_release(action)
|
||||
for keyboard_event in keyboard_events:
|
||||
InputMap.action_erase_event(action, keyboard_event)
|
||||
|
||||
func _restore_keyboard_action_events() -> void:
|
||||
for action in _blocked_keyboard_events_by_action.keys():
|
||||
if not InputMap.has_action(action):
|
||||
continue
|
||||
|
||||
for keyboard_event in _blocked_keyboard_events_by_action[action]:
|
||||
InputMap.action_add_event(action, keyboard_event)
|
||||
|
||||
_blocked_keyboard_events_by_action.clear()
|
||||
|
||||
func _on_tree_node_added(node: Node) -> void:
|
||||
if node.is_in_group("wind_node") or node.is_in_group("weather_node") or node.is_in_group("weather_vegetables_node"):
|
||||
_queue_dynamic_environment_node(node)
|
||||
@@ -316,19 +250,8 @@ func select_day_time(normalized_time: float) -> void:
|
||||
#24:00 1.0000 3.0
|
||||
|
||||
if normalized_time < environment_config.sunrise:
|
||||
#Sunrise: stay night → night to alba(afternoon) → alba to morning
|
||||
var part = environment_config.sunrise / 3.0
|
||||
if normalized_time < part:
|
||||
# Stay Night
|
||||
day_time = 3.0
|
||||
elif normalized_time < part * 2.0:
|
||||
# Night to Alba (Afternoon)
|
||||
var t = (normalized_time - part) / part
|
||||
day_time = 3.0 - (t * 1.0) # 3.0 → 2.0
|
||||
else:
|
||||
# Alba (Afternoon) to Morning
|
||||
var t = (normalized_time - part * 2.0) / part
|
||||
day_time = 2.0 - (t * 1.0) # 2.0 → 1.0
|
||||
#Sunrise: night → morning
|
||||
day_time = 3.0 - (normalized_time / environment_config.sunrise) * 2.0 # 3.0 → 1.0
|
||||
elif normalized_time < environment_config.day:
|
||||
#Morning: morning → afternoon
|
||||
var t: float = (normalized_time - environment_config.sunrise) / (environment_config.day - environment_config.sunrise)
|
||||
@@ -353,17 +276,10 @@ func _update_clouds_lighting(normalized_time: float) -> void:
|
||||
return
|
||||
|
||||
if normalized_time < environment_config.sunrise:
|
||||
var part = environment_config.sunrise / 3.0
|
||||
if normalized_time < part * 2.0:
|
||||
# NOTTE / PRE-ALBA (Colori scuri, nessun rim light solare)
|
||||
cloud_material.set_shader_parameter("cloud_color", Color("1a1c2e"))
|
||||
cloud_material.set_shader_parameter("shadow_color", Color("0d0e17"))
|
||||
cloud_material.set_shader_parameter("rim_color", Color("000000"))
|
||||
else:
|
||||
# ALBA (uguale al tramonto)
|
||||
cloud_material.set_shader_parameter("cloud_color", Color("fdf3e7"))
|
||||
cloud_material.set_shader_parameter("shadow_color", Color("5c537a"))
|
||||
cloud_material.set_shader_parameter("rim_color", Color("ff9e64"))
|
||||
# NOTTE / PRE-ALBA (Colori scuri, nessun rim light solare)
|
||||
cloud_material.set_shader_parameter("cloud_color", Color("1a1c2e"))
|
||||
cloud_material.set_shader_parameter("shadow_color", Color("0d0e17"))
|
||||
cloud_material.set_shader_parameter("rim_color", Color("000000"))
|
||||
|
||||
elif normalized_time < environment_config.day:
|
||||
# MATTINA / ALBA (Colori che iniziano a scaldarsi)
|
||||
|
||||
@@ -13,10 +13,7 @@ global uniform float global_snow_accumulation_speed = 0.005;
|
||||
global uniform float global_snow_melt_time = -1.0;
|
||||
global uniform float global_snow_melt_speed = 0.1;
|
||||
global uniform float global_snow_amount = 0.0;
|
||||
global uniform vec4 global_snow_color = vec4(0.92, 0.96, 1.0, 1.0);
|
||||
global uniform float global_rain_intensity;
|
||||
const float GRASS_FULL_SNOW_START = 0.58;
|
||||
const float GRASS_FULL_SNOW_END = 0.86;
|
||||
|
||||
// --- PARAMETRI ESTETICI ---
|
||||
uniform bool billboard_enabled = true;
|
||||
@@ -136,22 +133,19 @@ void fragment() {
|
||||
// Applichiamo la variazione al colore finale dell'erba
|
||||
vec3 varied_grass_color = mix(v_final_color, variance_color.rgb, noise_sample * variance_intensity);
|
||||
|
||||
float snow_amount = pow(get_snow_progress(), 0.55);
|
||||
float snow_amount = smoothstep(0.0, 1.0, get_snow_progress());
|
||||
|
||||
float top_mask = 1.0 - shifted_uv.y;
|
||||
float snow_start = 1.0 - clamp(snow_coverage, 0.05, 1.0);
|
||||
float snow_mask = smoothstep(snow_start, 1.0, top_mask) * snow_amount * snow_visibility;
|
||||
snow_mask *= step(0.01, snow_amount);
|
||||
snow_mask = clamp(snow_mask, 0.0, 1.0);
|
||||
float full_snow_mask = smoothstep(GRASS_FULL_SNOW_START, GRASS_FULL_SNOW_END, snow_amount) * step(0.01, snow_visibility);
|
||||
float final_snow_mask = max(snow_mask, full_snow_mask);
|
||||
|
||||
vec3 snow_base_color = max(snow_color.rgb, global_snow_color.rgb);
|
||||
float snow_light = mix(0.82, 1.0, max(v_shade_factor, 0.35));
|
||||
vec3 shaded_snow = clamp(snow_base_color * snow_light, 0.0, 1.0);
|
||||
vec3 dark_snow = snow_color.rgb * (1.0 - shadow_intensity);
|
||||
vec3 shaded_snow = mix(dark_snow, snow_color.rgb, v_shade_factor);
|
||||
|
||||
// Mescoliamo il colore variato con la neve
|
||||
vec3 final_albedo = mix(varied_grass_color, shaded_snow, final_snow_mask);
|
||||
vec3 final_albedo = mix(varied_grass_color, shaded_snow, snow_mask);
|
||||
float rain_int = clamp(global_rain_intensity, 0.0, 1.0);
|
||||
final_albedo *= mix(1.0, 1.0 - wetness_darkening, rain_int);
|
||||
float final_roughness = mix(0.02, 0.005, rain_int);
|
||||
|
||||
@@ -13,8 +13,6 @@ global uniform float global_snow_melt_speed = 0.1;
|
||||
global uniform float global_snow_amount = 0.0;
|
||||
global uniform vec4 global_snow_color;
|
||||
global uniform float global_rain_intensity;
|
||||
const float LEAVES_FULL_SNOW_START = 0.58;
|
||||
const float LEAVES_FULL_SNOW_END = 0.86;
|
||||
|
||||
uniform sampler2D wind_noise : filter_linear_mipmap;
|
||||
uniform bool billboard_enabled = true;
|
||||
@@ -112,12 +110,10 @@ void fragment() {
|
||||
float top_mask = 1.0 - shifted_uv.y;
|
||||
float snow_mask = smoothstep(1.0 - snow_amount * 1.35, 1.08 - snow_amount * 1.35, top_mask) * snow_visibility;
|
||||
snow_mask *= step(0.01, snow_amount);
|
||||
float full_snow_mask = smoothstep(LEAVES_FULL_SNOW_START, LEAVES_FULL_SNOW_END, snow_amount) * clamp(snow_visibility, 0.0, 1.0);
|
||||
float final_snow_mask = max(snow_mask, full_snow_mask);
|
||||
|
||||
float snow_light = mix(0.82, 1.0, max(v_shade_factor, 0.35));
|
||||
vec3 shaded_snow = clamp(global_snow_color.rgb * snow_light, 0.0, 1.0);
|
||||
vec3 final_albedo = mix(v_final_color, shaded_snow, final_snow_mask);
|
||||
vec3 dark_snow = global_snow_color.rgb * (1.0 - shadow_intensity);
|
||||
vec3 shaded_snow = mix(dark_snow, global_snow_color.rgb, v_shade_factor);
|
||||
vec3 final_albedo = mix(v_final_color, shaded_snow, snow_mask);
|
||||
|
||||
// Rain wetness: darken and make shinier
|
||||
float rain_int = clamp(global_rain_intensity, 0.0, 1.0);
|
||||
|
||||
@@ -170,7 +170,7 @@ func _process(delta: float) -> void:
|
||||
base_grad_intensity = lerp(environment_config.grad_intensity_morning, environment_config.grad_intensity_afternoon, t)
|
||||
base_water_color = environment_config.water_color_morning.lerp(environment_config.water_color_afternoon, t)
|
||||
base_rotation_sun = environment_config.sun_rotation_morning.lerp(environment_config.sun_rotation_afternoon, t)
|
||||
elif day_time <= 3.0:
|
||||
else:
|
||||
var t = day_time - 2.0
|
||||
base_tint = environment_config.afternoon_color.lerp(environment_config.night_color, t)
|
||||
base_sky_top = environment_config.sky_top_afternoon.lerp(environment_config.sky_top_night, t)
|
||||
@@ -184,20 +184,6 @@ func _process(delta: float) -> void:
|
||||
base_grad_intensity = lerp(environment_config.grad_intensity_afternoon, environment_config.grad_intensity_night, t)
|
||||
base_water_color = environment_config.water_color_afternoon.lerp(environment_config.water_color_night, t)
|
||||
base_rotation_sun = environment_config.sun_rotation_afternoon.lerp(environment_config.sun_rotation_night, t)
|
||||
else:
|
||||
var t = day_time - 3.0
|
||||
base_tint = environment_config.night_color.lerp(environment_config.morning_color, t)
|
||||
base_sky_top = environment_config.sky_top_night.lerp(environment_config.sky_top_morning, t)
|
||||
base_sky_horizon = environment_config.sky_horizon_night.lerp(environment_config.sky_horizon_morning, t)
|
||||
base_fog_color = environment_config.fog_color_night.lerp(environment_config.fog_color_morning, t)
|
||||
base_fog_density = lerp(environment_config.fog_density_night, environment_config.fog_density_morning, t)
|
||||
base_bloom = lerp(environment_config.glow_night, environment_config.glow_morning, t)
|
||||
base_exposure = lerp(environment_config.exposure_night, environment_config.exposure_morning, t)
|
||||
base_grad_top = environment_config.grad_top_night.lerp(environment_config.grad_top_morning, t)
|
||||
base_grad_bot = environment_config.grad_bot_night.lerp(environment_config.grad_bot_morning, t)
|
||||
base_grad_intensity = lerp(environment_config.grad_intensity_night, environment_config.grad_intensity_morning, t)
|
||||
base_water_color = environment_config.water_color_night.lerp(environment_config.water_color_morning, t)
|
||||
base_rotation_sun = environment_config.sun_rotation_night.lerp(environment_config.sun_rotation_morning, t)
|
||||
|
||||
var weather_color = environment_config.rain_mode_color
|
||||
if is_storm:
|
||||
@@ -326,30 +312,26 @@ func create_sound_players():
|
||||
func _get_rain_day_color() -> Color:
|
||||
if day_time <= 2.0:
|
||||
return environment_config.rain_morning_color.lerp(environment_config.rain_afternoon_color, day_time - 1.0)
|
||||
elif day_time <= 3.0:
|
||||
return environment_config.rain_afternoon_color.lerp(environment_config.rain_night_color, day_time - 2.0)
|
||||
return environment_config.rain_night_color.lerp(environment_config.rain_morning_color, day_time - 3.0)
|
||||
|
||||
return environment_config.rain_afternoon_color.lerp(environment_config.rain_night_color, day_time - 2.0)
|
||||
|
||||
func _get_storm_day_color() -> Color:
|
||||
if day_time <= 2.0:
|
||||
return environment_config.storm_morning_color.lerp(environment_config.storm_afternoon_color, day_time - 1.0)
|
||||
elif day_time <= 3.0:
|
||||
return environment_config.storm_afternoon_color.lerp(environment_config.storm_night_color, day_time - 2.0)
|
||||
return environment_config.storm_night_color.lerp(environment_config.storm_morning_color, day_time - 3.0)
|
||||
|
||||
return environment_config.storm_afternoon_color.lerp(environment_config.storm_night_color, day_time - 2.0)
|
||||
|
||||
func _get_rain_day_exposure() -> float:
|
||||
if day_time <= 2.0:
|
||||
return lerp(environment_config.rain_exposure_morning, environment_config.rain_exposure_afternoon, day_time - 1.0)
|
||||
elif day_time <= 3.0:
|
||||
return lerp(environment_config.rain_exposure_afternoon, environment_config.rain_exposure_night, day_time - 2.0)
|
||||
return lerp(environment_config.rain_exposure_night, environment_config.rain_exposure_morning, day_time - 3.0)
|
||||
|
||||
return lerp(environment_config.rain_exposure_afternoon, environment_config.rain_exposure_night, day_time - 2.0)
|
||||
|
||||
func _get_storm_day_exposure() -> float:
|
||||
if day_time <= 2.0:
|
||||
return lerp(environment_config.storm_exposure_morning, environment_config.storm_exposure_afternoon, day_time - 1.0)
|
||||
elif day_time <= 3.0:
|
||||
return lerp(environment_config.storm_exposure_afternoon, environment_config.storm_exposure_night, day_time - 2.0)
|
||||
return lerp(environment_config.storm_exposure_night, environment_config.storm_exposure_morning, day_time - 3.0)
|
||||
|
||||
return lerp(environment_config.storm_exposure_afternoon, environment_config.storm_exposure_night, day_time - 2.0)
|
||||
|
||||
#region camera
|
||||
func _set_camera(curr_camera: Camera3D):
|
||||
|
||||
@@ -17,8 +17,6 @@ global uniform float global_snow_cap_flatness_end = 0.96;
|
||||
global uniform float global_snow_cap_noise_scale = 0.22;
|
||||
global uniform float global_snow_cap_noise_strength = 0.18;
|
||||
const float SNOW_VISUAL_RESPONSE = 0.55;
|
||||
const float FULL_SNOW_VISUAL_START = 0.82;
|
||||
const float FULL_SNOW_VISUAL_END = 0.98;
|
||||
uniform bool snow_noise_enabled = true;
|
||||
uniform float snow_noise_scale : hint_range(0.01, 1.0) = 0.15;
|
||||
uniform float snow_edge_softness : hint_range(0.01, 0.5) = 0.2;
|
||||
@@ -158,8 +156,6 @@ void fragment() {
|
||||
float snow_factor = max(snow_edge * snow_coverage, flat_accumulation);
|
||||
float snow_opacity = clamp(snow_factor, 0.0, 1.0);
|
||||
snow_opacity = max(snow_opacity, flat_accumulation * mix(0.45, 0.9, snow_noise_mask));
|
||||
float full_snow_opacity = snow_edge * smoothstep(FULL_SNOW_VISUAL_START, FULL_SNOW_VISUAL_END, snow_progress);
|
||||
snow_opacity = max(snow_opacity, full_snow_opacity);
|
||||
|
||||
float shade = mix(-snow_color_variation, snow_color_variation, noise_val);
|
||||
vec3 snow_albedo = clamp(global_snow_color.rgb + vec3(shade), 0.0, 1.0);
|
||||
|
||||
@@ -4,7 +4,6 @@ extends Resource
|
||||
@export_group("Day")
|
||||
@export var start_time: float = 0.0 #start time of the day
|
||||
@export var day_duration: float = 300.0 #Duration of a full day cycle in seconds
|
||||
@export var start_day_time_paused: bool = false #Start with day time paused, without advancing the day cycle
|
||||
@export var sunrise: float = 0.25 #day_time 1.0→2.0 (night colors → morning colors)
|
||||
@export var day: float = 0.45 #day_time 2.0→2.0 (stays morning/afternoon)
|
||||
@export var sunset: float = 0.80 #day_time 2.0→3.0 (afternoon colors → night colors)
|
||||
@@ -155,6 +154,13 @@ extends Resource
|
||||
@export var godray_spawn_height: float = 5.0 #Y world position where god rays spawn
|
||||
@export var godray_scale: Vector3 = Vector3(2.0, 6.0, 2.0) #Scale of the god ray mesh
|
||||
|
||||
#Train start settings
|
||||
@export_group("Train Start")
|
||||
@export var train_start_from_random_position: bool = true #When enabled the train starts from a random offset on the rail curve instead of a stop
|
||||
@export_range(0, 64, 1, "or_greater") var train_start_stop_index: int = 1 #Stop index used for the train start when random start is disabled
|
||||
@export var train_start_delay_seconds: float = 3.0 #Seconds the train waits before starting at game launch
|
||||
@export var train_start_acceleration_seconds: float = 4.0 #Seconds used to progressively reach normal train speed after launch
|
||||
|
||||
#Snow settings
|
||||
@export_group("Snow")
|
||||
@export var snow_amount: float = 0.0 #Initial snow coverage amount (0.0 = none, 1.0 = full)
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="font_data_dynamic"
|
||||
type="FontFile"
|
||||
uid="uid://d08lffa62cwe4"
|
||||
path="res://.godot/imported/DePixelSchmal.ttf-8ac33b7cef810a277bf67f13d849d16b.fontdata"
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/font/DePixelSchmal.ttf"
|
||||
dest_files=["res://.godot/imported/DePixelSchmal.ttf-8ac33b7cef810a277bf67f13d849d16b.fontdata"]
|
||||
|
||||
[params]
|
||||
|
||||
Rendering=null
|
||||
antialiasing=1
|
||||
generate_mipmaps=false
|
||||
disable_embedded_bitmaps=true
|
||||
multichannel_signed_distance_field=false
|
||||
msdf_pixel_range=8
|
||||
msdf_size=48
|
||||
allow_system_fallback=true
|
||||
force_autohinter=false
|
||||
modulate_color_glyphs=false
|
||||
hinting=1
|
||||
subpixel_positioning=4
|
||||
keep_rounding_remainders=true
|
||||
oversampling=0.0
|
||||
Fallbacks=null
|
||||
fallbacks=[]
|
||||
Compress=null
|
||||
compress=true
|
||||
preload=[]
|
||||
language_support={}
|
||||
script_support={}
|
||||
opentype_features={}
|
||||
@@ -1,6 +0,0 @@
|
||||
[gd_resource type="Theme" format=3 uid="uid://dib2yjsuiyhl"]
|
||||
|
||||
[ext_resource type="FontFile" uid="uid://d08lffa62cwe4" path="res://core/font/DePixelSchmal.ttf" id="1_svhk7"]
|
||||
|
||||
[resource]
|
||||
default_font = ExtResource("1_svhk7")
|
||||
|
Before Width: | Height: | Size: 208 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dpsyqpi74dnvu"
|
||||
path="res://.godot/imported/pg_3.png-03cc0909b35fe8817a39820d5cb898ba.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_2/pg_3.png"
|
||||
dest_files=["res://.godot/imported/pg_3.png-03cc0909b35fe8817a39820d5cb898ba.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
|
||||
|
Before Width: | Height: | Size: 195 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://decvm18okiuxw"
|
||||
path="res://.godot/imported/pg_3_vertical.png-c2c3e741e77873e5b55455c2f973c775.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_2/pg_3_vertical.png"
|
||||
dest_files=["res://.godot/imported/pg_3_vertical.png-c2c3e741e77873e5b55455c2f973c775.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
|
||||
|
Before Width: | Height: | Size: 309 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://nqkwsl05pj6t"
|
||||
path="res://.godot/imported/pg_3_vertical_2.png-733981bb73bbd5adfc0b985312448a48.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_2/pg_3_vertical_2.png"
|
||||
dest_files=["res://.godot/imported/pg_3_vertical_2.png-733981bb73bbd5adfc0b985312448a48.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
|
||||
|
Before Width: | Height: | Size: 343 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://nw420tkucw5p"
|
||||
path="res://.godot/imported/pg_3_vertical_cs.png-2d42ea13986f9679ddedd33b2e463769.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_2/pg_3_vertical_cs.png"
|
||||
dest_files=["res://.godot/imported/pg_3_vertical_cs.png-2d42ea13986f9679ddedd33b2e463769.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
|
||||
|
Before Width: | Height: | Size: 7.4 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://culspkef43qfd"
|
||||
path="res://.godot/imported/barretta_regular.png-004551bd2a59af046ec6f59b14c511df.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/barretta_regular.png"
|
||||
dest_files=["res://.godot/imported/barretta_regular.png-004551bd2a59af046ec6f59b14c511df.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
|
||||
|
Before Width: | Height: | Size: 6.4 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://od0hlvkpilqt"
|
||||
path="res://.godot/imported/button_1_texture.png-c83d07b1c1d4bd7bb3af0cf5e59324e0.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/button_1_texture.png"
|
||||
dest_files=["res://.godot/imported/button_1_texture.png-c83d07b1c1d4bd7bb3af0cf5e59324e0.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
|
||||
|
Before Width: | Height: | Size: 6.4 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://bfy6ju4p5uu2t"
|
||||
path="res://.godot/imported/button_2_texture.png-05acc1cdd8e1a7438677073a53d6fc60.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/button_2_texture.png"
|
||||
dest_files=["res://.godot/imported/button_2_texture.png-05acc1cdd8e1a7438677073a53d6fc60.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
|
||||
|
Before Width: | Height: | Size: 5.9 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dxms3ts0qh2t5"
|
||||
path="res://.godot/imported/button_3_texture.png-68d6211a327c46ea2d6803fe08d2ca24.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/button_3_texture.png"
|
||||
dest_files=["res://.godot/imported/button_3_texture.png-68d6211a327c46ea2d6803fe08d2ca24.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
|
||||
|
Before Width: | Height: | Size: 76 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://kuqxyqwqdrq0"
|
||||
path="res://.godot/imported/play_button_2.png-c01ddb1aeca349285eb93a0bb8d21b97.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/play_button_2.png"
|
||||
dest_files=["res://.godot/imported/play_button_2.png-c01ddb1aeca349285eb93a0bb8d21b97.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
|
||||
|
Before Width: | Height: | Size: 75 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://diqsj3x0ftdo"
|
||||
path="res://.godot/imported/quit_button_2.png-a64c0ab5cbea6b10b86c94631528b175.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/quit_button_2.png"
|
||||
dest_files=["res://.godot/imported/quit_button_2.png-a64c0ab5cbea6b10b86c94631528b175.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
|
||||
|
Before Width: | Height: | Size: 162 KiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://c010wpjb66cmb"
|
||||
path="res://.godot/imported/settings_button_2.png-5ff07ad2e8705a51cc1173bc788b44c9.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://core/game_menu/assets/page_3/settings_button_2.png"
|
||||
dest_files=["res://.godot/imported/settings_button_2.png-5ff07ad2e8705a51cc1173bc788b44c9.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
|
||||
@@ -2,23 +2,21 @@
|
||||
|
||||
[ext_resource type="Script" uid="uid://bnh1y560h55vc" path="res://core/game_menu/audio_option.gd" id="1_orafl"]
|
||||
[ext_resource type="Texture2D" uid="uid://dirbxw8ii87nv" path="res://core/game_menu/assets/page_3/main_volume_button.png" id="2_vudub"]
|
||||
[ext_resource type="Texture2D" uid="uid://dxms3ts0qh2t5" path="res://core/game_menu/assets/page_3/button_3_texture.png" id="3_f3y2u"]
|
||||
[ext_resource type="Texture2D" uid="uid://bfy6ju4p5uu2t" path="res://core/game_menu/assets/page_3/button_2_texture.png" id="4_tj25j"]
|
||||
[ext_resource type="Texture2D" uid="uid://od0hlvkpilqt" path="res://core/game_menu/assets/page_3/button_1_texture.png" id="5_4fmty"]
|
||||
[ext_resource type="Texture2D" uid="uid://culspkef43qfd" path="res://core/game_menu/assets/page_3/barretta_regular.png" id="6_aax0b"]
|
||||
[ext_resource type="Texture2D" uid="uid://s33pbfshxhb5" path="res://core/game_menu/assets/page_3/button_-1.png" id="3_vf41c"]
|
||||
[ext_resource type="Texture2D" uid="uid://c6kgm3fq8521h" path="res://core/game_menu/assets/page_3/barretta.png" id="4_hduhm"]
|
||||
|
||||
[sub_resource type="StyleBoxTexture" id="StyleBoxTexture_f3y2u"]
|
||||
content_margin_left = 0.0
|
||||
content_margin_right = 0.0
|
||||
content_margin_bottom = 0.0
|
||||
texture = ExtResource("6_aax0b")
|
||||
texture = ExtResource("4_hduhm")
|
||||
texture_margin_top = 23.0
|
||||
|
||||
[sub_resource type="StyleBoxTexture" id="StyleBoxTexture_tj25j"]
|
||||
texture = ExtResource("6_aax0b")
|
||||
texture = ExtResource("4_hduhm")
|
||||
|
||||
[sub_resource type="StyleBoxTexture" id="StyleBoxTexture_4fmty"]
|
||||
texture = ExtResource("6_aax0b")
|
||||
texture = ExtResource("4_hduhm")
|
||||
|
||||
[node name="AudioOption" type="VBoxContainer" unique_id=1509773712]
|
||||
custom_minimum_size = Vector2(280, 117)
|
||||
@@ -42,9 +40,9 @@ stretch_mode = 5
|
||||
[node name="HSlider" type="HSlider" parent="." unique_id=1286896253]
|
||||
process_mode = 3
|
||||
layout_mode = 2
|
||||
theme_override_icons/grabber = ExtResource("3_f3y2u")
|
||||
theme_override_icons/grabber_highlight = ExtResource("4_tj25j")
|
||||
theme_override_icons/grabber_disabled = ExtResource("5_4fmty")
|
||||
theme_override_icons/grabber = ExtResource("3_vf41c")
|
||||
theme_override_icons/grabber_highlight = ExtResource("3_vf41c")
|
||||
theme_override_icons/grabber_disabled = ExtResource("3_vf41c")
|
||||
theme_override_styles/slider = SubResource("StyleBoxTexture_f3y2u")
|
||||
theme_override_styles/grabber_area = SubResource("StyleBoxTexture_tj25j")
|
||||
theme_override_styles/grabber_area_highlight = SubResource("StyleBoxTexture_4fmty")
|
||||
|
||||
@@ -16,32 +16,11 @@ func _ready():
|
||||
$%TextureRect.show()
|
||||
else:
|
||||
$%TextureRect.hide()
|
||||
TweenFX.breathe(self, 1)
|
||||
|
||||
|
||||
func _on_pressed() -> void:
|
||||
if locked:
|
||||
return
|
||||
TweenFX.stop_all(self)
|
||||
scale = Vector2.ONE
|
||||
rotation = 0.0
|
||||
modulate.a = 1.0
|
||||
TweenFX.press_rotate(self)
|
||||
|
||||
|
||||
func _on_mouse_entered() -> void:
|
||||
if locked:
|
||||
return
|
||||
TweenFX.stop_all(self)
|
||||
scale = Vector2.ONE
|
||||
rotation = 0.0
|
||||
modulate.a = 1.0
|
||||
TweenFX.breathe(self, 1)
|
||||
|
||||
|
||||
func _on_mouse_exited() -> void:
|
||||
if locked:
|
||||
return
|
||||
TweenFX.stop_all(self)
|
||||
scale = Vector2.ONE
|
||||
rotation = 0.0
|
||||
modulate.a = 1.0
|
||||
|
||||
@@ -80,6 +80,4 @@ mouse_filter = 2
|
||||
texture = ExtResource("3_jqji0")
|
||||
expand_mode = 1
|
||||
|
||||
[connection signal="mouse_entered" from="." to="." method="_on_mouse_entered"]
|
||||
[connection signal="mouse_exited" from="." to="." method="_on_mouse_exited"]
|
||||
[connection signal="pressed" from="." to="." method="_on_pressed"]
|
||||
|
||||
@@ -6,28 +6,19 @@ func _ready() -> void:
|
||||
GameState.on_game_resumed.connect(_on_game_resumed)
|
||||
|
||||
func show_page() -> void:
|
||||
var tweens: Array[ContainerTween] = []
|
||||
for child in find_children("*", "", true, false):
|
||||
if child is ContainerTween:
|
||||
tweens.append(child)
|
||||
var tweens = find_children("*", "ContainerTween", true, false)
|
||||
for tween in tweens:
|
||||
tween.start_tween()
|
||||
show()
|
||||
|
||||
|
||||
func hide_page() -> void:
|
||||
var tweens: Array[ContainerTween] = []
|
||||
for child in find_children("*", "", true, false):
|
||||
if child is ContainerTween:
|
||||
tweens.append(child)
|
||||
var tweens = find_children("*", "ContainerTween", true, false)
|
||||
for tween in tweens:
|
||||
tween.stop_tween()
|
||||
hide()
|
||||
|
||||
func _on_game_resumed() -> void:
|
||||
var tweens: Array[ContainerTween] = []
|
||||
for child in find_children("*", "", true, false):
|
||||
if child is ContainerTween:
|
||||
tweens.append(child)
|
||||
var tweens = find_children("*", "ContainerTween", true, false)
|
||||
for tween in tweens:
|
||||
tween.stop_tween()
|
||||
|
||||
@@ -33,10 +33,7 @@ flip_h = true
|
||||
layout_mode = 1
|
||||
anchors_preset = 9
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 2.0
|
||||
offset_top = 13.0
|
||||
offset_right = 762.0
|
||||
offset_bottom = 13.0
|
||||
offset_right = 760.0
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
texture = ExtResource("3_sfb5f")
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
extends "res://core/game_menu/page_interactive.gd"
|
||||
|
||||
@onready var coming_soon_texture = $%ComingSoonTexture
|
||||
|
||||
func on_page_opened() -> void:
|
||||
var anim = coming_soon_texture.texture
|
||||
anim.current_frame = 0
|
||||
anim.pause = false
|
||||
|
||||
func on_page_closed() -> void:
|
||||
var anim = coming_soon_texture.texture as AnimatedTexture
|
||||
anim.pause = true
|
||||
anim.current_frame = 0
|
||||
@@ -1 +0,0 @@
|
||||
uid://pkvsjrnsteuk
|
||||
@@ -1,10 +1,9 @@
|
||||
[gd_scene format=3 uid="uid://clno1ahv2byng"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://pkvsjrnsteuk" path="res://core/game_menu/page_2_right.gd" id="1_71v1w"]
|
||||
[ext_resource type="Script" uid="uid://0yyr318wl7co" path="res://core/game_menu/page_interactive.gd" id="1_script"]
|
||||
[ext_resource type="Texture2D" uid="uid://xfl3ks4dbfaw" path="res://core/game_menu/assets/page_2/achievements_text.png" id="3_4uwhd"]
|
||||
[ext_resource type="Texture2D" uid="uid://drwe2xcnp8vs1" path="res://core/game_menu/assets/page_2/2_dx.png" id="3_msl27"]
|
||||
[ext_resource type="PackedScene" uid="uid://bvw086glfpcba" path="res://core/game_menu/collectible_gallery.tscn" id="5_w0bcg"]
|
||||
[ext_resource type="Texture2D" uid="uid://nw420tkucw5p" path="res://core/game_menu/assets/page_2/pg_3_vertical_cs.png" id="7_71v1w"]
|
||||
[ext_resource type="Texture2D" uid="uid://bx6gsh5uchkge" path="res://core/game_menu/assets/lock.png" id="8_48jk0"]
|
||||
[ext_resource type="Texture2D" uid="uid://vg5y4qgc26ko" path="res://core/game_menu/assets/page_3/coming_soon_01.png" id="8_71v1w"]
|
||||
[ext_resource type="Texture2D" uid="uid://bmatlcouch6jm" path="res://core/game_menu/assets/page_3/coming_soon_02.png" id="9_g7kul"]
|
||||
@@ -15,7 +14,6 @@
|
||||
|
||||
[sub_resource type="AnimatedTexture" id="AnimatedTexture_0x02d"]
|
||||
frames = 5
|
||||
one_shot = true
|
||||
frame_0/texture = ExtResource("8_71v1w")
|
||||
frame_0/duration = 0.15
|
||||
frame_1/texture = ExtResource("9_g7kul")
|
||||
@@ -37,7 +35,7 @@ offset_bottom = -506.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
script = ExtResource("1_71v1w")
|
||||
script = ExtResource("1_script")
|
||||
|
||||
[node name="PageBackground" type="TextureRect" parent="." unique_id=1387851649]
|
||||
layout_mode = 1
|
||||
@@ -58,10 +56,7 @@ anchors_preset = 11
|
||||
anchor_left = 1.0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = -149.695
|
||||
offset_top = 22.855
|
||||
offset_right = 610.3054
|
||||
offset_bottom = 22.85498
|
||||
offset_left = -760.0
|
||||
grow_horizontal = 0
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
@@ -70,9 +65,9 @@ stretch_mode = 2
|
||||
|
||||
[node name="AchievementsText" type="TextureRect" parent="." unique_id=766898810]
|
||||
layout_mode = 0
|
||||
offset_left = 184.0
|
||||
offset_left = 261.0
|
||||
offset_top = 34.5
|
||||
offset_right = 579.0
|
||||
offset_right = 656.0
|
||||
offset_bottom = 105.5
|
||||
mouse_filter = 2
|
||||
texture = ExtResource("3_4uwhd")
|
||||
@@ -87,7 +82,6 @@ offset_right = 767.0
|
||||
offset_bottom = 539.5
|
||||
|
||||
[node name="LockTexture" type="TextureRect" parent="." unique_id=535700029]
|
||||
visible = false
|
||||
layout_mode = 0
|
||||
offset_left = 342.0
|
||||
offset_top = 153.5
|
||||
@@ -98,25 +92,12 @@ texture = ExtResource("8_48jk0")
|
||||
expand_mode = 1
|
||||
stretch_mode = 5
|
||||
|
||||
[node name="LockTexture2" type="TextureRect" parent="." unique_id=997767159]
|
||||
[node name="TextureRect" type="TextureRect" parent="." unique_id=1942592146]
|
||||
layout_mode = 0
|
||||
offset_left = 129.0
|
||||
offset_top = 122.0
|
||||
offset_right = 643.0
|
||||
offset_bottom = 482.7
|
||||
mouse_filter = 2
|
||||
texture = ExtResource("7_71v1w")
|
||||
expand_mode = 1
|
||||
stretch_mode = 5
|
||||
|
||||
[node name="ComingSoonTexture" type="TextureRect" parent="." unique_id=1942592146]
|
||||
unique_name_in_owner = true
|
||||
layout_mode = 0
|
||||
offset_left = 387.99997
|
||||
offset_top = 224.00002
|
||||
offset_right = 708.0
|
||||
offset_bottom = 567.0
|
||||
rotation = -0.05235988
|
||||
offset_left = 596.0
|
||||
offset_top = 86.0
|
||||
offset_right = 743.0
|
||||
offset_bottom = 233.0
|
||||
texture = SubResource("AnimatedTexture_0x02d")
|
||||
expand_mode = 1
|
||||
stretch_mode = 5
|
||||
|
||||
@@ -32,21 +32,17 @@ flip_h = true
|
||||
layout_mode = 1
|
||||
anchors_preset = 9
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 5.3050003
|
||||
offset_top = 78.795
|
||||
offset_right = 765.305
|
||||
offset_bottom = 78.79498
|
||||
offset_right = 760.0
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
texture = ExtResource("3_jdqrf")
|
||||
stretch_mode = 2
|
||||
|
||||
[node name="SettingsMenu" parent="." unique_id=1402645746 instance=ExtResource("2_settings")]
|
||||
layout_mode = 1
|
||||
anchor_left = 0.034210525
|
||||
anchor_top = 0.034843206
|
||||
anchor_right = 0.034210525
|
||||
anchor_bottom = 0.034843206
|
||||
layout_mode = 0
|
||||
anchors_preset = 0
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
offset_left = 68.0
|
||||
offset_top = 24.5
|
||||
offset_right = 692.0
|
||||
|
||||
@@ -36,10 +36,7 @@ anchors_preset = 11
|
||||
anchor_left = 1.0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = -235.0
|
||||
offset_top = 398.0
|
||||
offset_right = 525.0
|
||||
offset_bottom = 398.0
|
||||
offset_left = -760.0
|
||||
grow_horizontal = 0
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
@@ -53,10 +50,10 @@ anchor_left = 0.5
|
||||
anchor_top = 0.5
|
||||
anchor_right = 0.5
|
||||
anchor_bottom = 0.5
|
||||
offset_left = -193.5
|
||||
offset_top = -217.0
|
||||
offset_right = 236.5
|
||||
offset_bottom = 207.0
|
||||
offset_left = -181.5
|
||||
offset_top = -212.0
|
||||
offset_right = 248.5
|
||||
offset_bottom = 212.0
|
||||
|
||||
[node name="PlayButton" parent="OptionMenu/VBoxContainer" parent_id_path=PackedInt32Array(537721615, 508055524) index="0" unique_id=1990327704]
|
||||
visible = false
|
||||
|
||||
@@ -6,23 +6,9 @@ func _ready() -> void:
|
||||
manage_pageflip.connect(_on_manage_pageflip)
|
||||
|
||||
func _on_manage_pageflip(give_control: bool) -> void:
|
||||
var tweens: Array[ContainerTween] = []
|
||||
for child in find_children("*", "", true, false):
|
||||
if child is ContainerTween:
|
||||
tweens.append(child)
|
||||
var tweens = find_children("*", "ContainerTween", true, false)
|
||||
for tween in tweens:
|
||||
if give_control:
|
||||
tween.stop_tween()
|
||||
else:
|
||||
tween.start_tween()
|
||||
|
||||
if give_control:
|
||||
on_page_closed()
|
||||
else:
|
||||
on_page_opened()
|
||||
|
||||
func on_page_opened() -> void:
|
||||
pass
|
||||
|
||||
func on_page_closed() -> void:
|
||||
pass
|
||||
else:
|
||||
tween.stop_tween()
|
||||
|
||||
@@ -40,7 +40,6 @@ func _on_color_selected(selected_color_picker: TrainColorPicker, material_index:
|
||||
for i in range(color_pickers.size()):
|
||||
if color_pickers[i] == selected_color_picker:
|
||||
_set_selected_color(i, material_index)
|
||||
AchievementManager.unlock("ACH_CHANGE_TRAIN_COLOR")
|
||||
break
|
||||
|
||||
func _apply_train_color(color: Color, material_index: int, color_index: int = 0) -> void:
|
||||
|
||||
@@ -158,8 +158,4 @@ color = Color(0.9098039, 0.6, 0.5529412, 1)
|
||||
|
||||
[node name="ContainerTween" parent="." unique_id=160227524 node_paths=PackedStringArray("targets") instance=ExtResource("10_i2rs1")]
|
||||
unique_name_in_owner = true
|
||||
targets = [NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker1"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker2"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker3"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker4"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker5"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker6")]
|
||||
|
||||
[node name="ContainerTween2" parent="." unique_id=97219846 node_paths=PackedStringArray("targets") instance=ExtResource("10_i2rs1")]
|
||||
unique_name_in_owner = true
|
||||
targets = [NodePath("../TextureRect2/MarginContainer/HBoxContainer2/ColorPicker7"), NodePath("../TextureRect2/MarginContainer/HBoxContainer2/ColorPicker8"), NodePath("../TextureRect2/MarginContainer/HBoxContainer2/ColorPicker9"), NodePath("../TextureRect2/MarginContainer/HBoxContainer2/ColorPicker10"), NodePath("../TextureRect2/MarginContainer/HBoxContainer2/ColorPicker11"), NodePath("../TextureRect2/MarginContainer/HBoxContainer2/ColorPicker12")]
|
||||
targets = [null, NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker1"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker2"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker3"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker4"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker5"), NodePath("../TextureRect/MarginContainer/HBoxContainer/ColorPicker6"), null]
|
||||
|
||||
@@ -41,7 +41,17 @@ func apply_video_settings() -> void:
|
||||
var msaa_mode = Viewport.MSAA_2X if save_data.anti_aliasing else Viewport.MSAA_DISABLED
|
||||
get_viewport().msaa_3d = msaa_mode
|
||||
get_viewport().msaa_2d = Viewport.MSAA_DISABLED
|
||||
|
||||
|
||||
func apply_train_colors() -> void:
|
||||
if not save_data.train_color_1.is_empty():
|
||||
var mat1: ShaderMaterial = load("res://tgcc/train/Color1_train.tres")
|
||||
if mat1:
|
||||
mat1.set_shader_parameter("albedo_color", Color(save_data.train_color_1))
|
||||
if not save_data.train_color_2.is_empty():
|
||||
var mat2: ShaderMaterial = load("res://tgcc/train/Color2_train.tres")
|
||||
if mat2:
|
||||
mat2.set_shader_parameter("albedo_color", Color(save_data.train_color_2))
|
||||
|
||||
match save_data.window_mode_index:
|
||||
0:
|
||||
DisplayServer.window_set_mode(DisplayServer.WINDOW_MODE_EXCLUSIVE_FULLSCREEN)
|
||||
@@ -68,16 +78,6 @@ func apply_video_settings() -> void:
|
||||
)
|
||||
DisplayServer.window_set_position(screen_center - window_half_size)
|
||||
|
||||
func apply_train_colors() -> void:
|
||||
if not save_data.train_color_1.is_empty():
|
||||
var mat1: ShaderMaterial = load("res://tgcc/train/Color1_train.tres")
|
||||
if mat1:
|
||||
mat1.set_shader_parameter("albedo_color", Color(save_data.train_color_1))
|
||||
if not save_data.train_color_2.is_empty():
|
||||
var mat2: ShaderMaterial = load("res://tgcc/train/Color2_train.tres")
|
||||
if mat2:
|
||||
mat2.set_shader_parameter("albedo_color", Color(save_data.train_color_2))
|
||||
|
||||
#encrypted file + binary serialization (standard)
|
||||
func load_game() -> void:
|
||||
if not FileAccess.file_exists(SAVE_PATH):
|
||||
|
||||
@@ -12,10 +12,10 @@ func _ready() -> void:
|
||||
mat.transparency = BaseMaterial3D.TRANSPARENCY_ALPHA
|
||||
|
||||
#fix color
|
||||
#sub_viewport.use_hdr_2d = false
|
||||
#mat.albedo_texture_force_srgb = true
|
||||
#mat.shading_mode = BaseMaterial3D.SHADING_MODE_UNSHADED
|
||||
#mat.albedo_color = Color(0.85, 0.85, 0.85, 1.0)
|
||||
sub_viewport.use_hdr_2d = false
|
||||
mat.albedo_texture_force_srgb = true
|
||||
mat.shading_mode = BaseMaterial3D.SHADING_MODE_UNSHADED
|
||||
mat.albedo_color = Color(0.85, 0.85, 0.85, 1.0)
|
||||
|
||||
quad_cartello.material_override = mat
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
[gd_scene format=3 uid="uid://dg4f3v0ukpmay"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://c4kekqicrv4m8" path="res://core/main_scene_ui/audio_player.gd" id="1_i2mrl"]
|
||||
[ext_resource type="Theme" uid="uid://bg8megpn77mod" path="res://core/font/main_theme.tres" id="2_0koyu"]
|
||||
[ext_resource type="Texture2D" uid="uid://dlp62v48tori0" path="res://core/main_scene_ui/assets/audio_player_background.png" id="3_e87kc"]
|
||||
[ext_resource type="Texture2D" uid="uid://s8pp2i6bjkps" path="res://core/main_scene_ui/assets/audio_player_wheel.png" id="4_n5r1o"]
|
||||
[ext_resource type="Theme" uid="uid://dib2yjsuiyhl" path="res://core/font/audio_player_theme.tres" id="5_e87kc"]
|
||||
[ext_resource type="Texture2D" uid="uid://bgrmy57xhg2gj" path="res://core/main_scene_ui/assets/audio_player_empty.png" id="10_xv7rp"]
|
||||
|
||||
[node name="AudioPlayer" type="Control" unique_id=425192018]
|
||||
@@ -104,7 +104,7 @@ anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
theme = ExtResource("5_e87kc")
|
||||
theme = ExtResource("2_0koyu")
|
||||
theme_override_font_sizes/font_size = 12
|
||||
text = "Uknown Track"
|
||||
horizontal_alignment = 1
|
||||
|
||||
@@ -10,7 +10,7 @@ extends Control
|
||||
@onready var collectible_icon_button: Button = $%CollectibleIconButton
|
||||
@onready var weather_row: HBoxContainer = $%WeatherRow
|
||||
@onready var time_of_day_row: HBoxContainer = $%TimeOfDayRow
|
||||
#@onready var cameras_row: HBoxContainer = $%CamerasRow
|
||||
@onready var cameras_row: HBoxContainer = $%CamerasRow
|
||||
@onready var photo_mode_texture_panel: Panel = $%PhotoModeTexturePanel
|
||||
@onready var photo_mode_texture_mask: TextureRect = $%PhotoModeTextureMask
|
||||
@onready var photo_mode_black_screen: ColorRect = $%PhotoModeBlackScreen
|
||||
@@ -28,10 +28,8 @@ var _ui_hidden = false
|
||||
var _photo_mode_mat_tween: Tween
|
||||
var _photo_mode_alpha_tween: Tween
|
||||
var _photo_mode_fold_tween: Tween
|
||||
var _game_menu_base_scale: Vector2
|
||||
|
||||
func _ready() -> void:
|
||||
_game_menu_base_scale = game_menu.scale
|
||||
set_process_input(false)
|
||||
GameState.on_enable_photo_mode_request.connect(_on_enable_photo_mode)
|
||||
GameState.on_disable_photo_mode_request.connect(_on_disable_photo_mode)
|
||||
@@ -88,34 +86,13 @@ func _on_photo_icon_button_pressed() -> void:
|
||||
GameState.on_enable_photo_mode_request.emit()
|
||||
|
||||
func _open_game_menu_on_page(tab_index: int) -> void:
|
||||
if TweenFX.is_playing(game_menu, TweenFX.Animations.FOLD_IN) or TweenFX.is_playing(game_menu, TweenFX.Animations.FOLD_OUT):
|
||||
return
|
||||
GameState.pause_game()
|
||||
game_menu.on_tab_pressed(tab_index, true)
|
||||
game_menu_panel.show()
|
||||
game_menu.scale = _game_menu_base_scale
|
||||
game_menu.scale = Vector2(1, 1)
|
||||
TweenFX.fold_in(game_menu)
|
||||
|
||||
var book = BookAPI.get_current_book()
|
||||
if is_instance_valid(book):
|
||||
for slot in [book.get("_slot_1"), book.get("_slot_2")]:
|
||||
if slot != null and slot.get_child_count() > 0:
|
||||
var node = slot.get_child(-1)
|
||||
if node.has_method("_on_manage_pageflip"):
|
||||
node._on_manage_pageflip(false)
|
||||
|
||||
func _on_resume_button_pressed() -> void:
|
||||
if TweenFX.is_playing(game_menu, TweenFX.Animations.FOLD_IN) or TweenFX.is_playing(game_menu, TweenFX.Animations.FOLD_OUT):
|
||||
return
|
||||
|
||||
var book = BookAPI.get_current_book()
|
||||
if is_instance_valid(book):
|
||||
for slot in [book.get("_slot_1"), book.get("_slot_2")]:
|
||||
if slot != null and slot.get_child_count() > 0:
|
||||
var node = slot.get_child(-1)
|
||||
if node.has_method("_on_manage_pageflip"):
|
||||
node._on_manage_pageflip(true)
|
||||
|
||||
var tween = TweenFX.fold_out(game_menu)
|
||||
await tween.finished
|
||||
game_menu_panel.hide()
|
||||
@@ -136,7 +113,6 @@ func _on_time_of_day_row_on_option_changed(data: String) -> void:
|
||||
pass
|
||||
|
||||
func _on_weather_row_on_option_changed(data: String) -> void:
|
||||
var weather_changed: bool = true
|
||||
match data:
|
||||
"Snow":
|
||||
_snow = !_snow
|
||||
@@ -153,10 +129,9 @@ func _on_weather_row_on_option_changed(data: String) -> void:
|
||||
"Random":
|
||||
pick_random_weather()
|
||||
_:
|
||||
weather_changed = false
|
||||
pass
|
||||
|
||||
if weather_changed:
|
||||
AchievementManager.unlock("ACH_CHANGE_METEO")
|
||||
AchievementManager.is_unlocked("ACH_CHANGE_METEO")
|
||||
|
||||
func pick_random_weather() -> void:
|
||||
var valid_buttons = []
|
||||
@@ -239,6 +214,7 @@ func _on_photo_taken_finished() -> void:
|
||||
|
||||
func _on_choo_choo_button_pressed() -> void:
|
||||
UIEvents.toot_toot.emit(true)
|
||||
AchievementManager.is_unlocked("ACH_CHANGE_TRAIN_COLOR")
|
||||
|
||||
func _set_buttons_mouse_filter(ignore: bool) -> void:
|
||||
var filter = Control.MOUSE_FILTER_IGNORE if ignore else Control.MOUSE_FILTER_STOP
|
||||
@@ -247,34 +223,26 @@ func _set_buttons_mouse_filter(ignore: bool) -> void:
|
||||
buttons.append_array(weather_row.options_icon_buttons)
|
||||
if time_of_day_row and "options_icon_buttons" in time_of_day_row:
|
||||
buttons.append_array(time_of_day_row.options_icon_buttons)
|
||||
#if cameras_row and "options_icon_buttons" in cameras_row:
|
||||
#buttons.append_array(cameras_row.options_icon_buttons)
|
||||
if cameras_row and "options_icon_buttons" in cameras_row:
|
||||
buttons.append_array(cameras_row.options_icon_buttons)
|
||||
|
||||
for btn in buttons:
|
||||
if btn is Control:
|
||||
btn.mouse_filter = filter
|
||||
if ignore:
|
||||
if btn.tooltip_text != "":
|
||||
btn.set_meta("old_tooltip", btn.tooltip_text)
|
||||
btn.tooltip_text = ""
|
||||
else:
|
||||
if btn.has_meta("old_tooltip"):
|
||||
btn.tooltip_text = btn.get_meta("old_tooltip")
|
||||
|
||||
func hide_ui() -> void:
|
||||
_ui_hidden = true
|
||||
_set_buttons_mouse_filter(true)
|
||||
var hud_elements = [hide_ui_button, weather_row, time_of_day_row, customize_train_button, collectible_icon_button, menu_icon_button, photo_icon_button, audio_player, choo_choo_button, time_label, dist_label]
|
||||
var hud_elements = [hide_ui_button, weather_row, time_of_day_row, cameras_row, customize_train_button, collectible_icon_button, menu_icon_button, photo_icon_button, audio_player, choo_choo_button, time_label, dist_label]
|
||||
for element in hud_elements:
|
||||
element.visible = false
|
||||
element.visible = true
|
||||
TweenFX.fade_out(element, 0.25)
|
||||
|
||||
func show_ui() -> void:
|
||||
UIEvents.on_show_ui_requested.emit()
|
||||
_ui_hidden = false
|
||||
_set_buttons_mouse_filter(false)
|
||||
var hud_elements = [hide_ui_button, weather_row, time_of_day_row, customize_train_button, collectible_icon_button, menu_icon_button, photo_icon_button, audio_player, choo_choo_button, time_label, dist_label, tooltips]
|
||||
var hud_elements = [hide_ui_button, weather_row, time_of_day_row, cameras_row, customize_train_button, collectible_icon_button, menu_icon_button, photo_icon_button, audio_player, choo_choo_button, time_label, dist_label, tooltips]
|
||||
for element in hud_elements:
|
||||
element.show()
|
||||
TweenFX.fade_in(element, 0.25)
|
||||
|
||||
@@ -2,7 +2,6 @@ extends Node
|
||||
|
||||
signal on_collectible_unlocked(collectible_id: StringName)
|
||||
signal on_photo_saved(filePath: String)
|
||||
@warning_ignore("unused_signal")
|
||||
signal on_photo_preview_ready(image: Image)
|
||||
|
||||
@export var collectibles_library: CollectibleLibrary
|
||||
|
||||
@@ -31,15 +31,11 @@ var initial_local_basis: Basis
|
||||
var is_making_photo = false
|
||||
var captured_image: Image
|
||||
|
||||
var _ui_is_visible = true
|
||||
|
||||
func _ready() -> void:
|
||||
GameState.on_enable_photo_mode_request.connect(enable_photo_mode)
|
||||
GameState.on_disable_photo_mode_request.connect(disable_photo_mode)
|
||||
GameState.on_photo_taken_making.connect(take_photo_async)
|
||||
GameState.on_photo_mode_black_screen_disappeared.connect(_on_photo_mode_black_screen_disappeared)
|
||||
UIEvents.on_show_ui_requested.connect(update_ui_visibility.bind(true))
|
||||
UIEvents.on_hide_ui_requested.connect(update_ui_visibility.bind(false))
|
||||
|
||||
initial_local_pos = position
|
||||
initial_local_basis = basis
|
||||
@@ -135,8 +131,6 @@ func _input(event: InputEvent) -> void:
|
||||
if event.is_action_pressed("toggle_photo_mode"):
|
||||
if get_tree().paused:
|
||||
return
|
||||
if !_ui_is_visible:
|
||||
return
|
||||
if not is_active:
|
||||
GameState.on_enable_photo_mode_request.emit()
|
||||
else:
|
||||
@@ -198,6 +192,3 @@ func take_photo_async() -> void:
|
||||
|
||||
func _on_photo_mode_black_screen_disappeared() -> void:
|
||||
is_making_photo = false
|
||||
|
||||
func update_ui_visibility(ui_is_visible) -> void:
|
||||
_ui_is_visible = ui_is_visible
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_resource type="Resource" script_class="SceneConfig" format=3 uid="uid://dr612tmciq8pg"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://cgkqj51u6p8dn" path="res://tgcc/main menu/main_menu_test.tscn" id="1_ayiwx"]
|
||||
[ext_resource type="PackedScene" uid="uid://btcpge7cj2041" path="res://core/main_menu/main_menu.tscn" id="1_72aup"]
|
||||
[ext_resource type="Script" uid="uid://bbgyhmb8a17i7" path="res://core/scene_manager/scene_config.gd" id="1_km45g"]
|
||||
[ext_resource type="PackedScene" uid="uid://vjf4bdxd8saj" path="res://tgcc/main_scene.tscn" id="2_prsyo"]
|
||||
[ext_resource type="PackedScene" uid="uid://ri5kxx4mipo" path="res://core/splash_screen/splash_screen.tscn" id="3_aasbo"]
|
||||
@@ -8,7 +8,7 @@
|
||||
[resource]
|
||||
script = ExtResource("1_km45g")
|
||||
scenes = Dictionary[int, PackedScene]({
|
||||
0: ExtResource("1_ayiwx"),
|
||||
0: ExtResource("1_72aup"),
|
||||
1: ExtResource("2_prsyo"),
|
||||
2: ExtResource("3_aasbo")
|
||||
})
|
||||
|
||||
@@ -148,8 +148,8 @@ func change_scene_with_standard_fade(scene_enum: SceneConfig.SceneName, show_loa
|
||||
|
||||
color_rect.mouse_filter = Control.MOUSE_FILTER_STOP
|
||||
|
||||
await cover(fade_in_duration)
|
||||
get_tree().change_scene_to_packed(target_scene)
|
||||
await cover(3.0)
|
||||
|
||||
if show_loading_label:
|
||||
_setup_logo_safety()
|
||||
|
||||
@@ -26,4 +26,4 @@ func _ready() -> void:
|
||||
# Aspetta lo schermo nero prima di caricare il menu principale
|
||||
await get_tree().create_timer(black_screen_delay).timeout
|
||||
|
||||
SceneManager.change_scene_with_standard_fade(SceneConfig.SceneName.MAIN_MENU, true)
|
||||
get_tree().change_scene_to_packed(main_menu_scene)
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
[ext_resource type="Script" uid="uid://ckj2pcoxi5j3" path="res://core/splash_screen/splash_screen.gd" id="1_elsnp"]
|
||||
[ext_resource type="Texture2D" uid="uid://dp3qxncy8u184" path="res://core/splash_screen/jmp_logo.png" id="1_jkpgl"]
|
||||
[ext_resource type="PackedScene" uid="uid://cgkqj51u6p8dn" path="res://tgcc/main menu/main_menu_test.tscn" id="2_qmlqp"]
|
||||
[ext_resource type="PackedScene" uid="uid://btcpge7cj2041" path="res://core/main_menu/main_menu.tscn" id="2_qmlqp"]
|
||||
|
||||
[node name="Control" type="Control" unique_id=163470013]
|
||||
layout_mode = 3
|
||||
@@ -13,11 +13,7 @@ grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
script = ExtResource("1_elsnp")
|
||||
main_menu_scene = ExtResource("2_qmlqp")
|
||||
initial_delay = null
|
||||
logo_fade_in_time = null
|
||||
logo_display_time = 1.25
|
||||
logo_fade_out_time = null
|
||||
black_screen_delay = null
|
||||
|
||||
[node name="ColorRect" type="ColorRect" parent="." unique_id=1599828641]
|
||||
layout_mode = 1
|
||||
|
||||
@@ -6,11 +6,6 @@ extends Node
|
||||
const KNOWN := [
|
||||
"ACH_CHANGE_METEO",
|
||||
"ACH_CHANGE_TRAIN_COLOR",
|
||||
"ACH_DISTANCE_100",
|
||||
"ACH_DISTANCE_200",
|
||||
"ACH_10_PHOTOS",
|
||||
"ACH_10_TOOTTOOT",
|
||||
"ACH_DISTANCE_1000"
|
||||
]
|
||||
|
||||
#how it works:
|
||||
|
||||
@@ -13,13 +13,6 @@ const KNOWN := [
|
||||
"stat_photo_number",
|
||||
"stat_toottoot_number",
|
||||
]
|
||||
const TIME_PLAYED_STAT: String = "stat_time_played"
|
||||
const DISTANCE_KM_STAT: String = "stat_distance_km"
|
||||
const STATS_STORE_INTERVAL_SECONDS: int = 60
|
||||
|
||||
var _pending_time_played_seconds: float = 0.0
|
||||
var _pending_distance_km: float = 0.0
|
||||
var _stats_store_timer: float = 0.0
|
||||
|
||||
#how it works:
|
||||
#func _on_match_finished(score: int) -> void:
|
||||
@@ -32,20 +25,10 @@ var _stats_store_timer: float = 0.0
|
||||
|
||||
func _ready() -> void:
|
||||
if not SteamManager.is_on_steam:
|
||||
set_process(false)
|
||||
return
|
||||
|
||||
Steam.user_stats_stored.connect(_on_stats_stored)
|
||||
|
||||
func _process(delta: float) -> void:
|
||||
_pending_time_played_seconds += delta
|
||||
_stats_store_timer += delta
|
||||
if _stats_store_timer >= STATS_STORE_INTERVAL_SECONDS:
|
||||
_flush_periodic_stats(false)
|
||||
|
||||
func _exit_tree() -> void:
|
||||
_flush_periodic_stats(true)
|
||||
|
||||
func get_int(stat: String) -> int:
|
||||
if not SteamManager.is_on_steam:
|
||||
return 0
|
||||
@@ -79,14 +62,6 @@ func add_int(stat: String, amount: int = 1) -> void:
|
||||
return
|
||||
set_int(stat, get_int(stat) + amount)
|
||||
|
||||
func add_distance_km(distance_km: float) -> void:
|
||||
if not SteamManager.is_on_steam:
|
||||
return
|
||||
if distance_km <= 0.0:
|
||||
return
|
||||
|
||||
_pending_distance_km += distance_km
|
||||
|
||||
func update_avg_rate(stat: String, count_this_session: float, session_length: float) -> void:
|
||||
if not SteamManager.is_on_steam:
|
||||
return
|
||||
@@ -99,32 +74,6 @@ func store() -> void:
|
||||
if not Steam.storeStats():
|
||||
push_error("storeStats failed; data saved locally")
|
||||
|
||||
#periodic stats incrementation; store data every 60 secs
|
||||
func _flush_periodic_stats(force_store: bool) -> void:
|
||||
if not SteamManager.is_on_steam:
|
||||
_pending_time_played_seconds = 0.0
|
||||
_pending_distance_km = 0.0
|
||||
_stats_store_timer = 0.0
|
||||
return
|
||||
|
||||
var has_changes: bool = false
|
||||
|
||||
var whole_seconds: int = int(floor(_pending_time_played_seconds))
|
||||
if whole_seconds > 0:
|
||||
_pending_time_played_seconds -= float(whole_seconds)
|
||||
add_int(TIME_PLAYED_STAT, whole_seconds)
|
||||
has_changes = true
|
||||
|
||||
var whole_km: int = int(floor(_pending_distance_km))
|
||||
if whole_km > 0:
|
||||
_pending_distance_km -= float(whole_km)
|
||||
add_int(DISTANCE_KM_STAT, whole_km)
|
||||
has_changes = true
|
||||
|
||||
_stats_store_timer = 0.0
|
||||
if has_changes and (force_store or whole_seconds > 0 or whole_km > 0):
|
||||
store()
|
||||
|
||||
#Development only: reset stats
|
||||
func reset_all(include_achievements: bool = false) -> void:
|
||||
if not SteamManager.is_on_steam:
|
||||
|
||||
@@ -52,8 +52,6 @@ signal toot_toot(update_stats: bool)
|
||||
@warning_ignore("unused_signal")
|
||||
signal resume_game_requested
|
||||
@warning_ignore("unused_signal")
|
||||
signal on_show_ui_requested
|
||||
@warning_ignore("unused_signal")
|
||||
signal on_hide_ui_requested
|
||||
@warning_ignore("unused_signal")
|
||||
signal change_camera_request(camera_index: int)
|
||||
|
||||
@@ -20,8 +20,8 @@ shader_parameter/variance_scale = 0.1
|
||||
shader_parameter/variance_color = Color(0.09803922, 0.18039216, 0.05490196, 1)
|
||||
shader_parameter/variance_intensity = 0.90000004275
|
||||
shader_parameter/snow_color = Color(0.85, 0.9, 0.95, 1)
|
||||
shader_parameter/snow_visibility = 1.6
|
||||
shader_parameter/snow_coverage = 0.65
|
||||
shader_parameter/snow_visibility = 1.0
|
||||
shader_parameter/snow_coverage = 0.35
|
||||
shader_parameter/height_min = 0.0
|
||||
shader_parameter/height_max = 5.0
|
||||
shader_parameter/shadow_intensity = 0.610000028975
|
||||
|
||||
@@ -28,8 +28,8 @@ shader_parameter/variance_scale = 0.06
|
||||
shader_parameter/variance_color = Color(0.3, 0.5, 0.2, 1)
|
||||
shader_parameter/variance_intensity = 0.350000016625
|
||||
shader_parameter/snow_color = Color(0.85, 0.9, 0.95, 1)
|
||||
shader_parameter/snow_visibility = 1.6
|
||||
shader_parameter/snow_coverage = 0.65
|
||||
shader_parameter/snow_visibility = 1.0
|
||||
shader_parameter/snow_coverage = 0.35
|
||||
shader_parameter/height_min = 0.0
|
||||
shader_parameter/height_max = 5.0
|
||||
shader_parameter/shadow_intensity = 0.6000000285
|
||||
|
||||
@@ -119,7 +119,7 @@ shader_parameter/glint_sharpness = 32.0
|
||||
shader_parameter/emission_color = Color(0, 0, 0, 1)
|
||||
shader_parameter/emission_energy = 0.0
|
||||
|
||||
[node name="chunk_railway_station_doubleside" unique_id=1591869611 groups=["railway_station", "weather_node"] instance=ExtResource("1_nkssc")]
|
||||
[node name="chunk_railway_station_doubleside" unique_id=1591869611 groups=["weather_node"] instance=ExtResource("1_nkssc")]
|
||||
script = ExtResource("2_i3rfy")
|
||||
chunk_type = 1
|
||||
est = true
|
||||
|
||||
@@ -78,7 +78,7 @@ shader_parameter/glint_sharpness = 32.0
|
||||
shader_parameter/emission_color = Color(0, 0, 0, 1)
|
||||
shader_parameter/emission_energy = 0.0
|
||||
|
||||
[node name="chunk_railway_station_oneside" unique_id=310632835 node_paths=PackedStringArray("connection_left", "connection_right") groups=["railway_station", "weather_node"] instance=ExtResource("1_38ujo")]
|
||||
[node name="chunk_railway_station_oneside" unique_id=310632835 node_paths=PackedStringArray("connection_left", "connection_right") groups=["weather_node"] instance=ExtResource("1_38ujo")]
|
||||
script = ExtResource("2_a8mxs")
|
||||
chunk_type = 1
|
||||
west = true
|
||||
|
||||
@@ -1,70 +0,0 @@
|
||||
extends Node3D
|
||||
|
||||
@export var play_departure_speed: float = -6.0
|
||||
@export var play_departure_delay_seconds: float = 1.0
|
||||
@export var play_move_before_transition_seconds: float = 3.0
|
||||
@export var menu_train_whistle_volume_db: float = -12.0
|
||||
|
||||
var _play_departure_started: bool = false
|
||||
|
||||
@onready var _rail_path: Node = $rail
|
||||
@onready var _option_menu: Control = $MainMenuUI/SubViewport/OptionMenu
|
||||
|
||||
func _ready() -> void:
|
||||
_stop_menu_train()
|
||||
_configure_menu_train_whistle_volume()
|
||||
_configure_play_transition_delay()
|
||||
_connect_play_button()
|
||||
|
||||
func _configure_menu_train_whistle_volume() -> void:
|
||||
if _rail_path == null or not "train_instance" in _rail_path:
|
||||
return
|
||||
|
||||
var train_instance := _rail_path.get("train_instance") as Node3D
|
||||
if train_instance == null:
|
||||
return
|
||||
|
||||
if "whistle_volume_db" in train_instance:
|
||||
train_instance.set("whistle_volume_db", menu_train_whistle_volume_db)
|
||||
|
||||
var whistle_player := train_instance.get_node_or_null("TrainWhistlePlayer") as AudioStreamPlayer3D
|
||||
if whistle_player != null:
|
||||
whistle_player.volume_db = menu_train_whistle_volume_db
|
||||
|
||||
func _configure_play_transition_delay() -> void:
|
||||
if _option_menu == null or not "fade_time" in _option_menu:
|
||||
return
|
||||
|
||||
_option_menu.set("fade_time", play_departure_delay_seconds + play_move_before_transition_seconds)
|
||||
|
||||
func _stop_menu_train() -> void:
|
||||
if _rail_path == null:
|
||||
return
|
||||
|
||||
_rail_path.set("is_inmotion", false)
|
||||
_rail_path.set("stop_multiply", 1.0)
|
||||
|
||||
func _connect_play_button() -> void:
|
||||
if _option_menu == null or not "play_button" in _option_menu:
|
||||
return
|
||||
|
||||
var play_button := _option_menu.get("play_button") as Button
|
||||
if play_button == null:
|
||||
return
|
||||
if not play_button.pressed.is_connected(_on_play_button_pressed):
|
||||
play_button.pressed.connect(_on_play_button_pressed)
|
||||
|
||||
func _on_play_button_pressed() -> void:
|
||||
if _rail_path == null or _play_departure_started:
|
||||
return
|
||||
|
||||
_play_departure_started = true
|
||||
await get_tree().create_timer(play_departure_delay_seconds).timeout
|
||||
if not is_inside_tree():
|
||||
return
|
||||
|
||||
_rail_path.set("train_speed", play_departure_speed)
|
||||
_rail_path.set("stop_multiply", 1.0)
|
||||
_rail_path.set("is_restarting", false)
|
||||
_rail_path.set("stop_ongoing", false)
|
||||
_rail_path.set("is_inmotion", true)
|
||||
@@ -1 +0,0 @@
|
||||
uid://cna45gowlxaqj
|
||||
@@ -1,7 +1,6 @@
|
||||
[gd_scene format=3 uid="uid://cgkqj51u6p8dn"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://cmuvmmp7xam4o" path="res://core/daynight/environment_management.tscn" id="1_2o8pc"]
|
||||
[ext_resource type="Script" uid="uid://cna45gowlxaqj" path="res://tgcc/main menu/main_menu_test.gd" id="1_4j5xl"]
|
||||
[ext_resource type="Resource" uid="uid://dufa43jysup7" path="res://tgcc/main menu/menu.tres" id="2_vvb5q"]
|
||||
[ext_resource type="PackedScene" uid="uid://bmwmdsdyfxfc1" path="res://tgcc/map/map_1/map_menu.tscn" id="2_wbrya"]
|
||||
[ext_resource type="Shader" uid="uid://cpgtj8mhjklb8" path="res://tgcc/chunk/prop/cloud/cloud3d.gdshader" id="2_wcae3"]
|
||||
@@ -105,9 +104,6 @@
|
||||
[ext_resource type="Shader" uid="uid://bhqtjjs3emv7f" path="res://tgcc/main menu/godraysmenu.gdshader" id="103_g1vc5"]
|
||||
[ext_resource type="PackedScene" uid="uid://cp2vmysawnuql" path="res://tgcc/chunk/prop/sign/scene/signMenu.tscn" id="103_mrhmq"]
|
||||
[ext_resource type="Material" uid="uid://dljvvppsdbjd1" path="res://tgcc/chunk/material/glowplane.tres" id="104_mrhmq"]
|
||||
[ext_resource type="Texture2D" uid="uid://kuqxyqwqdrq0" path="res://core/game_menu/assets/page_3/play_button_2.png" id="106_5hxod"]
|
||||
[ext_resource type="Texture2D" uid="uid://c010wpjb66cmb" path="res://core/game_menu/assets/page_3/settings_button_2.png" id="107_cg70g"]
|
||||
[ext_resource type="Texture2D" uid="uid://diqsj3x0ftdo" path="res://core/game_menu/assets/page_3/quit_button_2.png" id="108_0hcuf"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_00nq7"]
|
||||
render_priority = 0
|
||||
@@ -182,10 +178,10 @@ compositor_effects = Array[CompositorEffect]([SubResource("CompositorEffect_q52t
|
||||
closed = true
|
||||
bake_interval = 50.0
|
||||
_data = {
|
||||
"points": PackedVector3Array(0, 0, 0, 0, 0, 0, 3.5, 0, 0, 0, 0, 0, 0, 0, 0, 3.5, 0, 100, 0, 0, 0, 0, 0, 0, 2.961661, -0.009097099, -56.07381, 0, 0, 0, 0, 0, 0, 3.4848416, -0.013232231, -117.195526, 0, 0, 0, 0, 0, 0, 3.3488476, 0.0048189163, 176.55922, 0, 0, 0, 0, 0, 0, 1.7582202, 0.0118227005, 270.61703),
|
||||
"tilts": PackedFloat32Array(0, 0, 0, 0, 0, 0)
|
||||
"points": PackedVector3Array(0, 0, 0, 0, 0, 0, 3.5, 0, 0, 0, 0, 0, 0, 0, 0, 3.5, 0, 100),
|
||||
"tilts": PackedFloat32Array(0, 0)
|
||||
}
|
||||
point_count = 6
|
||||
point_count = 2
|
||||
|
||||
[sub_resource type="PlaneMesh" id="PlaneMesh_00nq7"]
|
||||
|
||||
@@ -286,12 +282,10 @@ size = Vector2(600, 300)
|
||||
|
||||
[node name="MainMenu" type="Node3D" unique_id=448381304]
|
||||
transform = Transform3D(-1, 0, -8.742278e-08, 0, 1, 0, 8.742278e-08, 0, -1, 0, 0, 0)
|
||||
script = ExtResource("1_4j5xl")
|
||||
|
||||
[node name="EnvironmentManager" parent="." unique_id=1611939731 instance=ExtResource("1_2o8pc")]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 1.822516, 0, 1.9254212)
|
||||
environment_config = ExtResource("2_vvb5q")
|
||||
block_keyboard_input = true
|
||||
cloud_material = SubResource("ShaderMaterial_00nq7")
|
||||
|
||||
[node name="Camera3D" type="Camera3D" parent="." unique_id=759297292]
|
||||
@@ -319,15 +313,9 @@ curve = SubResource("Curve3D_263ax")
|
||||
script = ExtResource("7_5p27e")
|
||||
train_model = ExtResource("8_ljvyb")
|
||||
wagon_pool = ExtResource("9_wcae3")
|
||||
wagon_random_number = false
|
||||
wagon_count = 4
|
||||
wagon_gap = 0.6
|
||||
wagon_count = 5
|
||||
wagon_gap = 0.8
|
||||
wagon_spacing_scale = 0.9
|
||||
train_start_mode = 2
|
||||
train_start_stop_index = 0
|
||||
train_start_position = 540.0
|
||||
train_start_after_delay = false
|
||||
train_facing_direction = 2
|
||||
sleepers_model = ExtResource("10_00nq7")
|
||||
fireworks_scene = ExtResource("11_aylkj")
|
||||
|
||||
@@ -364,10 +352,9 @@ railway_pool = SubResource("Resource_jrt8d")
|
||||
biome_list = Array[ExtResource("15_3blen")]([SubResource("Resource_n3osn")])
|
||||
entity_pool = ExtResource("78_xg6nk")
|
||||
entity_spawn_probability = 0.0
|
||||
max_entities_per_chunk = 0
|
||||
eye_line = 7
|
||||
max_entities_per_chunk = 5
|
||||
eye_line = 8
|
||||
lamppost_max_wire_distance = 0.0
|
||||
lamppost_rail_clearance_distance = 3.0
|
||||
|
||||
[node name="Fuji2" parent="." unique_id=842328745 instance=ExtResource("99_61psf")]
|
||||
transform = Transform3D(0.09337742, 0, 0.9715159, 0, 0.5685182, 0, -0.3828171, 0, 0.23697394, -236.37123, -4.8100815, 216.00096)
|
||||
@@ -498,21 +485,12 @@ offset_top = 6.0
|
||||
offset_bottom = -6.0
|
||||
theme_override_constants/separation = 64
|
||||
|
||||
[node name="PlayButton" parent="MainMenuUI/SubViewport/OptionMenu/VBoxContainer" index="0" unique_id=1990327704]
|
||||
image = ExtResource("106_5hxod")
|
||||
|
||||
[node name="ResumeButton" parent="MainMenuUI/SubViewport/OptionMenu/VBoxContainer" index="1" unique_id=635721927]
|
||||
visible = false
|
||||
|
||||
[node name="SettingsButton" parent="MainMenuUI/SubViewport/OptionMenu/VBoxContainer" index="2" unique_id=1931222561]
|
||||
image = ExtResource("107_cg70g")
|
||||
|
||||
[node name="SaveButton" parent="MainMenuUI/SubViewport/OptionMenu/VBoxContainer" index="3" unique_id=1161034414]
|
||||
visible = false
|
||||
|
||||
[node name="QuitButton" parent="MainMenuUI/SubViewport/OptionMenu/VBoxContainer" index="4" unique_id=1804807896]
|
||||
image = ExtResource("108_0hcuf")
|
||||
|
||||
[connection signal="input_event" from="Sign/QuadSign/Area3D" to="Sign" method="_on_area_3d_input_event"]
|
||||
|
||||
[editable path="Fuji4"]
|
||||
|
||||
@@ -34,9 +34,6 @@ shader_parameter/sun_color = Color(0.2841828, 0.2023238, 0.27953526, 1)
|
||||
|
||||
[resource]
|
||||
script = ExtResource("3_vg0pk")
|
||||
start_time = 0.5
|
||||
start_day_time_paused = true
|
||||
show_day_time_debug = false
|
||||
morning_color = Color(0.93333334, 0.78039217, 0.6039216, 1)
|
||||
afternoon_color = Color(0.9490196, 0.62352943, 0.38039216, 1)
|
||||
night_color = Color(0.18431373, 0.18431373, 0.4862745, 1)
|
||||
|
||||
@@ -190,7 +190,7 @@ data = PackedByteArray("//vQZAAOhpd2PgtGR7JsJPfgYSYSJ6387g9rgIGKF+EZgxxoAM4TYIWm
|
||||
closed = true
|
||||
bake_interval = 60.0
|
||||
_data = {
|
||||
"points": PackedVector3Array(0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 0, 0, 0, 0, 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 120, 0, 0, 0, 0, 0, 0, -4.1409535, 0, 140, 0, 0, 0, 0, 0, 0, -20.385382, 0, 160.4621, 0, 0, 0, 0, 0, 0, -40.62518, 0, 168.52754, 0, 0, 0, 0, 0, 0, -60, 0, 170, 0, 0, 0, 0, 0, 0, -80, 0, 170, 0, 0, 0, 0, 0, 0, -100, 0, 170, 0, 0, 0, 0, 0, 0, -120.42937, 0, 171.50279, 0, 0, 0, 0, 0, 0, -141.41747, 7.6293945e-06, 180.5982, 0, 0, 0, 0, 0, 0, -155.77005, 7.6293945e-06, 198.35184, 0, 0, 0, 0, 0, 0, -160.14105, 7.6293945e-06, 219.80951, 0, 0, 0, 0, 0, 0, -163.99007, 7.6293945e-06, 239.36005, 0, 0, 0, 0, 0, 0, -175.77509, 7.6293945e-06, 256.16028, 0, 0, 0, 0, 0, 0, -195.62283, 7.6293945e-06, 267.46912, 0, 0, 0, 0, 0, 0, -219.9999, 7.6293945e-06, 270.11758, 0, 0, 0, 0, 0, 0, -240, 0, 270.118, 0, 0, 0, 0, 0, 0, -260, 0, 270.118, 0, 0, 0, 0, 0, 0, -275.19666, 7.6293945e-06, 270.55228, 0, 0, 0, 0, 0, 0, -294.2925, 7.6293945e-06, 276.05307, 0, 0, 0, 0, 0, 0, -307.19006, 7.6293945e-06, 286.9095, 0, 0, 0, 0, 0, 0, -317.32443, 7.6293945e-06, 303.14682, 0, 0, 0, 0, 0, 0, -320, 0, 320, 0, 0, 0, 0, 0, 0, -320, 0, 340, 0, 0, 0, 0, 0, 0, -320, 0, 360, 0, 0, 0, 0, 0, 0, -320, 0, 380, 0, 0, 0, 0, 0, 0, -316.78876, 7.6293945e-06, 396.91193, 0, 0, 0, 0, 0, 0, -307.68207, 7.6293945e-06, 412.70596, 0, 0, 0, 0, 0, 0, -291.08273, 7.6293945e-06, 424.7491, 0, 0, 0, 0, 0, 0, -270, 0, 429.994, 0, 0, 0, 0, 0, 0, -250, 0, 429.994, 0, 0, 0, 0, 0, 0, -229.90146, 7.6293945e-06, 433.90823, 0, 0, 0, 0, 0, 0, -217.15442, 7.6293945e-06, 442.98242, 0, 0, 0, 0, 0, 0, -203.97934, 7.6293945e-06, 459.7799, 0, 0, 0, 0, 0, 0, -200, 0, 480, 0, 0, 0, 0, 0, 0, -200, 0, 500, 0, 0, 0, 0, 0, 0, -195.5338, 7.6293945e-06, 520.0368, 0, 0, 0, 0, 0, 0, -184.9173, 7.6293945e-06, 535.07776, 0, 0, 0, 0, 0, 0, -170.36423, 7.6293945e-06, 545.0799, 0, 0, 0, 0, 0, 0, -150.56184, 0, 549.8127, 0, 0, 0, 0, 0, 0, -130, 0, 550, 0, 0, 0, 0, 0, 0, -110, 0, 550, 0, 0, 0, 0, 0, 0, -90, 0, 550, 0, 0, 0, 0, 0, 0, -70, 0, 550, 0, 0, 0, 0, 0, 0, -50, 0, 550, 0, 0, 0, 0, 0, 0, -29.862535, 7.6293945e-06, 545.3371, 0, 0, 0, 0, 0, 0, -12.945752, 7.6293945e-06, 534.1406, 0, 0, 0, 0, 0, 0, -4.098665, 7.6293945e-06, 519.6814, 0, 0, 0, 0, 0, 0, -0.048213482, 7.6293945e-06, 500.107, 0, 0, 0, 0, 0, 0, 3.7920675, 7.6293945e-06, 480.64902, 0, 0, 0, 0, 0, 0, 13.513225, 7.6293945e-06, 465.9133, 0, 0, 0, 0, 0, 0, 29.76715, 7.6293945e-06, 454.41486, 0, 0, 0, 0, 0, 0, 49.711926, 7.6293945e-06, 450.12488, 0, 0, 0, 0, 0, 0, 70, 0, 450, 0, 0, 0, 0, 0, 0, 90, 0, 450, 0, 0, 0, 0, 0, 0, 110.055405, 7.6293945e-06, 445.42627, 0, 0, 0, 0, 0, 0, 127.27293, 7.6293945e-06, 433.46255, 0, 0, 0, 0, 0, 0, 136.95703, 7.6293945e-06, 417.5506, 0, 0, 0, 0, 0, 0, 140, 0, 400, 0, 0, 0, 0, 0, 0, 140, 0, 380, 0, 0, 0, 0, 0, 0, 140, 0, 360, 0, 0, 0, 0, 0, 0, 140, 0, 340, 0, 0, 0, 0, 0, 0, 140, 0, 320, 0, 0, 0, 0, 0, 0, 140, 0, 300, 0, 0, 0, 0, 0, 0, 140, 0, 280, 0, 0, 0, 0, 0, 0, 140, 0, 260, 0, 0, 0, 0, 0, 0, 140, 0, 240, 0, 0, 0, 0, 0, 0, 140, 0, 220, 0, 0, 0, 0, 0, 0, 140, 0, 200, 0, 0, 0, 0, 0, 0, 140, 0, 180, 0, 0, 0, 0, 0, 0, 140, 0, 160, 0, 0, 0, 0, 0, 0, 140, 0, 140, 0, 0, 0, 0, 0, 0, 140, 0, 120, 0, 0, 0, 0, 0, 0, 140, 0, 100, 0, 0, 0, 0, 0, 0, 140, 0, 80, 0, 0, 0, 0, 0, 0, 140, 0, 60, 0, 0, 0, 0, 0, 0, 140, 0, 40, 0, 0, 0, 0, 0, 0, 140.26848, 0, 20, 0, 0, 0, 0, 0, 0, 140, 0, 0, 0, 0, 0, 0, 0, 0, 136.2151, 7.6293945e-06, -18.930761, 0, 0, 0, 0, 0, 0, 124.47424, 7.6293945e-06, -35.771675, 0, 0, 0, 0, 0, 0, 109.556854, 7.6293945e-06, -45.911987, 0, 0, 0, 0, 0, 0, 90, 0, -50, 0, 0, 0, 0, 0, 0, 70, 0, -50, 0, 0, 0, 0, 0, 0, 50, 0, -50, 0, 0, 0, 0, 0, 0, 30.626865, 7.6293945e-06, -46.35706, 0, 0, 0, 0, 0, 0, 14.519331, 7.6293945e-06, -35.468895, 0, 0, 0, 0, 0, 0, 3.5, 0, -17.9, 0, 0, 0, 0, 0, 0, 0.2006703, 0, 0.20440674, 0, 0, 0, 0, 0, 0, 0.06303978, 0, 20.431122),
|
||||
"points": PackedVector3Array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 0, 0, 0, 0, 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 120, 0, 0, 0, 0, 0, 0, -4.372, 0, 140, 0, 0, 0, 0, 0, 0, -20.963, 0, 160, 0, 0, 0, 0, 0, 0, -40.62518, 0, 168.52754, 0, 0, 0, 0, 0, 0, -60, 0, 170, 0, 0, 0, 0, 0, 0, -80, 0, 170, 0, 0, 0, 0, 0, 0, -100, 0, 170, 0, 0, 0, 0, 0, 0, -120.42937, 0, 171.50279, 0, 0, 0, 0, 0, 0, -141.41747, 7.6293945e-06, 180.5982, 0, 0, 0, 0, 0, 0, -155.77005, 7.6293945e-06, 198.35184, 0, 0, 0, 0, 0, 0, -160.14105, 7.6293945e-06, 219.80951, 0, 0, 0, 0, 0, 0, -163.99007, 7.6293945e-06, 239.36005, 0, 0, 0, 0, 0, 0, -175.77509, 7.6293945e-06, 256.16028, 0, 0, 0, 0, 0, 0, -195.62283, 7.6293945e-06, 267.46912, 0, 0, 0, 0, 0, 0, -219.9999, 7.6293945e-06, 270.11758, 0, 0, 0, 0, 0, 0, -240, 0, 270.118, 0, 0, 0, 0, 0, 0, -260, 0, 270.118, 0, 0, 0, 0, 0, 0, -275.19666, 7.6293945e-06, 270.55228, 0, 0, 0, 0, 0, 0, -294.2925, 7.6293945e-06, 276.05307, 0, 0, 0, 0, 0, 0, -307.19006, 7.6293945e-06, 286.9095, 0, 0, 0, 0, 0, 0, -317.32443, 7.6293945e-06, 303.14682, 0, 0, 0, 0, 0, 0, -320, 0, 320, 0, 0, 0, 0, 0, 0, -320, 0, 340, 0, 0, 0, 0, 0, 0, -320, 0, 360, 0, 0, 0, 0, 0, 0, -320, 0, 380, 0, 0, 0, 0, 0, 0, -316.78876, 7.6293945e-06, 396.91193, 0, 0, 0, 0, 0, 0, -307.68207, 7.6293945e-06, 412.70596, 0, 0, 0, 0, 0, 0, -291.08273, 7.6293945e-06, 424.7491, 0, 0, 0, 0, 0, 0, -270, 0, 429.994, 0, 0, 0, 0, 0, 0, -250, 0, 429.994, 0, 0, 0, 0, 0, 0, -229.90146, 7.6293945e-06, 433.90823, 0, 0, 0, 0, 0, 0, -217.15442, 7.6293945e-06, 442.98242, 0, 0, 0, 0, 0, 0, -204.60803, 7.6293945e-06, 459.93704, 0, 0, 0, 0, 0, 0, -200, 0, 480, 0, 0, 0, 0, 0, 0, -200, 0, 500, 0, 0, 0, 0, 0, 0, -195.5338, 7.6293945e-06, 520.0368, 0, 0, 0, 0, 0, 0, -184.9173, 7.6293945e-06, 535.07776, 0, 0, 0, 0, 0, 0, -170.36423, 7.6293945e-06, 545.0799, 0, 0, 0, 0, 0, 0, -150.56184, 0, 549.8127, 0, 0, 0, 0, 0, 0, -130, 0, 550, 0, 0, 0, 0, 0, 0, -110, 0, 550, 0, 0, 0, 0, 0, 0, -90, 0, 550, 0, 0, 0, 0, 0, 0, -70, 0, 550, 0, 0, 0, 0, 0, 0, -50, 0, 550, 0, 0, 0, 0, 0, 0, -29.862535, 7.6293945e-06, 545.3371, 0, 0, 0, 0, 0, 0, -13.215244, 7.6293945e-06, 533.0626, 0, 0, 0, 0, 0, 0, -4.098665, 7.6293945e-06, 519.6814, 0, 0, 0, 0, 0, 0, -0.048213482, 7.6293945e-06, 500.107, 0, 0, 0, 0, 0, 0, 3.7920675, 7.6293945e-06, 480.64902, 0, 0, 0, 0, 0, 0, 13.513225, 7.6293945e-06, 465.9133, 0, 0, 0, 0, 0, 0, 29.76715, 7.6293945e-06, 454.41486, 0, 0, 0, 0, 0, 0, 49.711926, 7.6293945e-06, 450.12488, 0, 0, 0, 0, 0, 0, 70, 0, 450, 0, 0, 0, 0, 0, 0, 90, 0, 450, 0, 0, 0, 0, 0, 0, 110.055405, 7.6293945e-06, 445.42627, 0, 0, 0, 0, 0, 0, 126.975784, 7.6293945e-06, 432.8683, 0, 0, 0, 0, 0, 0, 136.95703, 7.6293945e-06, 417.5506, 0, 0, 0, 0, 0, 0, 140, 0, 400, 0, 0, 0, 0, 0, 0, 140, 0, 380, 0, 0, 0, 0, 0, 0, 140, 0, 360, 0, 0, 0, 0, 0, 0, 140, 0, 340, 0, 0, 0, 0, 0, 0, 140, 0, 320, 0, 0, 0, 0, 0, 0, 140, 0, 300, 0, 0, 0, 0, 0, 0, 140, 0, 280, 0, 0, 0, 0, 0, 0, 140, 0, 260, 0, 0, 0, 0, 0, 0, 140, 0, 240, 0, 0, 0, 0, 0, 0, 140, 0, 220, 0, 0, 0, 0, 0, 0, 140, 0, 200, 0, 0, 0, 0, 0, 0, 140, 0, 180, 0, 0, 0, 0, 0, 0, 140, 0, 160, 0, 0, 0, 0, 0, 0, 140, 0, 140, 0, 0, 0, 0, 0, 0, 140, 0, 120, 0, 0, 0, 0, 0, 0, 140, 0, 100, 0, 0, 0, 0, 0, 0, 140, 0, 80, 0, 0, 0, 0, 0, 0, 140, 0, 60, 0, 0, 0, 0, 0, 0, 140, 0, 40, 0, 0, 0, 0, 0, 0, 140.26848, 0, 20, 0, 0, 0, 0, 0, 0, 140, 0, 0, 0, 0, 0, 0, 0, 0, 136.2151, 7.6293945e-06, -18.930761, 0, 0, 0, 0, 0, 0, 124.47424, 7.6293945e-06, -35.771675, 0, 0, 0, 0, 0, 0, 109.556854, 7.6293945e-06, -45.911987, 0, 0, 0, 0, 0, 0, 90, 0, -50, 0, 0, 0, 0, 0, 0, 70, 0, -50, 0, 0, 0, 0, 0, 0, 50, 0, -50, 0, 0, 0, 0, 0, 0, 30.626865, 7.6293945e-06, -46.35706, 0, 0, 0, 0, 0, 0, 14.519331, 7.6293945e-06, -35.468895, 0, 0, 0, 0, 0, 0, 3.52941, 7.6293945e-06, -19.590664),
|
||||
"tilts": PackedFloat32Array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
|
||||
}
|
||||
point_count = 93
|
||||
@@ -205,7 +205,7 @@ compositor = SubResource("Compositor_mb5yv")
|
||||
rail_path = NodePath("../rail")
|
||||
biome_list = Array[ExtResource("6_jfe74")]([SubResource("Resource_3qrd0")])
|
||||
entity_pool = ExtResource("34_a2cst")
|
||||
entity_spawn_probability = 0.4
|
||||
entity_spawn_probability = 1.0
|
||||
max_entities_per_chunk = 5
|
||||
eye_line = 4
|
||||
|
||||
@@ -253,6 +253,18 @@ cameras = NodePath("../cameras")
|
||||
sleepers_model = ExtResource("46_lbmv2")
|
||||
fireworks_scene = ExtResource("47_q7p65")
|
||||
|
||||
[node name="Marker3D" type="Marker3D" parent="rail" unique_id=1460318018]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -6.7581053, -1.6046681, 59.658325)
|
||||
|
||||
[node name="Marker3D2" type="Marker3D" parent="rail" unique_id=131965864]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 127.14737, 0, 169.44846)
|
||||
|
||||
[node name="Marker3D3" type="Marker3D" parent="rail" unique_id=492991547]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -91.191925, 0, 539.03174)
|
||||
|
||||
[node name="Marker3D4" type="Marker3D" parent="rail" unique_id=1550097358]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -312.19193, 0, 349.03174)
|
||||
|
||||
[node name="Control" type="Control" parent="." unique_id=630650980]
|
||||
visible = false
|
||||
layout_mode = 3
|
||||
|
||||
@@ -64,9 +64,9 @@ grad_intensity_night = 0.5
|
||||
fog_color_morning = Color(0.7490196, 0.8509804, 0.9490196, 1)
|
||||
fog_color_afternoon = Color(0.9823975, 0.8034449, 0.8778439, 1)
|
||||
fog_color_night = Color(0.18375358, 0.16627002, 0.3588226, 1)
|
||||
fog_density_morning = 0.02
|
||||
fog_density_afternoon = 0.02
|
||||
fog_density_night = 0.02
|
||||
fog_density_morning = 0.01
|
||||
fog_density_afternoon = 0.01
|
||||
fog_density_night = 0.03
|
||||
glow_morning = 0.4
|
||||
glow_night = 0.8
|
||||
enable_fog = true
|
||||
@@ -78,8 +78,8 @@ lightning_min = 2
|
||||
lightning_max = 4
|
||||
lightning_scale_min = 2.0
|
||||
lightning_scale_max = 5.0
|
||||
godray_max_rain = 15
|
||||
godray_spawn_radius = 200.0
|
||||
godray_max_rain = 30
|
||||
godray_spawn_radius = 100.0
|
||||
godray_spawn_offset = Vector3(20, 80, 20)
|
||||
godray_rotation_degrees = Vector3(50, 30, 0)
|
||||
godray_scale = Vector3(2, 25, 50)
|
||||
|
||||