Initial commit of Escoria-Reloaded. Still a lot of missing stuff.
This commit is contained in:
134
game/rooms/room3/background.tscn
Normal file
134
game/rooms/room3/background.tscn
Normal file
@@ -0,0 +1,134 @@
|
||||
[gd_scene load_steps=12 format=2]
|
||||
|
||||
[ext_resource path="res://addons/escoria-core/game/core-scripts/escbackground.gd" type="Script" id=1]
|
||||
[ext_resource path="res://game/rooms/room2/bridge.tscn" type="PackedScene" id=2]
|
||||
[ext_resource path="res://game/rooms/room3/smoke.png" type="Texture" id=3]
|
||||
[ext_resource path="res://addons/escoria-core/game/core-scripts/escitem.gd" type="Script" id=4]
|
||||
|
||||
[sub_resource type="Gradient" id=1]
|
||||
offsets = PoolRealArray( 0, 0.830189 )
|
||||
colors = PoolColorArray( 1, 1, 1, 1, 0.353516, 0.353516, 0.353516, 1 )
|
||||
|
||||
[sub_resource type="GradientTexture" id=2]
|
||||
gradient = SubResource( 1 )
|
||||
|
||||
[sub_resource type="Curve" id=3]
|
||||
_data = [ Vector2( 0, 0.0886364 ), 0.0, 0.0, 0, 0, Vector2( 0.612766, 1 ), 0.0, 0.0, 0, 0, Vector2( 0.770213, 0.95 ), -1.55372, -1.55372, 0, 0, Vector2( 1, 0 ), 0.0, 0.0, 0, 0 ]
|
||||
|
||||
[sub_resource type="CurveTexture" id=4]
|
||||
curve = SubResource( 3 )
|
||||
|
||||
[sub_resource type="ParticlesMaterial" id=5]
|
||||
lifetime_randomness = 0.2
|
||||
emission_shape = 1
|
||||
emission_sphere_radius = 1.0
|
||||
flag_disable_z = true
|
||||
gravity = Vector3( 0, -9.81, 0 )
|
||||
angular_velocity = 14.47
|
||||
orbit_velocity = 0.0
|
||||
orbit_velocity_random = 1.0
|
||||
radial_accel = 3.97
|
||||
radial_accel_random = 0.63
|
||||
angle = 160.0
|
||||
angle_random = 1.0
|
||||
scale = 0.5
|
||||
scale_random = 0.45
|
||||
scale_curve = SubResource( 4 )
|
||||
color_ramp = SubResource( 2 )
|
||||
|
||||
[sub_resource type="Animation" id=6]
|
||||
resource_name = "button_broken"
|
||||
tracks/0/type = "value"
|
||||
tracks/0/path = NodePath("Particles2D:emitting")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ true ]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id=7]
|
||||
resource_name = "button_repaired"
|
||||
tracks/0/type = "value"
|
||||
tracks/0/path = NodePath("Particles2D:emitting")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ false ]
|
||||
}
|
||||
|
||||
[node name="background" type="TextureRect"]
|
||||
margin_right = 1300.0
|
||||
margin_bottom = 561.0
|
||||
mouse_filter = 2
|
||||
script = ExtResource( 1 )
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="l_platform" type="Line2D" parent="."]
|
||||
position = Vector2( 0, -266 )
|
||||
points = PoolVector2Array( -2.96298, 712.01, 129.973, 614.429, 499.081, 611.601, 456.654, 806.761, -4.3772, 811.004, -2.96295, 713.424 )
|
||||
|
||||
[node name="l_door" type="Line2D" parent="."]
|
||||
position = Vector2( 0, -266 )
|
||||
points = PoolVector2Array( -2.96298, 712.01, 1.85498, 387.294, 87.755, 339.775, 87.5463, 649.784 )
|
||||
|
||||
[node name="r_platform" type="Line2D" parent="."]
|
||||
position = Vector2( 0, -266 )
|
||||
points = PoolVector2Array( 859.704, 802.519, 815.717, 612.674, 1172.24, 617.258, 1288.21, 675.24, 1293.86, 815.247, 861.118, 808.176 )
|
||||
|
||||
[node name="r_door" type="Line2D" parent="."]
|
||||
position = Vector2( 0, -267.828 )
|
||||
points = PoolVector2Array( 1175.07, 620.086, 1171.24, 311.267, 1274.8, 356.87, 1278.31, 672.412, 1184.97, 628.571 )
|
||||
|
||||
[node name="bridge" parent="." instance=ExtResource( 2 )]
|
||||
global_id = "r3_bridge"
|
||||
|
||||
[node name="button" type="Sprite" parent="."]
|
||||
script = ExtResource( 4 )
|
||||
global_id = "r3_button"
|
||||
esc_script = "res://game/rooms/room3/esc/button.esc"
|
||||
tooltip_name = "button"
|
||||
dialog_color = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="lines" type="Line2D" parent="button"]
|
||||
position = Vector2( 0, -266.591 )
|
||||
points = PoolVector2Array( 322.305, 390.985, 322.305, 439.068, 368.698, 440.037, 368.974, 392.399, 319.028, 391.549 )
|
||||
|
||||
[node name="Polygon2D" type="Polygon2D" parent="button/lines"]
|
||||
visible = false
|
||||
polygon = PoolVector2Array( 343.993, 396.767, 323.298, 415.689, 344.585, 438.158, 365.872, 417.463 )
|
||||
|
||||
[node name="Particles2D" type="Particles2D" parent="button"]
|
||||
position = Vector2( 344.768, 142.144 )
|
||||
amount = 16
|
||||
lifetime = 4.0
|
||||
preprocess = 1.99
|
||||
speed_scale = 1.39
|
||||
process_material = SubResource( 5 )
|
||||
texture = ExtResource( 3 )
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="button"]
|
||||
anims/button_broken = SubResource( 6 )
|
||||
anims/button_repaired = SubResource( 7 )
|
||||
|
||||
[node name="interact_pos" type="Position2D" parent="button"]
|
||||
position = Vector2( 347.767, 378.011 )
|
||||
|
||||
[node name="area" type="Area2D" parent="button"]
|
||||
|
||||
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="button/area"]
|
||||
polygon = PoolVector2Array( 319.633, 122.126, 320.427, 177.685, 371.224, 176.098, 372.811, 121.332 )
|
||||
53
game/rooms/room3/button.tscn
Normal file
53
game/rooms/room3/button.tscn
Normal file
@@ -0,0 +1,53 @@
|
||||
[gd_scene load_steps=5 format=2]
|
||||
|
||||
[ext_resource path="res://addons/escoria-core/game/core-scripts/eschotspot.gd" type="Script" id=1]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id=1]
|
||||
extents = Vector2( 28.6442, 23.5021 )
|
||||
|
||||
[sub_resource type="Animation" id=2]
|
||||
resource_name = "button_broken"
|
||||
tracks/0/type = "value"
|
||||
tracks/0/path = NodePath("../../background/button/Particles2D:emitting")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ true ]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id=3]
|
||||
resource_name = "button_repaired"
|
||||
tracks/0/type = "value"
|
||||
tracks/0/path = NodePath("../../background/button/Particles2D:emitting")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ false ]
|
||||
}
|
||||
|
||||
[node name="button" type="Area2D"]
|
||||
position = Vector2( 346.18, 151.013 )
|
||||
script = ExtResource( 1 )
|
||||
global_id = "button"
|
||||
esc_script = "res://game/rooms/room3/esc/button.esc"
|
||||
tooltip_name = "Button"
|
||||
dialog_color = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource( 1 )
|
||||
|
||||
[node name="Position2D" type="Position2D" parent="."]
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
anims/button_broken = SubResource( 2 )
|
||||
anims/button_repaired = SubResource( 3 )
|
||||
41
game/rooms/room3/esc/button.esc
Executable file
41
game/rooms/room3/esc/button.esc
Executable file
@@ -0,0 +1,41 @@
|
||||
:look
|
||||
say player "That button must activate the bridge, but it is broken." [button_broken]
|
||||
say player "It should work now." [!button_broken]
|
||||
|
||||
:push
|
||||
say player "I must USE this."
|
||||
|
||||
:use
|
||||
> [!button_broken, !r3_bridge_closed]
|
||||
set_state r3_bridge bridge_close
|
||||
enable_terrain bridge_closed
|
||||
set_global r3_bridge_closed true
|
||||
set_interactive r3_right_platform false
|
||||
stop
|
||||
|
||||
> [!button_broken, r3_bridge_closed]
|
||||
set_state r3_bridge bridge_open
|
||||
enable_terrain bridge_open
|
||||
set_global r3_bridge_closed false
|
||||
set_interactive r3_right_platform true
|
||||
stop
|
||||
|
||||
> [button_broken]
|
||||
say player "The button is broken!"
|
||||
stop
|
||||
|
||||
:talk
|
||||
> [button_broken]
|
||||
say player "Please, will you repair yourself?"
|
||||
wait 2
|
||||
set_state r3_button button_repaired
|
||||
set_global button_broken false
|
||||
wait 2
|
||||
say player "Oh, it worked!"
|
||||
stop
|
||||
> [!button_broken]
|
||||
say player "I should not talk to it again. It could break itself back."
|
||||
|
||||
|
||||
:arrived
|
||||
say player "I am there!"
|
||||
2
game/rooms/room3/esc/left_exit.esc
Normal file
2
game/rooms/room3/esc/left_exit.esc
Normal file
@@ -0,0 +1,2 @@
|
||||
:exit_scene
|
||||
change_scene "res://game/rooms/room2/room2.tscn"
|
||||
2
game/rooms/room3/esc/right_exit.esc
Executable file
2
game/rooms/room3/esc/right_exit.esc
Executable file
@@ -0,0 +1,2 @@
|
||||
:exit_scene
|
||||
change_scene "res://game/rooms/room4/room4.tscn"
|
||||
5
game/rooms/room3/esc/right_platform.esc
Executable file
5
game/rooms/room3/esc/right_platform.esc
Executable file
@@ -0,0 +1,5 @@
|
||||
:look
|
||||
say player "That's the other side."
|
||||
|
||||
:arrived
|
||||
say player "I can't reach it."
|
||||
35
game/rooms/room3/esc/room3_bridge.esc
Normal file
35
game/rooms/room3/esc/room3_bridge.esc
Normal file
@@ -0,0 +1,35 @@
|
||||
# THIS ROOMS FEATURES AN OPEN BRIDGE WITH A ***BROKEN*** BUTTON TO USE IN ORDER TO OPEN
|
||||
|
||||
:setup
|
||||
|
||||
> [r3_bridge_closed]
|
||||
# Make set_state IMMEDIATE to reach the final frame immediately
|
||||
set_state r3_bridge bridge_close true
|
||||
enable_terrain bridge_closed
|
||||
set_interactive r3_right_platform false
|
||||
|
||||
> [eq ESC_LAST_SCENE room2]
|
||||
teleport player r3_l_exit
|
||||
# Set player look right
|
||||
set_angle player 180
|
||||
stop
|
||||
> [eq ESC_LAST_SCENE room4]
|
||||
teleport player r3_r_exit
|
||||
# Set player look left
|
||||
set_angle player 270
|
||||
stop
|
||||
> [!last_scene]
|
||||
teleport player player_start
|
||||
stop
|
||||
|
||||
:ready
|
||||
set_global bridge_closed false
|
||||
set_global button_broken true
|
||||
|
||||
# DEBUG
|
||||
#set_state r3_bridge bridge_close
|
||||
#enable_terrain bridge_closed
|
||||
#set_global bridge_closed true
|
||||
#set_interactive r3_right_platform false
|
||||
## /DEBUG
|
||||
|
||||
81
game/rooms/room3/room3.tscn
Normal file
81
game/rooms/room3/room3.tscn
Normal file
@@ -0,0 +1,81 @@
|
||||
[gd_scene load_steps=6 format=2]
|
||||
|
||||
[ext_resource path="res://game/rooms/room3/walkable_area.tscn" type="PackedScene" id=1]
|
||||
[ext_resource path="res://game/rooms/room3/background.tscn" type="PackedScene" id=2]
|
||||
[ext_resource path="res://addons/escoria-core/game/core-scripts/eschotspot.gd" type="Script" id=3]
|
||||
[ext_resource path="res://game/characters/guybrush/guybrush.tscn" type="PackedScene" id=4]
|
||||
[ext_resource path="res://addons/escoria-core/game/core-scripts/escroom.gd" type="Script" id=6]
|
||||
|
||||
[node name="room3" type="Node2D"]
|
||||
script = ExtResource( 6 )
|
||||
global_id = "room3"
|
||||
esc_script = "res://game/rooms/room3/esc/room3_bridge.esc"
|
||||
player_scene = ExtResource( 4 )
|
||||
|
||||
[node name="background" parent="." instance=ExtResource( 2 )]
|
||||
|
||||
[node name="walkable_area" parent="." instance=ExtResource( 1 )]
|
||||
scales = null
|
||||
bitmaps_scale = Vector2( 1, 1 )
|
||||
lightmap = null
|
||||
player_speed_multiplier = 1.0
|
||||
player_doubleclick_speed_multiplier = 1.5
|
||||
lightmap_modulate = Color( 1, 1, 1, 1 )
|
||||
debug_mode = 1
|
||||
scale_min = 0.3
|
||||
scale_max = 1.0
|
||||
|
||||
[node name="Hotspots" type="Node2D" parent="."]
|
||||
|
||||
[node name="r_platform" type="Area2D" parent="Hotspots"]
|
||||
script = ExtResource( 3 )
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
global_id = "r3_right_platform"
|
||||
esc_script = "res://game/rooms/room3/esc/right_platform.esc"
|
||||
tooltip_name = "Right platform"
|
||||
dialog_color = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="Hotspots/r_platform"]
|
||||
polygon = PoolVector2Array( 870.974, 538.342, 827.536, 353.995, 1181.4, 357.174, 1287.34, 413.325, 1289.46, 545.758 )
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="Position2D" type="Position2D" parent="Hotspots/r_platform"]
|
||||
position = Vector2( 430.893, 451.052 )
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="r_door" type="Area2D" parent="Hotspots"]
|
||||
script = ExtResource( 3 )
|
||||
global_id = "r3_r_exit"
|
||||
is_exit = true
|
||||
esc_script = "res://game/rooms/room3/esc/right_exit.esc"
|
||||
tooltip_name = "Exit"
|
||||
dialog_color = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="Hotspots/r_door"]
|
||||
polygon = PoolVector2Array( 1177.94, 348.61, 1175.95, 45.3759, 1276.06, 92.0953, 1277.95, 399.407 )
|
||||
|
||||
[node name="Position2D" type="Position2D" parent="Hotspots/r_door"]
|
||||
position = Vector2( 1225.47, 353.99 )
|
||||
|
||||
[node name="l_door" type="Area2D" parent="Hotspots"]
|
||||
script = ExtResource( 3 )
|
||||
global_id = "r3_l_exit"
|
||||
is_exit = true
|
||||
esc_script = "res://game/rooms/room3/esc/left_exit.esc"
|
||||
tooltip_name = "Exit"
|
||||
dialog_color = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="Hotspots/l_door"]
|
||||
polygon = PoolVector2Array( -2.71457, 437.818, 6.6293, 121.462, 89.3893, 74.7422, 88.0545, 376.416 )
|
||||
|
||||
[node name="Position2D" type="Position2D" parent="Hotspots/l_door"]
|
||||
position = Vector2( 44.1375, 384.691 )
|
||||
|
||||
[node name="player_start" type="Position2D" parent="."]
|
||||
position = Vector2( 63.3074, 444.653 )
|
||||
BIN
game/rooms/room3/smoke.png
Normal file
BIN
game/rooms/room3/smoke.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
34
game/rooms/room3/smoke.png.import
Normal file
34
game/rooms/room3/smoke.png.import
Normal file
@@ -0,0 +1,34 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/smoke.png-965262514fb8ca3a9976c9f3fd836bb3.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://game/rooms/room3/smoke.png"
|
||||
dest_files=[ "res://.import/smoke.png-965262514fb8ca3a9976c9f3fd836bb3.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
||||
26
game/rooms/room3/walkable_area.tscn
Normal file
26
game/rooms/room3/walkable_area.tscn
Normal file
@@ -0,0 +1,26 @@
|
||||
[gd_scene load_steps=4 format=2]
|
||||
|
||||
[ext_resource path="res://addons/escoria-core/game/core-scripts/escterrain.gd" type="Script" id=1]
|
||||
|
||||
[sub_resource type="NavigationPolygon" id=1]
|
||||
vertices = PoolVector2Array( 129.634, 615.792, 488.56, 617.98, 454.637, 800.726, 2.69714, 805.103, 75.8943, 663.384, 3.79144, 707.712, 5.9538, 653.476, 63.1848, 626.267, 1284.99, 804.433, 868.119, 803.394, 828.615, 621.468, 1152.31, 619.946, 1181.97, 640.075, 1260.04, 615.231, 1282.91, 680.724, 1190.39, 590.281 )
|
||||
polygons = [ PoolIntArray( 0, 1, 2, 3, 4 ), PoolIntArray( 4, 3, 5, 6, 7 ), PoolIntArray( 8, 9, 10, 11, 12 ), PoolIntArray( 13, 14, 8, 12, 15 ) ]
|
||||
outlines = [ PoolVector2Array( 3.79144, 707.712, 5.9538, 653.476, 63.1848, 626.267, 75.8943, 663.384, 129.634, 615.792, 488.56, 617.98, 454.637, 800.726, 2.69714, 805.103 ), PoolVector2Array( 828.615, 621.468, 868.119, 803.394, 1284.99, 804.433, 1282.91, 680.724, 1260.04, 615.231, 1190.39, 590.281, 1181.97, 640.075, 1152.31, 619.946 ) ]
|
||||
|
||||
[sub_resource type="NavigationPolygon" id=2]
|
||||
vertices = PoolVector2Array( 837.638, 649.714, 832.166, 621.263, 1171.4, 624.546, 863.901, 768.992, 129.634, 615.792, 488.56, 617.98, 484.183, 645.337, 462.297, 766.803, 454.637, 800.726, 85.8629, 647.526, 1265.5, 615.792, 1281.92, 680.354, 1290.67, 816.046, 877.032, 800.726, 2.69714, 805.103, 3.79144, 707.712, 13.64, 663.94, 55.2229, 643.149, 1199.85, 607.037 )
|
||||
polygons = [ PoolIntArray( 0, 1, 2, 3 ), PoolIntArray( 4, 5, 6, 7, 8, 9 ), PoolIntArray( 10, 11, 12, 13, 3, 2 ), PoolIntArray( 8, 14, 15, 16, 17, 9 ), PoolIntArray( 3, 7, 6, 0 ), PoolIntArray( 10, 2, 18 ) ]
|
||||
outlines = [ PoolVector2Array( 3.79144, 707.712, 13.64, 663.94, 55.2229, 643.149, 85.8629, 647.526, 129.634, 615.792, 488.56, 617.98, 484.183, 645.337, 837.638, 649.714, 832.166, 621.263, 1171.4, 624.546, 1199.85, 607.037, 1265.5, 615.792, 1281.92, 680.354, 1290.67, 816.046, 877.032, 800.726, 863.901, 768.992, 462.297, 766.803, 454.637, 800.726, 2.69714, 805.103 ) ]
|
||||
|
||||
[node name="walkable_area" type="Navigation2D"]
|
||||
script = ExtResource( 1 )
|
||||
|
||||
[node name="bridge_open" type="NavigationPolygonInstance" parent="."]
|
||||
position = Vector2( 6.73163, -264.779 )
|
||||
navpoly = SubResource( 1 )
|
||||
|
||||
[node name="bridge_closed" type="NavigationPolygonInstance" parent="."]
|
||||
visible = false
|
||||
position = Vector2( 0, -269.266 )
|
||||
navpoly = SubResource( 2 )
|
||||
enabled = false
|
||||
Reference in New Issue
Block a user