Quellcode durchsuchen

Merge branch 'max' into Henrik

Henrik
Pixdigit vor 4 Monaten
Ursprung
Commit
941bef0fe1
  1. BIN
      assets/models/pirate/Pirate_AO.png
  2. 36
      assets/models/pirate/Pirate_AO.png.import
  3. BIN
      assets/models/pirate/Pirate_BaseColor.png
  4. 36
      assets/models/pirate/Pirate_BaseColor.png.import
  5. BIN
      assets/models/pirate/Pirate_Metallic.png
  6. 36
      assets/models/pirate/Pirate_Metallic.png.import
  7. BIN
      assets/models/pirate/Pirate_Normal.png
  8. 36
      assets/models/pirate/Pirate_Normal.png.import
  9. BIN
      assets/models/pirate/Pirate_Roughness.png
  10. 36
      assets/models/pirate/Pirate_Roughness.png.import
  11. 613
      assets/models/pirate/pirate_export-2.escn
  12. 1063
      assets/models/pirate/pirate_export-2.escn.import
  13. BIN
      assets/models/seagull/mads 4.material
  14. BIN
      assets/models/seagull/mads 1.material
  15. BIN
      assets/models/seagull/mads 2.material
  16. BIN
      assets/models/seagull/mads 3.material
  17. 451
      assets/models/seagull/seagull.escn
  18. 1063
      assets/models/seagull/seagull.escn.import
  19. 8
      scenes/Ship.tscn
  20. 14
      scenes/sub_scenes/Seagull.tscn
  21. 26
      scenes/sub_scenes/pirate_export-2.tscn
  22. 19
      scenes/sub_scenes/plants/plant_canon_export_Actions.tscn
  23. 22
      scenes/sub_scenes/plants/plant_engine_export_left_fixed.tscn
  24. 83
      scenes/sub_scenes/player.tscn
  25. 5
      scenes/sub_scenes/seagull_inherit.tscn
  26. 4
      src/State.gd

BIN
assets/models/pirate/Pirate_AO.png

Nachher

Breite: 2048  |  Höhe: 2048  |  Größe: 1.9 MiB

36
assets/models/pirate/Pirate_AO.png.import

@ -0,0 +1,36 @@
[remap]
importer="texture"
type="StreamTexture"
path.s3tc="res://.import/Pirate_AO.png-84824729e3be864f4c7965af31b861e7.s3tc.stex"
path.etc2="res://.import/Pirate_AO.png-84824729e3be864f4c7965af31b861e7.etc2.stex"
metadata={
"imported_formats": [ "s3tc", "etc2" ],
"vram_texture": true
}
[deps]
source_file="res://assets/models/pirate/Pirate_AO.png"
dest_files=[ "res://.import/Pirate_AO.png-84824729e3be864f4c7965af31b861e7.s3tc.stex", "res://.import/Pirate_AO.png-84824729e3be864f4c7965af31b861e7.etc2.stex" ]
[params]
compress/mode=2
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=true
flags/filter=true
flags/mipmaps=true
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=false
svg/scale=1.0

BIN
assets/models/pirate/Pirate_BaseColor.png

Nachher

Breite: 2048  |  Höhe: 2048  |  Größe: 1.3 MiB

36
assets/models/pirate/Pirate_BaseColor.png.import

@ -0,0 +1,36 @@
[remap]
importer="texture"
type="StreamTexture"
path.s3tc="res://.import/Pirate_BaseColor.png-a8e824de49594160b1a3d3f63bb61ef8.s3tc.stex"
path.etc2="res://.import/Pirate_BaseColor.png-a8e824de49594160b1a3d3f63bb61ef8.etc2.stex"
metadata={
"imported_formats": [ "s3tc", "etc2" ],
"vram_texture": true
}
[deps]
source_file="res://assets/models/pirate/Pirate_BaseColor.png"
dest_files=[ "res://.import/Pirate_BaseColor.png-a8e824de49594160b1a3d3f63bb61ef8.s3tc.stex", "res://.import/Pirate_BaseColor.png-a8e824de49594160b1a3d3f63bb61ef8.etc2.stex" ]
[params]
compress/mode=2
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=true
flags/filter=true
flags/mipmaps=true
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=false
svg/scale=1.0

BIN
assets/models/pirate/Pirate_Metallic.png

Nachher

Breite: 2048  |  Höhe: 2048  |  Größe: 21 KiB

