diff --git a/Actors/Player/Player.gd b/Actors/Player/Player.gd index 974e413..776ecb2 100644 --- a/Actors/Player/Player.gd +++ b/Actors/Player/Player.gd @@ -100,5 +100,5 @@ func draw_circle_arc_poly(center, radius, angle_from, angle_to, color): points_arc.push_back(center + Vector2(cos(angle_point), sin(angle_point)) * radius) draw_polygon(points_arc, colors) -func _heard(area): - pass #TODO Sounds +func hear(event): + pass diff --git a/Actors/Player/Player.tscn b/Actors/Player/Player.tscn index 58998eb..4d3425d 100644 --- a/Actors/Player/Player.tscn +++ b/Actors/Player/Player.tscn @@ -30,4 +30,3 @@ collision_mask = 32 [node name="CollisionShape2D" type="CollisionShape2D" parent="Earing"] shape = SubResource( 2 ) -[connection signal="area_entered" from="Earing" to="." method="_heard"] diff --git a/Scenes/Game.gd b/Scenes/Game.gd index 7264ae4..ba427d7 100644 --- a/Scenes/Game.gd +++ b/Scenes/Game.gd @@ -8,6 +8,7 @@ onready var ui = $CanvasLayer/ui onready var world = $world onready var systems = $systems onready var netgame = $"/root/Multiplayer" +onready var physics = world.get_world_2d().direct_space_state var writing = false @@ -53,10 +54,26 @@ master func ready_to_spawn() -> void: # Then spawn him as well rpc("spawn_player", id) -remotesync func spawn_player(id): +master func broadcast_zone(message: String, origin: Vector2, radius: float) -> void: + var shape = CircleShape2D.new() + shape.radius = radius + var query = Physics2DShapeQueryParameters.new() + query.collision_layer = 32 + query.transform = Transform(world.transform.translated(origin)) + query.set_shape(shape) + var res = physics.intersect_shape(query, 100) + print(res) + +master func broadcast(message: String) -> void: + rpc("add_log", message) + +remotesync func add_log(message: String) -> void: + ui.logs.add_line(message) + +remotesync func spawn_player(id: int) -> void: world.spawn_player(id, multiplayer.get_network_unique_id() == id) -remotesync func process_command(cmd: UICommand): +remotesync func process_command(cmd: UICommand) -> void: match cmd.cmd_type: UICommand.CommandType.SetShipTarget: world.map.current_ship_target = cmd.cmd_args[0] diff --git a/Scenes/Maps/odyssey.tscn b/Scenes/Maps/odyssey.tscn index db2c8a0..fe9c759 100644 --- a/Scenes/Maps/odyssey.tscn +++ b/Scenes/Maps/odyssey.tscn @@ -33,7 +33,7 @@ material = SubResource( 1 ) position = Vector2( 208, 256 ) texture = ExtResource( 7 ) region_enabled = true -region_rect = Rect2( 0, 0, 10000, 10000 ) +region_rect = Rect2( 0, 0, 100000, 100000 ) __meta__ = { "_edit_group_": true, "_edit_lock_": true @@ -57,7 +57,7 @@ cell_size = Vector2( 32, 32 ) cell_quadrant_size = 32 occluder_light_mask = -2147483647 format = 1 -tile_data = PoolIntArray( -589822, 0, 131073, -589818, 0, 131073, -524286, 0, 65539, -524282, 0, 65539, -458750, 0, 65539, -458746, 0, 65539, -327706, 0, 131072, -327705, 0, 65536, -327704, 0, 196608, -393214, 0, 65538, -393213, 0, 196608, -393211, 0, 65537, -393210, 0, 196611, -262168, 0, 65539, -327677, 0, 65539, -327675, 0, 65539, -196632, 0, 65539, -262141, 0, 65539, -262139, 0, 65539, -131101, 0, 131072, -131100, 0, 65536, -131099, 0, 65536, -131098, 0, 65536, -131097, 0, 65536, -131096, 0, 131074, -196605, 0, 65539, -196603, 0, 65539, -65560, 0, 65539, -131069, 0, 65539, -131067, 0, 65539, -131050, 0, 65537, -131049, 0, 262144, -26, 0, 131073, -24, 0, 65539, -65533, 0, 65539, -65531, 0, 65539, -65514, 0, 65539, -65512, 0, 131073, 65507, 0, 131072, 65508, 0, 65536, 65509, 0, 65536, 65510, 0, 2, 65511, 0, 65536, 65512, 0, 196610, 65513, 0, 65536, 65514, 0, 65536, 65515, 0, 65536, 65516, 0, 65536, 65517, 0, 65536, 65518, 0, 65536, 65519, 0, 65536, 65520, 0, 65536, 65521, 0, 65536, 65522, 0, 1, 65523, 0, 65536, 65524, 0, 65536, 65525, 0, 65536, 65526, 0, 65536, 65527, 0, 65536, 65528, 0, 65536, 65529, 0, 1, 65530, 0, 65536, 65531, 0, 65536, 65532, 0, 65536, 65533, 0, 65536, 65534, 0, 65536, 65535, 0, 65536, 0, 0, 65536, 1, 0, 65536, 2, 0, 65536, 3, 0, 2, 4, 0, 65536, 5, 0, 2, 6, 0, 1, 7, 0, 65536, 8, 0, 65536, 9, 0, 65536, 10, 0, 65536, 11, 0, 1, 12, 0, 65536, 13, 0, 1, 14, 0, 65536, 15, 0, 65536, 16, 0, 65536, 17, 0, 65536, 18, 0, 65536, 19, 0, 65536, 20, 0, 65536, 21, 0, 65536, 22, 0, 196610, 23, 0, 65536, 24, 0, 131074, 131048, 0, 65539, 131058, 0, 65539, 131065, 0, 65539, 65542, 0, 65539, 65547, 0, 131075, 65549, 0, 131075, 65558, 0, 65539, 65560, 0, 131075, 196584, 0, 65539, 196594, 0, 65539, 196601, 0, 65539, 131078, 0, 65539, 131094, 0, 65538, 131095, 0, 0, 262115, 0, 131072, 262116, 0, 65536, 262117, 0, 65536, 262118, 0, 65536, 262119, 0, 65536, 262120, 0, 131074, 262130, 0, 65539, 262137, 0, 65539, 196614, 0, 65539, 327656, 0, 65539, 327666, 0, 65539, 327670, 0, 131072, 327671, 0, 65536, 327672, 0, 65536, 327673, 0, 131074, 262150, 0, 65538, 262151, 0, 196608, 393192, 0, 65539, 393202, 0, 65539, 393209, 0, 65539, 327687, 0, 131075, 458726, 0, 131072, 458727, 0, 65536, 458728, 0, 196611, 458738, 0, 65539, 458745, 0, 65538, 458746, 0, 65536, 458747, 0, 65536, 458748, 0, 0, 524272, 0, 131072, 524273, 0, 65536, 524274, 0, 196611 ) +tile_data = PoolIntArray( -589822, 0, 131073, -589818, 0, 131073, -524286, 0, 65539, -524282, 0, 65539, -458750, 0, 65539, -458746, 0, 65539, -327706, 0, 131072, -327705, 0, 65536, -327704, 0, 196608, -393214, 0, 65539, -393210, 0, 65539, -262168, 0, 65539, -327678, 0, 65538, -327677, 0, 196608, -327675, 0, 65537, -327674, 0, 196611, -196632, 0, 65539, -262141, 0, 65539, -262139, 0, 65539, -131101, 0, 131072, -131100, 0, 65536, -131099, 0, 65536, -131098, 0, 65536, -131097, 0, 65536, -131096, 0, 131074, -196605, 0, 65539, -196603, 0, 65539, -65560, 0, 65539, -131069, 0, 65539, -131067, 0, 65539, -131050, 0, 65537, -131049, 0, 262144, -26, 0, 131073, -24, 0, 65539, -65533, 0, 65539, -65531, 0, 65539, -65523, 0, 131073, -65514, 0, 65539, -65512, 0, 131073, 65507, 0, 131072, 65508, 0, 65536, 65509, 0, 65536, 65510, 0, 2, 65511, 0, 65536, 65512, 0, 196610, 65513, 0, 65536, 65514, 0, 65536, 65515, 0, 65536, 65516, 0, 65536, 65517, 0, 65536, 65518, 0, 65536, 65519, 0, 65536, 65520, 0, 65536, 65521, 0, 65536, 65522, 0, 1, 65523, 0, 65536, 65524, 0, 65536, 65525, 0, 65536, 65526, 0, 65536, 65527, 0, 65536, 65528, 0, 65536, 65529, 0, 1, 65530, 0, 65536, 65531, 0, 65536, 65532, 0, 65536, 65533, 0, 65536, 65534, 0, 65536, 65535, 0, 65536, 0, 0, 65536, 1, 0, 65536, 2, 0, 65536, 3, 0, 2, 4, 0, 65536, 5, 0, 2, 6, 0, 1, 7, 0, 65536, 8, 0, 65536, 9, 0, 65536, 10, 0, 65536, 11, 0, 1, 12, 0, 65536, 13, 0, 196610, 14, 0, 65536, 15, 0, 65536, 16, 0, 65536, 17, 0, 65536, 18, 0, 65536, 19, 0, 65536, 20, 0, 65536, 21, 0, 65536, 22, 0, 196610, 23, 0, 65536, 24, 0, 131074, 131048, 0, 65539, 131058, 0, 65539, 131065, 0, 65539, 65542, 0, 65539, 65547, 0, 131075, 65549, 0, 131075, 65558, 0, 65539, 65560, 0, 131075, 196584, 0, 65539, 196594, 0, 65539, 196601, 0, 65539, 131078, 0, 65539, 131094, 0, 65538, 131095, 0, 0, 262115, 0, 131072, 262116, 0, 65536, 262117, 0, 65536, 262118, 0, 65536, 262119, 0, 65536, 262120, 0, 131074, 262130, 0, 65539, 262137, 0, 65539, 196614, 0, 65539, 327656, 0, 65539, 327666, 0, 65539, 327670, 0, 131072, 327671, 0, 65536, 327672, 0, 65536, 327673, 0, 131074, 262150, 0, 65538, 262151, 0, 196608, 393192, 0, 65539, 393202, 0, 65539, 393209, 0, 65539, 327687, 0, 131075, 458726, 0, 131072, 458727, 0, 65536, 458728, 0, 196611, 458738, 0, 65539, 458745, 0, 65538, 458746, 0, 65536, 458747, 0, 65536, 458748, 0, 0, 524272, 0, 131072, 524273, 0, 65536, 524274, 0, 196611 ) [node name="floor" type="TileMap" parent="."] z_index = 3 @@ -67,7 +67,7 @@ cell_size = Vector2( 32, 32 ) cell_quadrant_size = 32 occluder_light_mask = -2147483647 format = 1 -tile_data = PoolIntArray( -655358, 0, 0, -655354, 0, 0, -589822, 0, 0, -589818, 0, 0, -524286, 0, 0, -524282, 0, 0, -458750, 0, 0, -458749, 0, 0, -458748, 0, 0, -458747, 0, 0, -458746, 0, 0, -393214, 0, 0, -393213, 0, 0, -393212, 0, 0, -393211, 0, 0, -393210, 0, 0, -327678, 0, 0, -327677, 0, 0, -327676, 0, 0, -327675, 0, 0, -327674, 0, 0, -262142, 0, 0, -262141, 0, 0, -262140, 0, 0, -262139, 0, 0, -262138, 0, 0, -131095, 0, 0, -196607, 0, 0, -196606, 0, 0, -196605, 0, 0, -196604, 0, 0, -196603, 0, 0, -196602, 0, 0, -196601, 0, 0, -196588, 9, 0, -196587, 8, 0, -196586, 9, 0, -196585, 9, 0, -65563, 0, 0, -65562, 0, 0, -65561, 0, 0, -65559, 0, 0, -131072, 0, 0, -131071, 0, 0, -131070, 0, 0, -131069, 0, 0, -131068, 0, 0, -131067, 0, 0, -131066, 0, 0, -131065, 0, 0, -131052, 9, 0, -131051, 8, 0, -131050, 9, 0, -131049, 9, 0, -131048, 8, 0, -131047, 8, 0, -131046, 9, 0, -27, 0, 0, -26, 0, 0, -25, 0, 0, -24, 0, 0, -23, 0, 0, -21, 0, 0, -20, 0, 0, -19, 0, 0, -18, 0, 0, -17, 0, 0, -16, 0, 0, -15, 0, 0, -14, 0, 0, -13, 0, 0, -12, 0, 0, -11, 0, 0, -10, 0, 0, -9, 0, 0, -8, 0, 0, -7, 0, 0, -6, 0, 0, -5, 0, 0, -4, 0, 0, -3, 0, 0, -2, 0, 0, -1, 0, 0, -65536, 0, 0, -65535, 0, 0, -65534, 0, 0, -65533, 0, 0, -65532, 0, 0, -65531, 0, 0, -65530, 0, 0, -65529, 0, 0, -65528, 0, 0, -65527, 0, 0, -65526, 0, 0, -65525, 0, 0, -65524, 0, 0, -65523, 0, 0, -65522, 0, 0, -65521, 0, 0, -65520, 0, 0, -65519, 0, 0, -65518, 0, 0, -65516, 8, 0, -65515, 8, 0, -65514, 9, 0, -65513, 8, 0, -65512, 8, 0, -65511, 8, 0, -65510, 9, 0, -65509, 9, 0, 65509, 0, 0, 65510, 0, 0, 65511, 0, 0, 65512, 0, 0, 65513, 0, 0, 65514, 0, 0, 65515, 0, 0, 65516, 0, 0, 65517, 0, 0, 65518, 0, 0, 65519, 0, 0, 65520, 0, 0, 65521, 0, 0, 65522, 0, 0, 65523, 0, 0, 65524, 0, 0, 65525, 0, 0, 65526, 0, 0, 65527, 0, 0, 65528, 0, 0, 65529, 0, 0, 65530, 0, 0, 65531, 0, 0, 65532, 0, 0, 65533, 0, 0, 65534, 0, 0, 65535, 0, 0, 0, 0, 0, 1, 0, 0, 2, 0, 0, 3, 0, 0, 4, 0, 0, 5, 0, 0, 6, 0, 0, 7, 0, 0, 8, 0, 0, 9, 0, 0, 10, 0, 0, 11, 0, 0, 12, 0, 0, 13, 0, 0, 14, 0, 0, 15, 0, 0, 16, 0, 0, 17, 0, 0, 18, 0, 0, 19, 0, 0, 20, 9, 0, 21, 9, 0, 22, 9, 0, 23, 9, 0, 24, 9, 0, 25, 8, 0, 26, 9, 0, 27, 9, 0, 131045, 0, 0, 131046, 0, 0, 131047, 0, 0, 131048, 0, 0, 131049, 0, 0, 131051, 0, 0, 131052, 0, 0, 131053, 0, 0, 131054, 0, 0, 131055, 0, 0, 131056, 0, 0, 131057, 0, 0, 131058, 0, 0, 131059, 0, 0, 131060, 0, 0, 131061, 0, 0, 131062, 0, 0, 131063, 0, 0, 131064, 0, 0, 131065, 0, 0, 131066, 0, 0, 131067, 0, 0, 131068, 0, 0, 131069, 0, 0, 131070, 0, 0, 131071, 0, 0, 65536, 0, 0, 65537, 0, 0, 65538, 0, 0, 65539, 0, 0, 65540, 0, 0, 65541, 0, 0, 65542, 0, 0, 65543, 0, 0, 65544, 0, 0, 65545, 0, 0, 65546, 0, 0, 65547, 0, 0, 65548, 0, 0, 65549, 0, 0, 65550, 0, 0, 65551, 0, 0, 65552, 0, 0, 65553, 0, 0, 65554, 0, 0, 65556, 8, 0, 65557, 8, 0, 65558, 9, 0, 65559, 8, 0, 65560, 8, 0, 65561, 8, 0, 65562, 9, 0, 65563, 9, 0, 196581, 0, 0, 196582, 0, 0, 196583, 0, 0, 196585, 0, 0, 196594, 0, 0, 196601, 0, 0, 131073, 0, 0, 131074, 0, 0, 131075, 0, 0, 131076, 0, 0, 131077, 0, 0, 131078, 0, 0, 131079, 0, 0, 131083, 0, 0, 131085, 0, 0, 131092, 9, 0, 131093, 8, 0, 131094, 9, 0, 131095, 9, 0, 131096, 8, 0, 131097, 8, 0, 131098, 9, 0, 262121, 0, 0, 262124, 0, 0, 262125, 0, 0, 262126, 0, 0, 262128, 0, 0, 262129, 0, 0, 262130, 0, 0, 262131, 0, 0, 262132, 0, 0, 262134, 3, 0, 262135, 3, 0, 262136, 3, 0, 262137, 3, 0, 262138, 3, 0, 262139, 3, 0, 262140, 3, 0, 262141, 3, 0, 262142, 3, 0, 262143, 3, 0, 196610, 0, 0, 196611, 0, 0, 196612, 0, 0, 196613, 0, 0, 196614, 0, 0, 196615, 0, 0, 196617, 8, 0, 196618, 5, 0, 196619, 8, 0, 196620, 5, 0, 196621, 8, 0, 196622, 5, 0, 196623, 8, 0, 196624, 5, 0, 196625, 8, 0, 196626, 5, 0, 196628, 9, 0, 196629, 8, 0, 196630, 9, 0, 196631, 9, 0, 327660, 0, 0, 327661, 0, 0, 327662, 0, 0, 327664, 0, 0, 327665, 0, 0, 327666, 0, 0, 327667, 0, 0, 327668, 0, 0, 327669, 0, 0, 327670, 3, 0, 327671, 3, 0, 327672, 3, 0, 327673, 3, 0, 327674, 3, 0, 327675, 3, 0, 327676, 3, 0, 327677, 3, 0, 327678, 3, 0, 327679, 3, 0, 262144, 3, 0, 262146, 0, 0, 262147, 0, 0, 262148, 0, 0, 262149, 0, 0, 262150, 0, 0, 262151, 0, 0, 262152, 0, 0, 262153, 5, 0, 262154, 8, 0, 262155, 5, 0, 262156, 8, 0, 262157, 5, 0, 262158, 8, 0, 262159, 5, 0, 262160, 8, 0, 262161, 5, 0, 262162, 8, 0, 393196, 0, 0, 393197, 0, 0, 393198, 0, 0, 393200, 0, 0, 393201, 0, 0, 393202, 0, 0, 393203, 0, 0, 393204, 0, 0, 393205, 0, 0, 393206, 3, 0, 393207, 3, 0, 393208, 3, 0, 393209, 3, 0, 393210, 3, 0, 393211, 3, 0, 393212, 3, 0, 393213, 3, 0, 393214, 3, 0, 393215, 3, 0, 327680, 3, 0, 327682, 0, 0, 327683, 0, 0, 327684, 0, 0, 327685, 0, 0, 327686, 0, 0, 327687, 0, 0, 327688, 0, 0, 327689, 8, 0, 327690, 5, 0, 327691, 8, 0, 327692, 5, 0, 327693, 8, 0, 327694, 5, 0, 327695, 8, 0, 327696, 5, 0, 327697, 8, 0, 327698, 5, 0, 458732, 0, 0, 458733, 0, 0, 458734, 0, 0, 458736, 0, 0, 458737, 0, 0, 458738, 0, 0, 458739, 0, 0, 458740, 0, 0, 458742, 3, 0, 458743, 3, 0, 458744, 3, 0, 458745, 3, 0, 458746, 3, 0, 458747, 3, 0, 458748, 3, 0, 458749, 3, 0, 458750, 3, 0, 458751, 3, 0, 393216, 3, 0, 393218, 0, 0, 393219, 0, 0, 393220, 0, 0, 393221, 0, 0, 393222, 0, 0, 393223, 0, 0, 393225, 5, 0, 393226, 8, 0, 393227, 5, 0, 393228, 8, 0, 393229, 5, 0, 393230, 8, 0, 393231, 5, 0, 393232, 8, 0, 393233, 5, 0, 393234, 8, 0, 524268, 0, 0, 524269, 0, 0, 524270, 0, 0, 524271, 0, 0, 524272, 0, 0, 524273, 0, 0, 524274, 0, 0, 524275, 0, 0, 524276, 0, 0, 524278, 3, 0, 524279, 3, 0, 524280, 3, 0, 524281, 3, 0, 524282, 3, 0, 524283, 3, 0, 524284, 3, 0, 524285, 3, 0, 524286, 3, 0, 524287, 3, 0, 458752, 3, 0, 458754, 0, 0, 458755, 0, 0, 458756, 0, 0, 458757, 0, 0, 458758, 0, 0, 458759, 0, 0, 589804, 0, 0, 589805, 0, 0, 589806, 0, 0, 589808, 0, 0, 589809, 0, 0, 589810, 0, 0, 589811, 0, 0, 589812, 0, 0, 589814, 3, 0, 589815, 3, 0, 589816, 3, 0, 589817, 3, 0, 589818, 3, 0, 589819, 3, 0, 589820, 3, 0, 589821, 3, 0, 589822, 3, 0, 589823, 3, 0, 524288, 3, 0, 524290, 0, 0, 524291, 0, 0, 524292, 0, 0, 524293, 0, 0, 524294, 0, 0, 524295, 0, 0 ) +tile_data = PoolIntArray( -655358, 0, 0, -655354, 0, 0, -589822, 0, 0, -589818, 0, 0, -524286, 0, 0, -524282, 0, 0, -458750, 0, 0, -458749, 0, 0, -458748, 0, 0, -458747, 0, 0, -458746, 0, 0, -393214, 0, 0, -393213, 0, 0, -393212, 0, 0, -393211, 0, 0, -393210, 0, 0, -393208, 9, 0, -393207, 9, 0, -393206, 9, 0, -393205, 9, 0, -393204, 9, 0, -393203, 9, 0, -393202, 9, 0, -393201, 9, 0, -393200, 9, 0, -393199, 9, 0, -393198, 9, 0, -327678, 0, 0, -327677, 0, 0, -327676, 0, 0, -327675, 0, 0, -327674, 0, 0, -327673, 0, 0, -327672, 9, 0, -327671, 9, 0, -327670, 9, 0, -327669, 9, 0, -327668, 9, 0, -327667, 9, 0, -327666, 9, 0, -327665, 9, 0, -327664, 9, 0, -327663, 9, 0, -327662, 9, 0, -262141, 0, 0, -262140, 0, 0, -262139, 0, 0, -262135, 9, 0, -262134, 9, 0, -262133, 9, 0, -262132, 9, 0, -262131, 9, 0, -262130, 9, 0, -262129, 9, 0, -262128, 9, 0, -262127, 9, 0, -262126, 9, 0, -131095, 0, 0, -196607, 0, 0, -196606, 0, 0, -196605, 0, 0, -196604, 0, 0, -196603, 0, 0, -196602, 0, 0, -196601, 0, 0, -196599, 9, 0, -196598, 9, 0, -196597, 9, 0, -196596, 9, 0, -196595, 9, 0, -196594, 9, 0, -196593, 9, 0, -196592, 9, 0, -196591, 9, 0, -196590, 9, 0, -196588, 9, 0, -196587, 8, 0, -196586, 9, 0, -196585, 9, 0, -65563, 0, 0, -65562, 0, 0, -65561, 0, 0, -65559, 0, 0, -131072, 0, 0, -131071, 0, 0, -131070, 0, 0, -131069, 0, 0, -131068, 0, 0, -131067, 0, 0, -131066, 0, 0, -131065, 0, 0, -131059, 0, 0, -131052, 9, 0, -131051, 8, 0, -131050, 9, 0, -131049, 9, 0, -131048, 8, 0, -131047, 8, 0, -131046, 9, 0, -27, 0, 0, -26, 0, 0, -25, 0, 0, -24, 0, 0, -23, 0, 0, -21, 0, 0, -20, 0, 0, -19, 0, 0, -18, 0, 0, -17, 0, 0, -16, 0, 0, -15, 0, 0, -14, 0, 0, -13, 0, 0, -12, 0, 0, -11, 0, 0, -10, 0, 0, -9, 0, 0, -8, 0, 0, -7, 0, 0, -6, 0, 0, -5, 0, 0, -4, 0, 0, -3, 0, 0, -2, 0, 0, -1, 0, 0, -65536, 0, 0, -65535, 0, 0, -65534, 0, 0, -65533, 0, 0, -65532, 0, 0, -65531, 0, 0, -65530, 0, 0, -65529, 0, 0, -65528, 0, 0, -65527, 0, 0, -65526, 0, 0, -65525, 0, 0, -65524, 0, 0, -65523, 0, 0, -65522, 0, 0, -65521, 0, 0, -65520, 0, 0, -65519, 0, 0, -65518, 0, 0, -65516, 8, 0, -65515, 8, 0, -65514, 9, 0, -65513, 8, 0, -65512, 8, 0, -65511, 8, 0, -65510, 9, 0, -65509, 9, 0, 65509, 0, 0, 65510, 0, 0, 65511, 0, 0, 65512, 0, 0, 65513, 0, 0, 65514, 0, 0, 65515, 0, 0, 65516, 0, 0, 65517, 0, 0, 65518, 0, 0, 65519, 0, 0, 65520, 0, 0, 65521, 0, 0, 65522, 0, 0, 65523, 0, 0, 65524, 0, 0, 65525, 0, 0, 65526, 0, 0, 65527, 0, 0, 65528, 0, 0, 65529, 0, 0, 65530, 0, 0, 65531, 0, 0, 65532, 0, 0, 65533, 0, 0, 65534, 0, 0, 65535, 0, 0, 0, 0, 0, 1, 0, 0, 2, 0, 0, 3, 0, 0, 4, 0, 0, 5, 0, 0, 6, 0, 0, 7, 0, 0, 8, 0, 0, 9, 0, 0, 10, 0, 0, 11, 0, 0, 12, 0, 0, 13, 0, 0, 14, 0, 0, 15, 0, 0, 16, 0, 0, 17, 0, 0, 18, 0, 0, 19, 0, 0, 20, 9, 0, 21, 9, 0, 22, 9, 0, 23, 9, 0, 24, 9, 0, 25, 8, 0, 26, 9, 0, 27, 9, 0, 131045, 0, 0, 131046, 0, 0, 131047, 0, 0, 131048, 0, 0, 131049, 0, 0, 131051, 0, 0, 131052, 0, 0, 131053, 0, 0, 131054, 0, 0, 131055, 0, 0, 131056, 0, 0, 131057, 0, 0, 131058, 0, 0, 131059, 0, 0, 131060, 0, 0, 131061, 0, 0, 131062, 0, 0, 131063, 0, 0, 131064, 0, 0, 131065, 0, 0, 131066, 0, 0, 131067, 0, 0, 131068, 0, 0, 131069, 0, 0, 131070, 0, 0, 131071, 0, 0, 65536, 0, 0, 65537, 0, 0, 65538, 0, 0, 65539, 0, 0, 65540, 0, 0, 65541, 0, 0, 65542, 0, 0, 65543, 0, 0, 65544, 0, 0, 65545, 0, 0, 65546, 0, 0, 65547, 0, 0, 65548, 0, 0, 65549, 0, 0, 65550, 0, 0, 65551, 0, 0, 65552, 0, 0, 65553, 0, 0, 65554, 0, 0, 65556, 8, 0, 65557, 8, 0, 65558, 9, 0, 65559, 8, 0, 65560, 8, 0, 65561, 8, 0, 65562, 9, 0, 65563, 9, 0, 196581, 0, 0, 196582, 0, 0, 196583, 0, 0, 196585, 0, 0, 196594, 0, 0, 196601, 0, 0, 131073, 0, 0, 131074, 0, 0, 131075, 0, 0, 131076, 0, 0, 131077, 0, 0, 131078, 0, 0, 131079, 0, 0, 131083, 0, 0, 131085, 0, 0, 131092, 9, 0, 131093, 8, 0, 131094, 9, 0, 131095, 9, 0, 131096, 8, 0, 131097, 8, 0, 131098, 9, 0, 262121, 0, 0, 262124, 0, 0, 262125, 0, 0, 262126, 0, 0, 262128, 0, 0, 262129, 0, 0, 262130, 0, 0, 262131, 0, 0, 262132, 0, 0, 262134, 3, 0, 262135, 3, 0, 262136, 3, 0, 262137, 3, 0, 262138, 3, 0, 262139, 3, 0, 262140, 3, 0, 262141, 3, 0, 262142, 3, 0, 262143, 3, 0, 196610, 0, 0, 196611, 0, 0, 196612, 0, 0, 196613, 0, 0, 196614, 0, 0, 196615, 0, 0, 196617, 8, 0, 196618, 5, 0, 196619, 8, 0, 196620, 5, 0, 196621, 8, 0, 196622, 5, 0, 196623, 8, 0, 196624, 5, 0, 196625, 8, 0, 196626, 5, 0, 196628, 9, 0, 196629, 8, 0, 196630, 9, 0, 196631, 9, 0, 327660, 0, 0, 327661, 0, 0, 327662, 0, 0, 327664, 0, 0, 327665, 0, 0, 327666, 0, 0, 327667, 0, 0, 327668, 0, 0, 327669, 0, 0, 327670, 3, 0, 327671, 3, 0, 327672, 3, 0, 327673, 3, 0, 327674, 3, 0, 327675, 3, 0, 327676, 3, 0, 327677, 3, 0, 327678, 3, 0, 327679, 3, 0, 262144, 3, 0, 262146, 0, 0, 262147, 0, 0, 262148, 0, 0, 262149, 0, 0, 262150, 0, 0, 262151, 0, 0, 262152, 0, 0, 262153, 5, 0, 262154, 8, 0, 262155, 5, 0, 262156, 8, 0, 262157, 5, 0, 262158, 8, 0, 262159, 5, 0, 262160, 8, 0, 262161, 5, 0, 262162, 8, 0, 393196, 0, 0, 393197, 0, 0, 393198, 0, 0, 393200, 0, 0, 393201, 0, 0, 393202, 0, 0, 393203, 0, 0, 393204, 0, 0, 393205, 0, 0, 393206, 3, 0, 393207, 3, 0, 393208, 3, 0, 393209, 3, 0, 393210, 3, 0, 393211, 3, 0, 393212, 3, 0, 393213, 3, 0, 393214, 3, 0, 393215, 3, 0, 327680, 3, 0, 327682, 0, 0, 327683, 0, 0, 327684, 0, 0, 327685, 0, 0, 327686, 0, 0, 327687, 0, 0, 327688, 0, 0, 327689, 8, 0, 327690, 5, 0, 327691, 8, 0, 327692, 5, 0, 327693, 8, 0, 327694, 5, 0, 327695, 8, 0, 327696, 5, 0, 327697, 8, 0, 327698, 5, 0, 458732, 0, 0, 458733, 0, 0, 458734, 0, 0, 458736, 0, 0, 458737, 0, 0, 458738, 0, 0, 458739, 0, 0, 458740, 0, 0, 458742, 3, 0, 458743, 3, 0, 458744, 3, 0, 458745, 3, 0, 458746, 3, 0, 458747, 3, 0, 458748, 3, 0, 458749, 3, 0, 458750, 3, 0, 458751, 3, 0, 393216, 3, 0, 393218, 0, 0, 393219, 0, 0, 393220, 0, 0, 393221, 0, 0, 393222, 0, 0, 393223, 0, 0, 393225, 5, 0, 393226, 8, 0, 393227, 5, 0, 393228, 8, 0, 393229, 5, 0, 393230, 8, 0, 393231, 5, 0, 393232, 8, 0, 393233, 5, 0, 393234, 8, 0, 524268, 0, 0, 524269, 0, 0, 524270, 0, 0, 524271, 0, 0, 524272, 0, 0, 524273, 0, 0, 524274, 0, 0, 524275, 0, 0, 524276, 0, 0, 524278, 3, 0, 524279, 3, 0, 524280, 3, 0, 524281, 3, 0, 524282, 3, 0, 524283, 3, 0, 524284, 3, 0, 524285, 3, 0, 524286, 3, 0, 524287, 3, 0, 458752, 3, 0, 458754, 0, 0, 458755, 0, 0, 458756, 0, 0, 458757, 0, 0, 458758, 0, 0, 458759, 0, 0, 589804, 0, 0, 589805, 0, 0, 589806, 0, 0, 589808, 0, 0, 589809, 0, 0, 589810, 0, 0, 589811, 0, 0, 589812, 0, 0, 589814, 3, 0, 589815, 3, 0, 589816, 3, 0, 589817, 3, 0, 589818, 3, 0, 589819, 3, 0, 589820, 3, 0, 589821, 3, 0, 589822, 3, 0, 589823, 3, 0, 524288, 3, 0, 524290, 0, 0, 524291, 0, 0, 524292, 0, 0, 524293, 0, 0, 524294, 0, 0, 524295, 0, 0 ) [node name="walls" type="TileMap" parent="."] position = Vector2( 0, -1 ) @@ -78,7 +78,7 @@ cell_size = Vector2( 32, 32 ) cell_quadrant_size = 32 occluder_light_mask = -2147483647 format = 1 -tile_data = PoolIntArray( -655359, 3, 0, -655357, 3, 0, -655355, 3, 0, -655353, 3, 0, -524309, 2, 0, -524308, 2, 0, -524307, 2, 0, -524306, 2, 0, -524305, 2, 0, -524304, 2, 0, -524303, 2, 0, -524302, 2, 0, -524301, 2, 0, -524300, 2, 0, -524299, 2, 0, -524298, 2, 0, -524297, 2, 0, -524296, 2, 0, -524295, 2, 0, -524294, 2, 0, -524293, 2, 0, -524292, 2, 0, -524291, 2, 0, -524290, 2, 0, -524289, 2, 0, -589824, 2, 0, -589823, 3, 0, -589821, 3, 0, -589819, 3, 0, -589817, 3, 0, -458773, 2, 0, -524288, 2, 0, -524287, 3, 0, -524285, 3, 0, -524284, 2, 0, -524283, 3, 0, -524281, 3, 0, -393243, 2, 0, -393242, 3, 0, -393241, 3, 0, -393240, 2, 0, -393239, 2, 0, -393238, 2, 0, -393237, 2, 0, -458752, 2, 0, -458751, 2, 0, -458745, 2, 0, -458744, 2, 0, -458743, 2, 0, -458742, 2, 0, -458741, 2, 0, -458740, 2, 0, -458739, 2, 0, -458738, 2, 0, -458737, 2, 0, -458736, 2, 0, -458735, 2, 0, -458734, 2, 0, -458733, 2, 0, -327707, 2, 0, -327701, 2, 0, -393215, 2, 0, -393209, 2, 0, -393197, 2, 0, -262171, 2, 0, -262165, 2, 0, -327679, 2, 0, -327673, 2, 0, -327661, 2, 0, -196638, 2, 0, -196637, 2, 0, -196636, 2, 0, -196635, 2, 0, -196629, 2, 0, -262144, 2, 0, -262143, 2, 0, -262142, 3, 0, -262140, 2, 0, -262138, 3, 0, -262137, 2, 0, -262136, 2, 0, -262125, 2, 0, -262124, 2, 0, -262123, 2, 0, -262122, 2, 0, -262121, 2, 0, -262120, 3, 0, -131102, 2, 0, -131094, 2, 0, -131093, 2, 0, -131073, 2, 0, -196608, 2, 0, -196600, 2, 0, -196589, 2, 0, -196584, 3, 0, -196583, 3, 0, -196582, 3, 0, -196581, 3, 0, -65566, 2, 0, -65558, 2, 0, -65557, 2, 0, -65556, 2, 0, -65555, 2, 0, -65554, 2, 0, -65553, 2, 0, -65552, 2, 0, -65551, 2, 0, -65550, 2, 0, -65549, 2, 0, -65548, 2, 0, -65547, 2, 0, -65546, 2, 0, -65545, 2, 0, -65544, 2, 0, -65543, 2, 0, -65542, 2, 0, -65541, 2, 0, -65540, 2, 0, -65539, 2, 0, -65538, 2, 0, -65537, 2, 0, -131064, 2, 0, -131063, 2, 0, -131062, 2, 0, -131061, 2, 0, -131060, 2, 0, -131059, 2, 0, -131058, 2, 0, -131057, 2, 0, -131056, 2, 0, -131055, 2, 0, -131054, 2, 0, -131053, 2, 0, -131045, 3, 0, -131044, 3, 0, -30, 2, 0, -22, 2, 0, -65517, 3, 0, -65508, 3, 0, 65506, 2, 0, 28, 3, 0, 131042, 2, 0, 131050, 2, 0, 65555, 3, 0, 65564, 3, 0, 196578, 2, 0, 196586, 2, 0, 196587, 2, 0, 196588, 2, 0, 196589, 3, 0, 196590, 2, 0, 196591, 2, 0, 196592, 3, 0, 196593, 3, 0, 196595, 3, 0, 196596, 3, 0, 196597, 2, 0, 196598, 3, 0, 196599, 3, 0, 196600, 2, 0, 196602, 3, 0, 196603, 2, 0, 196604, 2, 0, 196605, 2, 0, 196606, 3, 0, 196607, 3, 0, 131072, 2, 0, 131080, 2, 0, 131081, 3, 0, 131082, 3, 0, 131084, 3, 0, 131086, 3, 0, 131087, 2, 0, 131088, 2, 0, 131089, 2, 0, 131090, 2, 0, 131091, 2, 0, 131099, 3, 0, 131100, 3, 0, 262114, 2, 0, 262122, 2, 0, 262123, 2, 0, 262127, 2, 0, 262133, 3, 0, 262141, 2, 0, 196608, 2, 0, 196609, 2, 0, 196616, 3, 0, 196627, 2, 0, 196632, 3, 0, 196633, 3, 0, 196634, 3, 0, 196635, 3, 0, 327650, 2, 0, 327651, 2, 0, 327652, 2, 0, 327653, 2, 0, 327659, 2, 0, 327663, 2, 0, 327677, 2, 0, 262145, 2, 0, 262163, 2, 0, 262164, 2, 0, 262165, 2, 0, 262166, 2, 0, 262167, 2, 0, 262168, 3, 0, 393189, 2, 0, 393195, 2, 0, 393199, 3, 0, 393205, 2, 0, 393213, 2, 0, 327681, 2, 0, 327699, 2, 0, 458725, 2, 0, 458731, 2, 0, 458735, 3, 0, 458741, 3, 0, 393217, 2, 0, 393224, 3, 0, 393235, 2, 0, 524261, 2, 0, 524262, 3, 0, 524263, 3, 0, 524264, 2, 0, 524265, 2, 0, 524266, 2, 0, 524267, 2, 0, 524277, 3, 0, 524285, 2, 0, 458753, 3, 0, 458760, 2, 0, 458761, 2, 0, 458762, 2, 0, 458763, 2, 0, 458764, 2, 0, 458765, 2, 0, 458766, 2, 0, 458767, 2, 0, 458768, 2, 0, 458769, 2, 0, 458770, 2, 0, 458771, 2, 0, 589803, 3, 0, 589807, 2, 0, 589813, 2, 0, 589821, 2, 0, 524289, 3, 0, 524296, 2, 0, 655339, 2, 0, 655340, 2, 0, 655341, 3, 0, 655342, 3, 0, 655343, 2, 0, 655344, 2, 0, 655345, 2, 0, 655346, 2, 0, 655347, 2, 0, 655348, 2, 0, 655349, 2, 0, 655350, 2, 0, 655351, 3, 0, 655352, 3, 0, 655353, 3, 0, 655354, 3, 0, 655355, 3, 0, 655356, 2, 0, 655357, 2, 0, 655358, 2, 0, 655359, 2, 0, 589824, 2, 0, 589825, 2, 0, 589826, 3, 0, 589827, 3, 0, 589828, 3, 0, 589829, 3, 0, 589830, 3, 0, 589831, 3, 0, 589832, 2, 0 ) +tile_data = PoolIntArray( -655359, 3, 0, -655357, 3, 0, -655355, 3, 0, -655353, 3, 0, -524309, 2, 0, -524308, 2, 0, -524307, 2, 0, -524306, 2, 0, -524305, 2, 0, -524304, 2, 0, -524303, 2, 0, -524302, 2, 0, -524301, 2, 0, -524300, 2, 0, -524299, 2, 0, -524298, 2, 0, -524297, 2, 0, -524296, 2, 0, -524295, 2, 0, -524294, 2, 0, -524293, 2, 0, -524292, 2, 0, -524291, 2, 0, -524290, 2, 0, -524289, 2, 0, -589824, 2, 0, -589823, 3, 0, -589821, 3, 0, -589819, 3, 0, -589817, 3, 0, -458773, 2, 0, -524288, 2, 0, -524287, 3, 0, -524285, 3, 0, -524284, 2, 0, -524283, 3, 0, -524281, 3, 0, -393243, 2, 0, -393242, 3, 0, -393241, 3, 0, -393240, 2, 0, -393239, 2, 0, -393238, 2, 0, -393237, 2, 0, -458752, 2, 0, -458751, 2, 0, -458745, 2, 0, -458744, 2, 0, -458743, 2, 0, -458742, 2, 0, -458741, 2, 0, -458740, 2, 0, -458739, 2, 0, -458738, 2, 0, -458737, 2, 0, -458736, 2, 0, -458735, 2, 0, -458734, 2, 0, -458733, 2, 0, -327707, 2, 0, -327701, 2, 0, -393215, 2, 0, -393209, 3, 0, -393197, 2, 0, -262171, 2, 0, -262165, 2, 0, -327679, 2, 0, -327661, 2, 0, -196638, 2, 0, -196637, 2, 0, -196636, 2, 0, -196635, 2, 0, -196629, 2, 0, -262144, 2, 0, -262143, 2, 0, -262142, 3, 0, -262140, 2, 0, -262138, 3, 0, -262137, 2, 0, -262136, 2, 0, -262125, 2, 0, -262124, 2, 0, -262123, 3, 0, -262122, 2, 0, -262121, 2, 0, -262120, 3, 0, -131102, 2, 0, -131094, 2, 0, -131093, 2, 0, -131073, 2, 0, -196608, 2, 0, -196600, 2, 0, -196589, 2, 0, -196584, 3, 0, -196583, 3, 0, -196582, 3, 0, -196581, 3, 0, -65566, 2, 0, -65558, 2, 0, -65557, 2, 0, -65556, 2, 0, -65555, 2, 0, -65554, 2, 0, -65553, 2, 0, -65552, 2, 0, -65551, 2, 0, -65550, 2, 0, -65549, 2, 0, -65548, 2, 0, -65547, 2, 0, -65546, 2, 0, -65545, 2, 0, -65544, 2, 0, -65543, 2, 0, -65542, 2, 0, -65541, 2, 0, -65540, 2, 0, -65539, 2, 0, -65538, 2, 0, -65537, 2, 0, -131064, 2, 0, -131063, 2, 0, -131062, 3, 0, -131061, 3, 0, -131060, 2, 0, -131058, 2, 0, -131057, 3, 0, -131056, 3, 0, -131055, 2, 0, -131054, 2, 0, -131053, 2, 0, -131045, 3, 0, -131044, 3, 0, -30, 2, 0, -22, 2, 0, -65517, 3, 0, -65508, 3, 0, 65506, 2, 0, 28, 3, 0, 131042, 2, 0, 131050, 2, 0, 65555, 3, 0, 65564, 3, 0, 196578, 2, 0, 196586, 2, 0, 196587, 2, 0, 196588, 2, 0, 196589, 3, 0, 196590, 2, 0, 196591, 2, 0, 196592, 3, 0, 196593, 3, 0, 196595, 3, 0, 196596, 3, 0, 196597, 2, 0, 196598, 3, 0, 196599, 3, 0, 196600, 2, 0, 196602, 3, 0, 196603, 2, 0, 196604, 2, 0, 196605, 2, 0, 196606, 3, 0, 196607, 3, 0, 131072, 2, 0, 131080, 2, 0, 131081, 3, 0, 131082, 3, 0, 131084, 3, 0, 131086, 3, 0, 131087, 2, 0, 131088, 2, 0, 131089, 2, 0, 131090, 2, 0, 131091, 2, 0, 131099, 3, 0, 131100, 3, 0, 262114, 2, 0, 262122, 2, 0, 262123, 2, 0, 262127, 2, 0, 262133, 3, 0, 262141, 2, 0, 196608, 2, 0, 196609, 2, 0, 196616, 3, 0, 196627, 2, 0, 196632, 3, 0, 196633, 3, 0, 196634, 3, 0, 196635, 3, 0, 327650, 2, 0, 327651, 2, 0, 327652, 2, 0, 327653, 2, 0, 327659, 2, 0, 327663, 2, 0, 327677, 2, 0, 262145, 2, 0, 262163, 2, 0, 262164, 2, 0, 262165, 3, 0, 262166, 2, 0, 262167, 2, 0, 262168, 3, 0, 393189, 2, 0, 393195, 2, 0, 393199, 3, 0, 393205, 2, 0, 393213, 2, 0, 327681, 2, 0, 327699, 3, 0, 458725, 2, 0, 458731, 2, 0, 458735, 3, 0, 458741, 3, 0, 393217, 2, 0, 393224, 3, 0, 393235, 3, 0, 524261, 2, 0, 524262, 3, 0, 524263, 3, 0, 524264, 2, 0, 524265, 2, 0, 524266, 2, 0, 524267, 2, 0, 524277, 3, 0, 524285, 2, 0, 458753, 3, 0, 458760, 2, 0, 458761, 2, 0, 458762, 3, 0, 458763, 3, 0, 458764, 2, 0, 458765, 2, 0, 458766, 3, 0, 458767, 3, 0, 458768, 3, 0, 458769, 2, 0, 458770, 2, 0, 458771, 2, 0, 589803, 3, 0, 589807, 2, 0, 589813, 2, 0, 589821, 2, 0, 524289, 3, 0, 524296, 2, 0, 655339, 2, 0, 655340, 2, 0, 655341, 3, 0, 655342, 3, 0, 655343, 2, 0, 655344, 3, 0, 655345, 3, 0, 655346, 2, 0, 655347, 3, 0, 655348, 3, 0, 655349, 2, 0, 655350, 2, 0, 655351, 3, 0, 655352, 3, 0, 655353, 3, 0, 655354, 3, 0, 655355, 3, 0, 655356, 2, 0, 655357, 2, 0, 655358, 2, 0, 655359, 2, 0, 589824, 2, 0, 589825, 2, 0, 589826, 3, 0, 589827, 3, 0, 589828, 3, 0, 589829, 3, 0, 589830, 3, 0, 589831, 3, 0, 589832, 2, 0 ) script = ExtResource( 3 ) extended_tilemap_node = NodePath("../1x1") @@ -228,6 +228,12 @@ position = Vector2( 256, 128 ) [node name="Door17" parent="objects" instance=ExtResource( 4 )] position = Vector2( 256, 160 ) +[node name="Door18" parent="objects" instance=ExtResource( 4 )] +position = Vector2( 416, -64 ) + +[node name="Door19" parent="objects" instance=ExtResource( 4 )] +position = Vector2( 224, -160 ) + [node name="sockets" type="Node2D" parent="."] z_index = 2 z_as_relative = false @@ -405,6 +411,16 @@ connectionPaths = [ NodePath("../../objects/Door14") ] position = Vector2( 416, 32 ) connectionPaths = [ NodePath("../../objects/Door15") ] +[node name="ElectricSocket36" parent="sockets" instance=ExtResource( 14 )] +position = Vector2( 192, -160 ) +direction = 1 +connectionPaths = [ NodePath("../../objects/Door19") ] + +[node name="ElectricSocket37" parent="sockets" instance=ExtResource( 14 )] +position = Vector2( 416, -32 ) +direction = 2 +connectionPaths = [ NodePath("../../objects/Door18") ] + [node name="lights" type="Node2D" parent="."] modulate = Color( 0.980392, 0.980392, 0.980392, 1 ) z_index = 11 @@ -441,13 +457,20 @@ position = Vector2( -48, -96 ) [node name="Port2" type="Node2D" parent="areas/Docking"] position = Vector2( 80, -96 ) -[node name="Medbay" parent="areas" instance=ExtResource( 8 )] +[node name="Medical" parent="areas" instance=ExtResource( 8 )] position = Vector2( 464, 144 ) z_index = 100 area_name = "Medical" wall_tilemap = NodePath("../../walls") base_tilemap = NodePath("../../base") +[node name="Security" parent="areas" instance=ExtResource( 8 )] +position = Vector2( 464, -144 ) +z_index = 100 +area_name = "Security" +wall_tilemap = NodePath("../../walls") +base_tilemap = NodePath("../../base") + [node name="Bar" parent="areas" instance=ExtResource( 8 )] position = Vector2( -208, 176 ) z_index = 100 @@ -465,10 +488,10 @@ area_name = "Engine room" wall_tilemap = NodePath("../../walls") base_tilemap = NodePath("../../base") -[node name="Lounge" parent="areas" instance=ExtResource( 8 )] +[node name="CrewStorage" parent="areas" instance=ExtResource( 8 )] position = Vector2( -432, 176 ) z_index = 100 -area_name = "Lounge" +area_name = "Crew Storage" wall_tilemap = NodePath("../../walls") base_tilemap = NodePath("../../base") diff --git a/Scenes/UI.gd b/Scenes/UI.gd index 58c9949..ea44736 100644 --- a/Scenes/UI.gd +++ b/Scenes/UI.gd @@ -13,6 +13,8 @@ enum PopupName { EnergyUsage } +onready var logs = $Logs + func _ready() -> void: # Add options to menu buttons var serverMenu = $Menu/Margins/Grid/Server.get_popup() diff --git a/Scenes/UI/Panels/Logs.gd b/Scenes/UI/Panels/Logs.gd index bf5ecb7..98e3549 100644 --- a/Scenes/UI/Panels/Logs.gd +++ b/Scenes/UI/Panels/Logs.gd @@ -1,16 +1,20 @@ extends Control +onready var log_text = $ResizablePanel/RichTextLabel onready var chat_bar = $ResizablePanel/LineEdit -func _input(event): +func _input(event: InputEvent) -> void: if event is InputEventMouseButton: if not chat_bar_focus: chat_bar.release_focus() +func add_line(line: String) -> void: + log_text.append_bbcode(line) + var chat_bar_focus = false -func _chat_bar_status(editing): +func _chat_bar_status(editing: bool) -> void: $"/root/scene".writing = editing -func _chat_bar_focus(entered): +func _chat_bar_focus(entered: bool) -> void: chat_bar_focus = entered diff --git a/Scenes/UI/Panels/Logs.tscn b/Scenes/UI/Panels/Logs.tscn index ab0f88b..6c079b7 100644 --- a/Scenes/UI/Panels/Logs.tscn +++ b/Scenes/UI/Panels/Logs.tscn @@ -51,6 +51,7 @@ custom_fonts/bold_italics_font = SubResource( 1 ) custom_fonts/italics_font = SubResource( 2 ) custom_fonts/bold_font = SubResource( 3 ) custom_fonts/normal_font = SubResource( 4 ) +bbcode_enabled = true selection_enabled = true __meta__ = { "_edit_use_anchors_": false diff --git a/addons/pnhelper/pngui.gd b/addons/pnhelper/pngui.gd index 94026fb..b5490d9 100644 --- a/addons/pnhelper/pngui.gd +++ b/addons/pnhelper/pngui.gd @@ -53,3 +53,5 @@ func _make_socket(direction: String) -> void: func _area_debug_modified(button_pressed): var map = api.get_editor_interface().get_edited_scene_root() as GameMap map.debug_areas = button_pressed + for area in map.get_node("areas").get_children(): + area.update() diff --git a/icon.png.import b/icon.png.import old mode 100755 new mode 100644