Updated rover game with everything it needs

This commit is contained in:
akshay 2022-08-21 15:32:47 -04:00
parent 79f41e7a41
commit 23dfc3bb72
16 changed files with 35 additions and 119 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,6 +1,7 @@
[gd_scene load_steps=13 format=2]
[gd_scene load_steps=14 format=2]
[ext_resource path="res://scenes/rover.tscn" type="PackedScene" id=1]
[ext_resource path="res://assets/UI/Timers.png" type="Texture" id=2]
[ext_resource path="res://assets/rover_level/RoverGame.glb" type="PackedScene" id=4]
[ext_resource path="res://scripts/rover_camera.gd" type="Script" id=5]
[ext_resource path="res://scripts/rover_game.gd" type="Script" id=6]
@ -8,7 +9,7 @@
[ext_resource path="res://assets/rover_level/Arrow_MAT.tres" type="Material" id=9]
[sub_resource type="BoxShape" id=7]
extents = Vector3( 2.00704, 1, 1 )
extents = Vector3( 3.5, 2, 1 )
[sub_resource type="Environment" id=5]
background_mode = 2
@ -46,7 +47,7 @@ surfaces/0 = {
[node name="rover_game" type="Spatial"]
script = ExtResource( 6 )
play_time = 45.0
play_time = 25.0
arrow_viz_distance = 15.0
geode_loot_count_per_chance = {
1: 40,
@ -58,7 +59,7 @@ __meta__ = {
"_edit_group_": true
}
[node name="Arrow" parent="RoverGame" index="7"]
[node name="Arrow001" parent="RoverGame" index="56"]
visible = false
[node name="rover" parent="." instance=ExtResource( 1 )]
@ -76,7 +77,7 @@ current = true
script = ExtResource( 5 )
[node name="collection_area" type="Area" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -2.988 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.95935, -2.988 )
collision_layer = 0
collision_mask = 32
@ -99,6 +100,7 @@ one_shot = true
autostart = true
[node name="UI" type="CanvasLayer" parent="."]
layer = 10
[node name="Control" type="Control" parent="UI"]
anchor_right = 1.0
@ -106,13 +108,29 @@ anchor_bottom = 1.0
[node name="progress_bar" type="ProgressBar" parent="UI/Control"]
unique_name_in_owner = true
anchor_left = 0.295312
anchor_right = 0.704687
anchor_bottom = 0.0398148
anchor_left = 1.0
anchor_top = 1.0
anchor_right = 1.0
anchor_bottom = 1.0
margin_left = -49.0
margin_top = 4.0
margin_right = 681.0
margin_bottom = 47.0
rect_rotation = -90.0
rect_pivot_offset = Vector2( 1.0874, -4 )
custom_colors/font_color = Color( 0, 0, 0, 0 )
custom_styles/fg = SubResource( 12 )
custom_styles/bg = SubResource( 13 )
value = 75.0
[node name="HUD" type="TextureRect" parent="UI/Control"]
visible = false
anchor_left = 0.610937
anchor_top = -0.00740741
anchor_right = 1.0
anchor_bottom = 0.126852
texture = ExtResource( 2 )
expand = true
__meta__ = {
"_edit_use_anchors_": true
}
@ -120,137 +138,35 @@ __meta__ = {
[node name="spawn locations" type="Spatial" parent="."]
[node name="spawn_location" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 72.8999 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -13.8043, 0, 40.6835 )
[node name="spawn_location2" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -14.1474, 0, 86.0569 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -27.9517, 0, 53.8405 )
[node name="spawn_location3" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 18.2501, 0, 95.3941 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 4.44575, 0, 63.1777 )
[node name="spawn_location4" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -0.749908, 0, 103.394 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -14.5543, 0, 71.1776 )
[node name="spawn_location5" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 15.2501, 0, 78.3941 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 1.44575, 0, 46.1777 )
[node name="spawn_location6" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 17.7966, 0, 55.7584 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 3.99225, 0, 23.542 )
[node name="spawn_location7" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -23.0892, 0, 38.7815 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -22.1687, 0, 17.8606 )
[node name="spawn_location8" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -23.0892, 0, 38.7815 )
[node name="spawn_location9" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 9.46336, 0, 135.092 )
[node name="spawn_location10" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0.483337, 0, 158.441 )
[node name="spawn_location11" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 19.4833, 0, 182.441 )
[node name="spawn_location12" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -22.4983, 0, 220.83 )
[node name="spawn_location13" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 5.50166, 0, 220.83 )
[node name="spawn_location14" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -18.9689, 0, 237.892 )
[node name="spawn_location15" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -7.7439, 0, 291.772 )
[node name="spawn_location16" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 22.1147, 0, 283.915 )
[node name="spawn_location17" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 27.9517, 0, 325.897 )
[node name="spawn_location18" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 13.1347, 0, 352.388 )
[node name="spawn_location19" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -17.1729, 0, 361.368 )
[node name="spawn_location20" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -4.60088, 0, 378.654 )
[node name="spawn_location21" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 17.6247, 0, 374.164 )
[node name="spawn_location22" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 17.6247, 0, 374.164 )
[node name="spawn_location23" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -9.0909, 0, 404.921 )
[node name="spawn_location24" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -22.7855, 0, 420.86 )
[node name="spawn_location25" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -14.4789, 0, 436.351 )
[node name="spawn_location26" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -1.00888, 0, 453.862 )
[node name="spawn_location27" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 6.17516, 0, 438.147 )
[node name="spawn_location28" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 21.2167, 0, 457.005 )
[node name="spawn_location29" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 15.6042, 0, 469.802 )
[node name="spawn_location30" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 25.0332, 0, 496.517 )
[node name="spawn_location31" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 9.99167, 0, 513.355 )
[node name="spawn_location32" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -18.0709, 0, 527.049 )
[node name="spawn_location33" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -20.0709, 0, 545.049 )
[node name="spawn_location34" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -20.0709, 0, 545.049 )
[node name="spawn_location35" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 30.2172, 0, 526.865 )
[node name="spawn_location36" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 13.2172, 0, 528.865 )
[node name="spawn_location37" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -17.0904, 0, 605.195 )
[node name="spawn_location38" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -0.701813, 0, 602.725 )
[node name="spawn_location39" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 15.0132, 0, 626.747 )
[node name="spawn_location40" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 24.8913, 0, 643.585 )
[node name="spawn_location41" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 15.0132, 0, 664.688 )
[node name="spawn_location42" type="Position3D" parent="spawn locations" groups=["rock_spawn_location"]]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 17.4828, 0, 603.399 )
[node name="DirectionalLight" type="DirectionalLight" parent="."]
transform = Transform( 0.866025, 2.18557e-08, -0.5, 0.5, -3.78552e-08, 0.866025, 0, -1, -4.37114e-08, 0, 87.952, 53 )
shadow_enabled = true
[node name="exit_trigger" type="Area" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1.25529, 0, 0.225982, -7.17776 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1.25529, 0, 0.225982, -4.96855 )
collision_layer = 64
collision_mask = 2

View File

@ -21,7 +21,7 @@ var loot_table : SimpleLootTable = null
func _ready():
loot_table = LootTable.new(geode_loot_count_per_chance)
timer.start(play_time)
spawn_rocks(10)
spawn_rocks(4)
func spawn_rocks(count: int):
var locations: Array = get_tree().get_nodes_in_group("rock_spawn_location")