36
assets/models/pirate/Pirate_Metallic.png.import

@ -0,0 +1,36 @@
[remap]
importer="texture"
type="StreamTexture"
path.s3tc="res://.import/Pirate_Metallic.png-dfa426ce066c40b677ff3f5ff0c99cf4.s3tc.stex"
path.etc2="res://.import/Pirate_Metallic.png-dfa426ce066c40b677ff3f5ff0c99cf4.etc2.stex"
metadata={
"imported_formats": [ "s3tc", "etc2" ],
"vram_texture": true
}
[deps]
source_file="res://assets/models/pirate/Pirate_Metallic.png"
dest_files=[ "res://.import/Pirate_Metallic.png-dfa426ce066c40b677ff3f5ff0c99cf4.s3tc.stex", "res://.import/Pirate_Metallic.png-dfa426ce066c40b677ff3f5ff0c99cf4.etc2.stex" ]
[params]
compress/mode=2
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=true
flags/filter=true
flags/mipmaps=true
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=false
svg/scale=1.0

BIN
assets/models/pirate/Pirate_Normal.png

Nachher

Breite: 2048  |  Höhe: 2048  |  Größe: 3.8 MiB

36
assets/models/pirate/Pirate_Normal.png.import

@ -0,0 +1,36 @@
[remap]
importer="texture"
type="StreamTexture"
path.s3tc="res://.import/Pirate_Normal.png-46f478743ec84d92f59a2d71aaa3f3e6.s3tc.stex"
path.etc2="res://.import/Pirate_Normal.png-46f478743ec84d92f59a2d71aaa3f3e6.etc2.stex"
metadata={
"imported_formats": [ "s3tc", "etc2" ],
"vram_texture": true
}
[deps]
source_file="res://assets/models/pirate/Pirate_Normal.png"
dest_files=[ "res://.import/Pirate_Normal.png-46f478743ec84d92f59a2d71aaa3f3e6.s3tc.stex", "res://.import/Pirate_Normal.png-46f478743ec84d92f59a2d71aaa3f3e6.etc2.stex" ]
[params]
compress/mode=2
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=1
flags/repeat=true
flags/filter=true
flags/mipmaps=true
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=false
svg/scale=1.0

BIN
assets/models/pirate/Pirate_Roughness.png

Nachher

Breite: 2048  |  Höhe: 2048  |  Größe: 234 KiB

36
assets/models/pirate/Pirate_Roughness.png.import

@ -0,0 +1,36 @@
[remap]
importer="texture"
type="StreamTexture"
path.s3tc="res://.import/Pirate_Roughness.png-6103d6898ae1fb0d8eeed52d39cd91fc.s3tc.stex"
path.etc2="res://.import/Pirate_Roughness.png-6103d6898ae1fb0d8eeed52d39cd91fc.etc2.stex"
metadata={
"imported_formats": [ "s3tc", "etc2" ],
"vram_texture": true
}
[deps]
source_file="res://assets/models/pirate/Pirate_Roughness.png"
dest_files=[ "res://.import/Pirate_Roughness.png-6103d6898ae1fb0d8eeed52d39cd91fc.s3tc.stex", "res://.import/Pirate_Roughness.png-6103d6898ae1fb0d8eeed52d39cd91fc.etc2.stex" ]
[params]
compress/mode=2
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=true
flags/filter=true
flags/mipmaps=true
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=false
svg/scale=1.0

613
assets/models/pirate/pirate_export-2.escn
Datei-Diff unterdrückt, da er zu groß ist
Datei anzeigen

1063
assets/models/pirate/pirate_export-2.escn.import
Datei-Diff unterdrückt, da er zu groß ist
Datei anzeigen

BIN
assets/models/seagull/mads 4.material

BIN
assets/models/seagull/mads 1.material

BIN
assets/models/seagull/mads 2.material

BIN
assets/models/seagull/mads 3.material

451
assets/models/seagull/seagull.escn
Datei-Diff unterdrückt, da er zu groß ist
Datei anzeigen

1063
assets/models/seagull/seagull.escn.import
Datei-Diff unterdrückt, da er zu groß ist
Datei anzeigen

8
scenes/Ship.tscn

@ -176,7 +176,7 @@ height = 0.1
[sub_resource type="BoxShape" id=25]
extents = Vector3( 0.8, 2.16543, 0.8 )
[sub_resource type="Animation" id=34]
[sub_resource type="Animation" id=26]
resource_name = "New Anim"
length = 10.0
loop = true
@ -460,7 +460,7 @@ transform = Transform( -0.747961, 0, 0.663739, 0, 1, 0, -0.663739, 0, -0.747961,
[node name="AnimationPlayer2" type="AnimationPlayer" parent="SeagullOrbit"]
autoplay = "New Anim"
"anims/New Anim" = SubResource( 34 )
"anims/New Anim" = SubResource( 26 )
[node name="WaterDetector" type="Area" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -9.99335, 9.65661, -0.110578 )
@ -556,7 +556,7 @@ type = 4
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 2.5, 0, 0 )
[node name="Quad2" type="Spatial" parent="Plants"]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 2, 8, 4.221 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 2, 8.03608, 4.221 )
[node name="satzkasten" parent="Plants/Quad2" instance=ExtResource( 4 )]
@ -588,7 +588,7 @@ transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 2.5, 0, 0 )
type = 4
[node name="Quad4" type="Spatial" parent="Plants"]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 2, 8, -7.277 )
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 2, 8.03608, -7.277 )
[node name="satzkasten" parent="Plants/Quad4" instance=ExtResource( 4 )]
type = 4

14
scenes/sub_scenes/Seagull.tscn

@ -5,10 +5,9 @@
[ext_resource path="res://assets/sound/Gulls/Seagulls_02_mono.ogg" type="AudioStream" id=3]
[ext_resource path="res://assets/sound/Gulls/Seagulls_03_mono.ogg" type="AudioStream" id=4]
[ext_resource path="res://addons/randomAudioStreamPlayer/random_audio_stream_player_3D.gd" type="Script" id=5]
[ext_resource path="res://scenes/sub_scenes/seagull_inherit.tscn" type="PackedScene" id=6]
[sub_resource type="CapsuleMesh" id=1]
[sub_resource type="GDScript" id=2]
[sub_resource type="GDScript" id=1]
script/source = "extends Timer
@ -22,15 +21,13 @@ func _on_timeout():
start(State.rng.randf_range(3.0, 6.0))
"
[node name="Gull Dummy" type="MeshInstance"]
[node name="Gull Dummy" type="Spatial"]
transform = Transform( 0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.7, 15, 0, 0 )
mesh = SubResource( 1 )
material/0 = null
[node name="Timer" type="Timer" parent="."]
wait_time = 3.0
autostart = true
script = SubResource( 2 )
script = SubResource( 1 )
[node name="RandomAudioStreamPlayer3D" type="AudioStreamPlayer3D" parent="."]
bus = "Seagull"
@ -43,4 +40,7 @@ volume_max = 10.0
randomize_pitch = false
pitch_min = 1.0
pitch_max = 1.0
[node name="seagull" parent="." instance=ExtResource( 6 )]
transform = Transform( 1.7534, -0.962069, 0, 0.962069, 1.7534, 0, 0, 0, 2, 0, 0, 0 )
[connection signal="timeout" from="Timer" to="Timer" method="_on_timeout"]

26
scenes/sub_scenes/pirate_export-2.tscn

@ -0,0 +1,26 @@
[gd_scene load_steps=3 format=2]
[ext_resource path="res://assets/models/pirate/pirate_export-2.escn" type="PackedScene" id=1]
[sub_resource type="GDScript" id=1]
script/source = "extends Spatial
func _ready():
var child2 = get_node(\"AnimationPlayer\")
var anim_name = child2.get_animation_list()[0]
var anim = child2.get_animation(anim_name)
anim.length = 1.3333333
anim.loop = true
child2.add_animation(\"anim\", anim)
child2.current_animation = \"anim\"
child2.play()
"
[node name="pirate_export-2" instance=ExtResource( 1 )]
script = SubResource( 1 )
[node name="Bone016BoneAttachment" parent="Armature" index="1"]
transform = Transform( 1, 2.38419e-07, -1.04794e-13, 1.77636e-15, 0, -1, -2.38419e-07, 1, 0, 2.7195e-14, 4.58208, -1.49384e-06 )

19
scenes/sub_scenes/plants/plant_canon_export_Actions.tscn

@ -1,6 +1,23 @@
[gd_scene load_steps=2 format=2]
[gd_scene load_steps=3 format=2]
[ext_resource path="res://assets/models/plants/canon/plant_canon_export_Actions.escn" type="PackedScene" id=1]
[sub_resource type="GDScript" id=1]
script/source = "extends Spatial
func _ready():
var child2 = get_node(\"AnimationPlayer\")
var anim_name = child2.get_animation_list()[1]
var anim = child2.get_animation(anim_name)
anim.length = 1.3333333
anim.loop = true
child2.add_animation(\"anim\", anim)
child2.current_animation = \"anim\"
child2.play()
"
[node name="plant_canon_export_Actions" instance=ExtResource( 1 )]
transform = Transform( 0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.5, 0, 0, 0 )
script = SubResource( 1 )

22
scenes/sub_scenes/plants/plant_engine_export_left_fixed.tscn

@ -1,5 +1,25 @@
[gd_scene load_steps=2 format=2]
[gd_scene load_steps=3 format=2]
[ext_resource path="res://assets/models/plants/engine/plant_engine_export_left_fixed.escn" type="PackedScene" id=1]
[sub_resource type="GDScript" id=1]
script/source = "extends Spatial
func _ready():
var child2 = get_node(\"AnimationPlayer\")
var anim_name = child2.get_animation_list()[0]
var anim = child2.get_animation(anim_name)
anim.loop = true
anim.length = 1.3333333
child2.add_animation(\"anim\", anim)
child2.current_animation = \"anim\"
child2.play()
"
[node name="plant_engine_export_left_fixed" instance=ExtResource( 1 )]
script = SubResource( 1 )
[node name="AnimationPlayer" parent="." index="1"]
autoplay = "Antenna_1_RigAction.001"

83
scenes/sub_scenes/player.tscn

@ -1,4 +1,4 @@
[gd_scene load_steps=13 format=2]
[gd_scene load_steps=12 format=2]
[ext_resource path="res://addons/randomAudioStreamPlayer/random_audio_stream_player_3D.gd" type="Script" id=1]
[ext_resource path="res://assets/sound/Steps/Metal_Footstep_02_mono.ogg" type="AudioStream" id=2]
@ -6,6 +6,8 @@
[ext_resource path="res://assets/sound/Steps/Metal_Footstep_03_mono.ogg" type="AudioStream" id=4]
[ext_resource path="res://scenes/sub_scenes/fertilizer_logo.tscn" type="PackedScene" id=5]
[ext_resource path="res://scenes/sub_scenes/water_logo.tscn" type="PackedScene" id=6]
[ext_resource path="res://scenes/sub_scenes/pirate_export-2.tscn" type="PackedScene" id=7]
[ext_resource path="res://scenes/sub_scenes/plants/plant_seedling_export.tscn" type="PackedScene" id=8]
[sub_resource type="GDScript" id=1]
script/source = "extends KinematicBody
@ -21,9 +23,9 @@ var gravity : Vector3 = Vector3(0,-0.9,0)
onready var audio = get_node(\"RandomAudioStreamPlayer3D\")
onready var stepTimer = get_node(\"Timer\")
onready var mesh = get_node(\"MeshInstance\")
onready var fertilizer_logo = get_node(\"FertilizerLogo\")
onready var water_logo = get_node(\"WaterLogo\")
#onready var seed_logo = get_node(\"SeedLogo\")
onready var fertilizer_logo = find_node(\"FertilizerLogo\")
onready var water_logo = find_node(\"WaterLogo\")
onready var seed_logo = find_node(\"SeedLogo\")
func _ready():
var err = State.connect(\"item_changed\", self, \"_on_item_changed\")
@ -32,13 +34,14 @@ func _ready():
func _on_item_changed():
water_logo.visible = false
fertilizer_logo.visible = false
seed_logo.visible = false
if State.player_inventory == State.ITEM.WATER:
water_logo.visible = true
elif State.player_inventory == State.ITEM.FERTILIZER:
fertilizer_logo.visible = true
elif State.player_inventory == State.ITEM.SEED:
pass # TODO seed_logo.visible = true
seed_logo.visible = true
func _physics_process(_delta):
@ -95,19 +98,26 @@ func smoothRotating(rot : float):
mesh.rotation_degrees.y = rad2deg(targetRotation)
"
[sub_resource type="CapsuleMesh" id=2]
mid_height = 2.0
[sub_resource type="SpatialMaterial" id=3]
albedo_color = Color( 0.760784, 0.576471, 0.4, 1 )
[sub_resource type="SphereMesh" id=4]
[sub_resource type="SpatialMaterial" id=5]
albedo_color = Color( 0.968627, 0.282353, 0.282353, 1 )
[sub_resource type="CapsuleShape" id=6]
height = 2.0
[sub_resource type="CylinderShape" id=2]
radius = 0.925012
height = 3.19668
[sub_resource type="Animation" id=3]
resource_name = "New Anim"
length = 1.5
loop = true
tracks/0/type = "value"
tracks/0/path = NodePath(".:rotation_degrees")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 1.5 ),
"transitions": PoolRealArray( 1, 1 ),
"update": 0,
"values": [ Vector3( 0, 0, 0 ), Vector3( 0, 360, 0 ) ]
}
[node name="Player" type="KinematicBody"]
script = SubResource( 1 )
@ -115,19 +125,11 @@ __meta__ = {
"_edit_group_": true
}
[node name="MeshInstance" type="MeshInstance" parent="."]
transform = Transform( 1, 0, 0, 0, -1.62921e-07, -1, 0, 1, -1.62921e-07, 0, 0, 0 )
mesh = SubResource( 2 )
material/0 = SubResource( 3 )
[node name="MeshInstance" type="MeshInstance" parent="MeshInstance"]
transform = Transform( 0.2, 0, 0, 0, 0.2, 0, 0, 0, 0.2, 0, 1.08105, -0.750059 )
mesh = SubResource( 4 )
material/0 = SubResource( 5 )
[node name="MeshInstance" parent="." instance=ExtResource( 7 )]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -1.70661, 0 )
[node name="CollisionShape" type="CollisionShape" parent="."]
transform = Transform( 1, 0, 0, 0, -1.62921e-07, -1, 0, 1, -1.62921e-07, 0, 0, 0 )
shape = SubResource( 6 )
shape = SubResource( 2 )
[node name="Timer" type="Timer" parent="."]
wait_time = 0.3
@ -145,19 +147,24 @@ randomize_pitch = false
pitch_min = 1.0
pitch_max = 1.0
[node name="FertilizerLogo" parent="." instance=ExtResource( 5 )]
[node name="Listener" type="Listener" parent="."]
[node name="Spatial" type="Spatial" parent="."]
transform = Transform( 0.953008, 0, -0.302946, 0, 1, 0, 0.302946, 0, 0.953008, 0, 0, 0 )
[node name="AnimationPlayer" type="AnimationPlayer" parent="Spatial"]
autoplay = "New Anim"
"anims/New Anim" = SubResource( 3 )
[node name="FertilizerLogo" parent="Spatial" instance=ExtResource( 5 )]
transform = Transform( 0.41941, 0, 0.907797, 0, 1, 0, -0.907797, 0, 0.41941, 0, 3, 0 )
visible = false
[node name="AnimationPlayer" type="AnimationPlayer" parent="FertilizerLogo"]
autoplay = "rotate"
[node name="WaterLogo" parent="." instance=ExtResource( 6 )]
[node name="WaterLogo" parent="Spatial" instance=ExtResource( 6 )]
transform = Transform( 0.901675, 0, -0.432413, 0, 1, 0, 0.432413, 0, 0.901675, 0, 3, 0 )
visible = false
[node name="AnimationPlayer2" type="AnimationPlayer" parent="WaterLogo"]
autoplay = "rotate"
[node name="Listener" type="Listener" parent="."]
[node name="SeedLogo" parent="Spatial" instance=ExtResource( 8 )]
transform = Transform( -0.978147, 0, -0.207916, 0, 1, 0, 0.207916, 0, -0.978147, 0, 2.17165, 0 )
visible = false
[connection signal="timeout" from="Timer" to="." method="_on_Timer_timeout"]

5
scenes/sub_scenes/seagull_inherit.tscn

@ -0,0 +1,5 @@
[gd_scene load_steps=2 format=2]
[ext_resource path="res://assets/models/seagull/seagull.escn" type="PackedScene" id=1]
[node name="seagull" instance=ExtResource( 1 )]

4
src/State.gd

@ -31,8 +31,8 @@ enum ITEM {
var rng: RandomNumberGenerator = RandomNumberGenerator.new()
var o2: float = 1
var o2_drain: float = 0.005
var o2_gain: float = 0.001
var o2_drain: float = 0.003
var o2_gain: float = 0.0006
var selected_plant: Spatial = null
var player_inventory: int = ITEM.EMPTY setget set_item

Laden…
Abbrechen
Speichern