diff --git a/assets/enemy/flyer-sheet.png b/assets/enemy/flyer-sheet.png new file mode 100644 index 0000000..08bebdf Binary files /dev/null and b/assets/enemy/flyer-sheet.png differ diff --git a/assets/enemy/flyer-sheet.png.import b/assets/enemy/flyer-sheet.png.import new file mode 100644 index 0000000..c7aa0e9 --- /dev/null +++ b/assets/enemy/flyer-sheet.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/flyer-sheet.png-543050397164a3f085ca5e0b208e6144.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/enemy/flyer-sheet.png" +dest_files=[ "res://.import/flyer-sheet.png-543050397164a3f085ca5e0b208e6144.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=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=false +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/assets/enemy/flyer.png b/assets/enemy/flyer.png new file mode 100644 index 0000000..9abeeb5 Binary files /dev/null and b/assets/enemy/flyer.png differ diff --git a/assets/enemy/flyer.png.import b/assets/enemy/flyer.png.import new file mode 100644 index 0000000..70f562c --- /dev/null +++ b/assets/enemy/flyer.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/flyer.png-2e4ed4bda6763939f03a619863c6a2a4.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/enemy/flyer.png" +dest_files=[ "res://.import/flyer.png-2e4ed4bda6763939f03a619863c6a2a4.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=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=false +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/assets/enemy/flyer1.png b/assets/enemy/flyer1.png new file mode 100644 index 0000000..4447450 Binary files /dev/null and b/assets/enemy/flyer1.png differ diff --git a/assets/enemy/flyer1.png.import b/assets/enemy/flyer1.png.import new file mode 100644 index 0000000..d0f0dac --- /dev/null +++ b/assets/enemy/flyer1.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/flyer1.png-eb593d700dc57909bdc60de141938bd1.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/enemy/flyer1.png" +dest_files=[ "res://.import/flyer1.png-eb593d700dc57909bdc60de141938bd1.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=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=false +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/assets/enemy/flyer2.png b/assets/enemy/flyer2.png new file mode 100644 index 0000000..0f2f027 Binary files /dev/null and b/assets/enemy/flyer2.png differ diff --git a/assets/enemy/flyer2.png.import b/assets/enemy/flyer2.png.import new file mode 100644 index 0000000..2b9bd30 --- /dev/null +++ b/assets/enemy/flyer2.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/flyer2.png-9b4714dc632c2046dfa1b24ec4f57963.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/enemy/flyer2.png" +dest_files=[ "res://.import/flyer2.png-9b4714dc632c2046dfa1b24ec4f57963.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=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=false +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/src/Actors/Blobby/Blobby.gd b/src/Actors/Blobby/Blobby.gd index 663620f..5a82779 100644 --- a/src/Actors/Blobby/Blobby.gd +++ b/src/Actors/Blobby/Blobby.gd @@ -274,7 +274,7 @@ func calculate_jump_velocity( linear_velocity.y += _gravity * delta # TODO This poop too - if -4 < velocity.x and velocity.x < 4: + if -20 < velocity.x and velocity.x < 20: linear_velocity.x += inair_velocity * direction.x if is_correct_airstrafe_input(): @@ -293,7 +293,7 @@ func calculate_fall_velocity( ) else: linear_velocity.y = max_velocity["fall"] - if -4 < velocity.x and velocity.x < 4: + if -10 < velocity.x and velocity.x < 10: # TODO This is poop linear_velocity.x += inair_velocity * direction.x if Input.is_action_just_pressed("jump"): diff --git a/src/Actors/Blobby/Blobby.tscn b/src/Actors/Blobby/Blobby.tscn index 9cbfe1c..a978df6 100644 --- a/src/Actors/Blobby/Blobby.tscn +++ b/src/Actors/Blobby/Blobby.tscn @@ -1,9 +1,11 @@ -[gd_scene load_steps=115 format=2] +[gd_scene load_steps=117 format=2] [ext_resource path="res://assets/blobby/blobby-effects-spritesheet.png" type="Texture" id=1] +[ext_resource path="res://src/Environment/LightingShaderMaterial.tres" type="Material" id=2] [ext_resource path="res://src/Actors/Blobby/BlobbyStateMachine.gd" type="Script" id=3] [ext_resource path="res://src/Actors/Blobby/Blobby.gd" type="Script" id=4] [ext_resource path="res://assets/meta/new_dynamicfont.tres" type="DynamicFont" id=5] +[ext_resource path="res://src/ThirdParty/Demo/IridescenceBall.tscn" type="PackedScene" id=6] [sub_resource type="RectangleShape2D" id=2] extents = Vector2( 14.9127, 5.98593 ) @@ -4475,6 +4477,7 @@ tracks/2/keys = { } [node name="Blobby" type="KinematicBody2D" groups=["player"]] +material = ExtResource( 2 ) collision_mask = 248 collision/safe_margin = 0.001 script = ExtResource( 4 ) @@ -4505,6 +4508,13 @@ position = Vector2( 0.0286326, -10.0053 ) scale = Vector2( 1.03, 1.04 ) shape = SubResource( 2 ) +[node name="BubbleShieldViewport" type="Viewport" parent="."] +unique_name_in_owner = true +size = Vector2( 128, 128 ) +transparent_bg = true + +[node name="IridescenceBall" parent="BubbleShieldViewport" instance=ExtResource( 6 )] + [node name="BlobbySprite" type="Sprite" parent="."] position = Vector2( 0, -16 ) scale = Vector2( -1, 1 ) @@ -4588,22 +4598,18 @@ offset = Vector2( 4, 0 ) hframes = 10 frame = 8 +[node name="Blobby3DEffects" type="Sprite" parent="."] +unique_name_in_owner = true +position = Vector2( 0, -9 ) +scale = Vector2( 0.48, 0.48 ) +z_index = 1 + [node name="BlobbyBody" type="CollisionShape2D" parent="." groups=["player"]] position = Vector2( 0.0392303, -10.002 ) shape = SubResource( 1 ) -[node name="BlobbyStateMachine" type="Node" parent="."] -script = ExtResource( 3 ) - -[node name="JumpBufferTimer" type="Timer" parent="BlobbyStateMachine"] -wait_time = 0.067 -one_shot = true - -[node name="CoyoteTimer" type="Timer" parent="BlobbyStateMachine"] -wait_time = 0.067 -one_shot = true - [node name="WallRaycasts" type="Node2D" parent="."] +visible = false position = Vector2( 0, -1 ) [node name="LeftWallRaycast" type="Node2D" parent="WallRaycasts"] @@ -4657,6 +4663,17 @@ enabled = true cast_to = Vector2( 0, 24 ) collision_mask = 8 +[node name="BlobbyStateMachine" type="Node" parent="."] +script = ExtResource( 3 ) + +[node name="JumpBufferTimer" type="Timer" parent="BlobbyStateMachine"] +wait_time = 0.067 +one_shot = true + +[node name="CoyoteTimer" type="Timer" parent="BlobbyStateMachine"] +wait_time = 0.067 +one_shot = true + [connection signal="area_entered" from="BlobbySkin" to="." method="_on_BlobbySkin_area_entered"] [connection signal="body_entered" from="BlobbySkin" to="." method="_on_BlobbySkin_body_entered"] [connection signal="got_grounded" from="BlobbyStateMachine" to="." method="_on_Blobby_got_grounded"] diff --git a/src/Actors/Blobby/BlobbyStateMachine.gd b/src/Actors/Blobby/BlobbyStateMachine.gd index b785b33..a0f105f 100644 --- a/src/Actors/Blobby/BlobbyStateMachine.gd +++ b/src/Actors/Blobby/BlobbyStateMachine.gd @@ -60,7 +60,8 @@ func _state_logic(delta): handle_input_ref = funcref(self, "handle_wallslide_input") _: print("don't panik") - + var texture = $"%BubbleShieldViewport".get_texture() + $"%Blobby3DEffects".texture = texture var direction = get_horizontal_direction() didTurn = false diff --git a/src/Actors/BlobbyCam.tscn b/src/Actors/BlobbyCam.tscn index 6fab596..743e3e9 100644 --- a/src/Actors/BlobbyCam.tscn +++ b/src/Actors/BlobbyCam.tscn @@ -633,10 +633,10 @@ texture = ExtResource( 8 ) [node name="AnimatedSprite" type="AnimatedSprite" parent="ParallaxBackground/ParallaxLayer5"] visible = false frames = SubResource( 7 ) -frame = 12 +frame = 2 playing = true [node name="AnimatedSprite2" type="AnimatedSprite" parent="ParallaxBackground/ParallaxLayer5"] frames = SubResource( 8 ) -frame = 3 +frame = 7 playing = true diff --git a/src/Actors/Enemies/Beings/Flyer.gd b/src/Actors/Enemies/Beings/Flyer.gd index d6155fd..2c71357 100644 --- a/src/Actors/Enemies/Beings/Flyer.gd +++ b/src/Actors/Enemies/Beings/Flyer.gd @@ -157,3 +157,6 @@ func update_navigation() -> void: func die() -> void: GlobalState.score += score queue_free() + +func get_facing_direction() -> float: + return orientation.cast_to.x diff --git a/src/Actors/Enemies/Beings/Flyer.tscn b/src/Actors/Enemies/Beings/Flyer.tscn index 1034827..c65079a 100644 --- a/src/Actors/Enemies/Beings/Flyer.tscn +++ b/src/Actors/Enemies/Beings/Flyer.tscn @@ -1,9 +1,187 @@ -[gd_scene load_steps=8 format=2] +[gd_scene load_steps=23 format=2] [ext_resource path="res://src/Actors/Enemies/Beings/Flyer.gd" type="Script" id=1] [ext_resource path="res://src/Actors/Enemies/Beings/FlyerStateMachine.gd" type="Script" id=2] [ext_resource path="res://assets/meta/new_dynamicfont.tres" type="DynamicFont" id=3] -[ext_resource path="res://assets/for testing/Adventurer Sprite Sheet v1.1.png" type="Texture" id=4] +[ext_resource path="res://assets/enemy/flyer-sheet.png" type="Texture" id=4] + +[sub_resource type="Animation" id=33] +length = 0.001 +tracks/0/type = "value" +tracks/0/path = NodePath(".:frame") +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": 0, +"values": [ 0 ] +} + +[sub_resource type="Animation" id=36] +resource_name = "hunting" +length = 1.62 +loop = true +step = 0.01 +tracks/0/type = "value" +tracks/0/path = NodePath(".:frame") +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": [ 0 ] +} +tracks/1/type = "value" +tracks/1/path = NodePath(".:scale") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ Vector2( -1, 1 ) ] +} + +[sub_resource type="Animation" id=38] +resource_name = "huntingLeft" +length = 0.042 +loop = true +tracks/0/type = "value" +tracks/0/path = NodePath(".:frame") +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": [ 0 ] +} +tracks/1/type = "value" +tracks/1/path = NodePath(".:scale") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ Vector2( 1, 1 ) ] +} + +[sub_resource type="Animation" id=35] +resource_name = "searching" +length = 1.62 +loop = true +step = 0.01 +tracks/0/type = "value" +tracks/0/path = NodePath(".:frame") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/keys = { +"times": PoolRealArray( 0.02 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ 1 ] +} +tracks/1/type = "value" +tracks/1/path = NodePath(".:scale") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ Vector2( -1, 1 ) ] +} + +[sub_resource type="Animation" id=34] +resource_name = "searchingLeft" +length = 1.62 +loop = true +step = 0.01 +tracks/0/type = "value" +tracks/0/path = NodePath(".:frame") +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": [ 1 ] +} +tracks/1/type = "value" +tracks/1/path = NodePath(".:scale") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ Vector2( 1, 1 ) ] +} + +[sub_resource type="AnimationNodeAnimation" id=46] +animation = "huntingLeft" + +[sub_resource type="AnimationNodeAnimation" id=47] +animation = "hunting" + +[sub_resource type="AnimationNodeBlendSpace1D" id=23] +blend_point_0/node = SubResource( 46 ) +blend_point_0/pos = -1.0 +blend_point_1/node = SubResource( 47 ) +blend_point_1/pos = 1.0 +min_space = -1.18 +max_space = 1.15 + +[sub_resource type="AnimationNodeAnimation" id=42] +animation = "searchingLeft" + +[sub_resource type="AnimationNodeAnimation" id=43] +animation = "searching" + +[sub_resource type="AnimationNodeBlendSpace1D" id=9] +blend_point_0/node = SubResource( 42 ) +blend_point_0/pos = -1.0 +blend_point_1/node = SubResource( 43 ) +blend_point_1/pos = 1.0 +min_space = -2.0 +max_space = 2.0 +snap = 1.0 + +[sub_resource type="AnimationNodeStateMachineTransition" id=27] + +[sub_resource type="AnimationNodeStateMachineTransition" id=32] + +[sub_resource type="AnimationNodeStateMachine" id=50] +states/hunting/node = SubResource( 23 ) +states/hunting/position = Vector2( 184.952, -12 ) +states/searching/node = SubResource( 9 ) +states/searching/position = Vector2( -52.0952, 102.762 ) +transitions = [ "searching", "hunting", SubResource( 27 ), "hunting", "searching", SubResource( 32 ) ] +start_node = "searching" +graph_offset = Vector2( -340, -193 ) + +[sub_resource type="AnimationNodeStateMachinePlayback" id=51] [sub_resource type="RectangleShape2D" id=1] extents = Vector2( 11, 9 ) @@ -40,12 +218,25 @@ align = 1 valign = 1 [node name="FlyerSprite" type="Sprite" parent="."] -position = Vector2( 2, -8 ) -scale = Vector2( 1, 1.34375 ) +unique_name_in_owner = true texture = ExtResource( 4 ) -hframes = 13 -vframes = 16 -frame = 81 +hframes = 2 + +[node name="AnimationPlayer" type="AnimationPlayer" parent="FlyerSprite"] +anims/RESET = SubResource( 33 ) +anims/hunting = SubResource( 36 ) +anims/huntingLeft = SubResource( 38 ) +anims/searching = SubResource( 35 ) +anims/searchingLeft = SubResource( 34 ) + +[node name="AnimationTree" type="AnimationTree" parent="FlyerSprite"] +tree_root = SubResource( 50 ) +anim_player = NodePath("../AnimationPlayer") +active = true +root_motion_track = NodePath(".") +parameters/playback = SubResource( 51 ) +parameters/hunting/blend_position = -1.04288 +parameters/searching/blend_position = 1.2903 [node name="VisibilityEnabler2D" type="VisibilityEnabler2D" parent="."] position = Vector2( 954, 0 ) diff --git a/src/Actors/Enemies/Beings/FlyerStateMachine.gd b/src/Actors/Enemies/Beings/FlyerStateMachine.gd index 3d80f41..2a11cd4 100644 --- a/src/Actors/Enemies/Beings/FlyerStateMachine.gd +++ b/src/Actors/Enemies/Beings/FlyerStateMachine.gd @@ -1,5 +1,7 @@ extends StateMachine +onready var anim_tree = $"../FlyerSprite/AnimationTree" +onready var anim_state_playback = $"../FlyerSprite/AnimationTree".get("parameters/playback") func _ready() -> void: add_state("searching") @@ -26,6 +28,7 @@ func _state_logic(delta): func _get_transition(_delta): parent.get_node("StateLabel").text = self.state + _animation_logic() var new_state if parent.target == null: new_state = states.searching @@ -44,3 +47,17 @@ func _enter_state(_new_state, _previous_state): func _exit_state(_previous_state, _new_state): pass + + +func _animation_logic(): + _set_blendspaces_direction() + if self.state == "searching": + anim_state_playback.travel("searching") + else: + anim_state_playback.travel("hunting") + + +func _set_blendspaces_direction(): + var value = parent.get_facing_direction() + anim_tree.set("parameters/searching/blend_position", value) + anim_tree.set("parameters/hunting/blend_position", value) diff --git a/src/Actors/Enemies/Beings/WhatAreFrog.tscn b/src/Actors/Enemies/Beings/WhatAreFrog.tscn index ea183ef..cef5962 100644 --- a/src/Actors/Enemies/Beings/WhatAreFrog.tscn +++ b/src/Actors/Enemies/Beings/WhatAreFrog.tscn @@ -252,58 +252,60 @@ tracks/1/keys = { "values": [ Vector2( -1, 1 ) ] } -[sub_resource type="AnimationNodeAnimation" id=7] -animation = "idleHappyLeft" +[sub_resource type="AnimationNodeAnimation" id=42] +animation = "searchingLeft" -[sub_resource type="AnimationNodeAnimation" id=8] -animation = "idleHappy" +[sub_resource type="AnimationNodeAnimation" id=43] +animation = "searching" [sub_resource type="AnimationNodeBlendSpace1D" id=9] -blend_point_0/node = SubResource( 7 ) +blend_point_0/node = SubResource( 42 ) blend_point_0/pos = -1.0 -blend_point_1/node = SubResource( 8 ) +blend_point_1/node = SubResource( 43 ) blend_point_1/pos = 1.0 min_space = -2.0 max_space = 2.0 snap = 1.0 -[sub_resource type="AnimationNodeAnimation" id=18] +[sub_resource type="AnimationNodeAnimation" id=44] animation = "idleMeanLeft" -[sub_resource type="AnimationNodeAnimation" id=19] +[sub_resource type="AnimationNodeAnimation" id=45] animation = "idleMean" [sub_resource type="AnimationNodeBlendSpace1D" id=20] -blend_point_0/node = SubResource( 18 ) +blend_point_0/node = SubResource( 44 ) blend_point_0/pos = -1.0 -blend_point_1/node = SubResource( 19 ) +blend_point_1/node = SubResource( 45 ) blend_point_1/pos = 1.0 min_space = -2.0 max_space = 2.0 snap = 1.0 -[sub_resource type="AnimationNodeAnimation" id=21] -animation = "liftOffLeft" +[sub_resource type="AnimationNodeAnimation" id=46] +animation = "huntingLeft" -[sub_resource type="AnimationNodeAnimation" id=22] -animation = "liftOff" +[sub_resource type="AnimationNodeAnimation" id=47] +animation = "hunting" [sub_resource type="AnimationNodeBlendSpace1D" id=23] -blend_point_0/node = SubResource( 21 ) +blend_point_0/node = SubResource( 46 ) blend_point_0/pos = -1.0 -blend_point_1/node = SubResource( 22 ) +blend_point_1/node = SubResource( 47 ) blend_point_1/pos = 1.0 +min_space = -1.18 +max_space = 1.15 -[sub_resource type="AnimationNodeAnimation" id=24] +[sub_resource type="AnimationNodeAnimation" id=48] animation = "midJumpingLeft" -[sub_resource type="AnimationNodeAnimation" id=25] +[sub_resource type="AnimationNodeAnimation" id=49] animation = "midJumping" [sub_resource type="AnimationNodeBlendSpace1D" id=26] -blend_point_0/node = SubResource( 24 ) +blend_point_0/node = SubResource( 48 ) blend_point_0/pos = -1.0 -blend_point_1/node = SubResource( 25 ) +blend_point_1/node = SubResource( 49 ) blend_point_1/pos = 1.0 [sub_resource type="AnimationNodeStateMachineTransition" id=27] @@ -321,8 +323,6 @@ switch_mode = 2 auto_advance = true [sub_resource type="AnimationNodeStateMachineTransition" id=32] -switch_mode = 2 -auto_advance = true [sub_resource type="AnimationNodeStateMachine" id=10] states/idleHappy/node = SubResource( 9 ) @@ -377,6 +377,7 @@ position = Vector2( 0, -7 ) texture = ExtResource( 1 ) hframes = 2 vframes = 4 +frame = 1 [node name="AnimationPlayer" type="AnimationPlayer" parent="FrogSprite"] anims/RESET = SubResource( 5 ) diff --git a/src/Contraptions/Rope/RopeAnchor.tscn b/src/Contraptions/Rope/RopeAnchor.tscn index b3b1097..c6fc7ec 100644 --- a/src/Contraptions/Rope/RopeAnchor.tscn +++ b/src/Contraptions/Rope/RopeAnchor.tscn @@ -1,6 +1,6 @@ [gd_scene load_steps=3 format=2] -[ext_resource path="res://assets/environment/blocks/random-innentile.png" type="Texture" id=1] +[ext_resource path="res://assets/enemy/laserpoint.png" type="Texture" id=1] [sub_resource type="CircleShape2D" id=5] radius = 2.0 diff --git a/src/Levels/Froggy Test Level.tscn b/src/Levels/Froggy Test Level.tscn index dea1634..dd37bee 100644 --- a/src/Levels/Froggy Test Level.tscn +++ b/src/Levels/Froggy Test Level.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=16 format=2] +[gd_scene load_steps=17 format=2] [ext_resource path="res://src/Environment/AlienShipTileSet.tres" type="TileSet" id=1] [ext_resource path="res://src/Utilities/GameplaySignalManager.gd" type="Script" id=2] @@ -8,6 +8,7 @@ [ext_resource path="res://src/Contraptions/Portal/Portal.tscn" type="PackedScene" id=6] [ext_resource path="res://src/Levels/Enemy Test Level.tscn" type="PackedScene" id=7] [ext_resource path="res://src/Contraptions/Platform/FlyingLaserCutter.tscn" type="PackedScene" id=8] +[ext_resource path="res://src/Actors/Enemies/Beings/BoundFrog.tscn" type="PackedScene" id=9] [ext_resource path="res://src/Contraptions/Triggers/ThreeWhyButtons.tscn" type="PackedScene" id=10] [ext_resource path="res://src/ObstacleObjects/Spikes.tscn" type="PackedScene" id=11] [ext_resource path="res://src/Actors/Blobby/Blobby.tscn" type="PackedScene" id=12] @@ -154,6 +155,10 @@ rotation = -6.28318 position = Vector2( 828, 324 ) rotation = -4.71238 +[node name="BoundFrog" parent="." instance=ExtResource( 9 )] +position = Vector2( 338, 254 ) + +[connection signal="ready" from="." to="BoundFrog" method="_on_LevelTemplate_ready"] [connection signal="timeout" from="UserInterface/HUD/HUDOverlay/GetBackTimer/Timer" to="GameplaySignalManager" method="_on_Timer_timeout"] [connection signal="getback_timer_up" from="GameplaySignalManager" to="Blobby" method="_on_GameplaySignalManager_getback_timer_up"] [connection signal="terminal_activated" from="GameplaySignalManager" to="UserInterface/HUD" method="_on_SignalManager_terminal_activated"] diff --git a/src/ThirdParty/Demo/IridescenceBall.tscn b/src/ThirdParty/Demo/IridescenceBall.tscn new file mode 100644 index 0000000..4b4dabc --- /dev/null +++ b/src/ThirdParty/Demo/IridescenceBall.tscn @@ -0,0 +1,18 @@ +[gd_scene load_steps=4 format=2] + +[ext_resource path="res://src/ThirdParty/Demo/meshinstance.gd" type="Script" id=1] +[ext_resource path="res://src/ThirdParty/Demo/meshinstance.material" type="Material" id=2] + +[sub_resource type="SphereMesh" id=1] + +[node name="IridescenceBall" type="Spatial"] + +[node name="Camera" type="Camera" parent="."] +transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 3 ) +far = 150.0 + +[node name="MeshInstance" type="MeshInstance" parent="."] +transform = Transform( 0.99997, -0.00767937, 0, 0.00767937, 0.99997, 0, 0, 0, 1, 0, 0, 0 ) +mesh = SubResource( 1 ) +material/0 = ExtResource( 2 ) +script = ExtResource( 1 ) diff --git a/src/ThirdParty/Demo/meshinstance.gd b/src/ThirdParty/Demo/meshinstance.gd new file mode 100644 index 0000000..b00dd20 --- /dev/null +++ b/src/ThirdParty/Demo/meshinstance.gd @@ -0,0 +1,5 @@ +extends MeshInstance + + +func _process(delta): + rotate_y(PI / 4.0 * delta) diff --git a/src/ThirdParty/Demo/meshinstance.material b/src/ThirdParty/Demo/meshinstance.material new file mode 100644 index 0000000..4ccb859 Binary files /dev/null and b/src/ThirdParty/Demo/meshinstance.material differ diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/.gitignore b/src/ThirdParty/Godot-Iridescence-Shader-master/.gitignore new file mode 100644 index 0000000..bf384b6 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/.gitignore @@ -0,0 +1,2 @@ +.import* +**/*.import diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/Demo.tscn b/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/Demo.tscn new file mode 100644 index 0000000..572fc49 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/Demo.tscn @@ -0,0 +1,36 @@ +[gd_scene load_steps=6 format=2] + +[ext_resource path="res://Demo/meshinstance.gd" type="Script" id=1] +[ext_resource path="res://Demo/meshinstance.material" type="Material" id=2] + +[sub_resource type="SphereMesh" id=1] + +[sub_resource type="ProceduralSky" id=2] +ground_bottom_color = Color( 0.647059, 0.839216, 0.945098, 1 ) +ground_horizon_color = Color( 0.839216, 0.917647, 0.980392, 1 ) + +[sub_resource type="Environment" id=3] +background_mode = 2 +background_sky = SubResource( 2 ) +background_color = Color( 0.0666667, 0.65098, 0.905882, 1 ) +ambient_light_sky_contribution = 0.0 +tonemap_mode = 2 +auto_exposure_scale = 0.6 +auto_exposure_min_luma = 6.91 +auto_exposure_max_luma = 16.0 +auto_exposure_speed = 50.43 + +[node name="Demo" type="Spatial"] + +[node name="Camera" type="Camera" parent="."] +transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 3 ) +far = 150.0 + +[node name="MeshInstance" type="MeshInstance" parent="."] +transform = Transform( 0.99997, -0.00767937, 0, 0.00767937, 0.99997, 0, 0, 0, 1, 0, 0, 0 ) +mesh = SubResource( 1 ) +material/0 = ExtResource( 2 ) +script = ExtResource( 1 ) + +[node name="WorldEnvironment" type="WorldEnvironment" parent="."] +environment = SubResource( 3 ) diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/meshinstance.gd b/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/meshinstance.gd new file mode 100644 index 0000000..b00dd20 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/meshinstance.gd @@ -0,0 +1,5 @@ +extends MeshInstance + + +func _process(delta): + rotate_y(PI / 4.0 * delta) diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/meshinstance.material b/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/meshinstance.material new file mode 100644 index 0000000..d80430e Binary files /dev/null and b/src/ThirdParty/Godot-Iridescence-Shader-master/Demo/meshinstance.material differ diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Gradiants/iridescence_gradiant.tres b/src/ThirdParty/Godot-Iridescence-Shader-master/Gradiants/iridescence_gradiant.tres new file mode 100644 index 0000000..3183164 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/Gradiants/iridescence_gradiant.tres @@ -0,0 +1,8 @@ +[gd_resource type="GradientTexture" load_steps=2 format=2] + +[sub_resource type="Gradient" id=1] +offsets = PoolRealArray( 0, 0.0816327, 0.156463, 0.238095, 0.319728, 0.414966, 0.489796, 0.591837, 0.70068, 0.809524, 0.911565, 1 ) +colors = PoolColorArray( 0, 0, 0, 0, 1, 0, 0, 1, 1, 0.585938, 0, 1, 1, 0.960938, 0, 1, 0.631893, 1, 0.403573, 1, 0, 1, 0.554688, 1, 0, 0.953125, 1, 1, 0, 0.390625, 1, 1, 0.382812, 0, 1, 1, 1, 0, 0.820312, 1, 1, 0, 0, 1, 1, 0.611765, 0.611765, 0 ) + +[resource] +gradient = SubResource( 1 ) diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Images/irs.png b/src/ThirdParty/Godot-Iridescence-Shader-master/Images/irs.png new file mode 100644 index 0000000..1ce88f1 Binary files /dev/null and b/src/ThirdParty/Godot-Iridescence-Shader-master/Images/irs.png differ diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/LICENSE.txt b/src/ThirdParty/Godot-Iridescence-Shader-master/LICENSE.txt new file mode 100644 index 0000000..7d97c77 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/LICENSE.txt @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 David E Lipps + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/README.md b/src/ThirdParty/Godot-Iridescence-Shader-master/README.md new file mode 100644 index 0000000..6e213c8 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/README.md @@ -0,0 +1,25 @@ +## EXP Iridescence Shader v.1.0.0 +#### By David Lipps aka Dave the Dev at EXPWorlds for Godot 3.2 Stable +--- +![Example Palettle Editor Image](Images/irs.png) + +--- + +A gradiant based iridescense shader. + + [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=22E6SNKTLTHRL¤cy_code=USD&source=url) If this project helped you out, consider sending some coffee my way so I can stay locked in "the zone" and bring the Godot community more cool free stuff. + +--- +**Parameter Discriptions:** +- Wavelength: Higher numbers increase the wave count. +- Wavespeed: How fast the waves animate. +- Alpha: The translucence of the object. +- Displacement: The amont the noise displacment texture can translate the vertices from their original position. +- Displacement Speed: How fast the noise displacement texture animates the object. +- Noise Texture: The perlin noise texture that offsets the waves. +- Noise Displacement Texture: The perlin noise texture that displaces vertices. +- Gradiant: The gradiant texture which defines the visible spectrum of the waves. + +--- +I can be reached at: davidlipps.dev@gmail.com +I'd love to hear your thoughts. Especially about how I can improve. I'll do my best to get back to you. \ No newline at end of file diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Shader/iridescence.shader b/src/ThirdParty/Godot-Iridescence-Shader-master/Shader/iridescence.shader new file mode 100644 index 0000000..9ded21e --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/Shader/iridescence.shader @@ -0,0 +1,29 @@ +shader_type spatial; +render_mode unshaded; + +uniform float wavelength = 10.0; +uniform float wavespeed = 1.0; +uniform float alpha = 0.25; +uniform float displacement = 0.0; +uniform float displacement_speed = 1.0; + +uniform sampler2D noise_texture; +uniform sampler2D noise_displacement_texture; +uniform sampler2D gradiant; + +void vertex() +{ + vec3 perlin = texture(noise_displacement_texture, UV + (TIME * displacement_speed)).rgb; + VERTEX = VERTEX + (perlin * NORMAL * displacement); +} + + +void fragment() +{ + vec3 perlin = texture(noise_texture, UV).rgb; + float ndotp = dot(VIEW, perlin) * wavelength; + float waves = (1.0 + sin(ndotp + TIME * wavespeed)) / 2.0; + vec4 color = texture(gradiant, vec2(waves, 0.5)); + ALBEDO = color.rgb; + ALPHA = min(color.a, alpha); +} \ No newline at end of file diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/Shader/iridescence_cullfront.shader b/src/ThirdParty/Godot-Iridescence-Shader-master/Shader/iridescence_cullfront.shader new file mode 100644 index 0000000..e87e50d --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/Shader/iridescence_cullfront.shader @@ -0,0 +1,29 @@ +shader_type spatial; +render_mode unshaded, cull_front; + +uniform float wavelength = 10.0; +uniform float wavespeed = 1.0; +uniform float alpha = 0.25; +uniform float displacement = 0.0; +uniform float displacement_speed = 1.0; + +uniform sampler2D noise_texture; +uniform sampler2D noise_displacement_texture; +uniform sampler2D gradiant; + +void vertex() +{ + vec3 perlin = texture(noise_displacement_texture, UV + (TIME * displacement_speed)).rgb; + VERTEX = VERTEX + (perlin * NORMAL * displacement); +} + + +void fragment() +{ + vec3 perlin = texture(noise_texture, UV).rgb; + float ndotp = dot(VIEW, perlin) * wavelength; + float waves = (1.0 + sin(ndotp + TIME * wavespeed)) / 2.0; + vec4 color = texture(gradiant, vec2(waves, 0.5)); + ALBEDO = color.rgb; + ALPHA = min(color.a, alpha); +} \ No newline at end of file diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/icon.png b/src/ThirdParty/Godot-Iridescence-Shader-master/icon.png new file mode 100644 index 0000000..a5dd6d9 Binary files /dev/null and b/src/ThirdParty/Godot-Iridescence-Shader-master/icon.png differ diff --git a/src/ThirdParty/Godot-Iridescence-Shader-master/project.godot b/src/ThirdParty/Godot-Iridescence-Shader-master/project.godot new file mode 100644 index 0000000..6cefc55 --- /dev/null +++ b/src/ThirdParty/Godot-Iridescence-Shader-master/project.godot @@ -0,0 +1,18 @@ +; Engine configuration file. +; It's best edited using the editor UI and not directly, +; since the parameters that go here are not all obvious. +; +; Format: +; [section] ; section goes between [] +; param=value ; assign values to parameters + +config_version=4 + +_global_script_classes=[ ] +_global_script_class_icons={ +} + +[application] + +config/name="EXP-Shader-Iridescence" +config/icon="res://icon.png" diff --git a/src/ThirdParty/Gradiants/iridescence_gradiant.tres b/src/ThirdParty/Gradiants/iridescence_gradiant.tres new file mode 100644 index 0000000..3183164 --- /dev/null +++ b/src/ThirdParty/Gradiants/iridescence_gradiant.tres @@ -0,0 +1,8 @@ +[gd_resource type="GradientTexture" load_steps=2 format=2] + +[sub_resource type="Gradient" id=1] +offsets = PoolRealArray( 0, 0.0816327, 0.156463, 0.238095, 0.319728, 0.414966, 0.489796, 0.591837, 0.70068, 0.809524, 0.911565, 1 ) +colors = PoolColorArray( 0, 0, 0, 0, 1, 0, 0, 1, 1, 0.585938, 0, 1, 1, 0.960938, 0, 1, 0.631893, 1, 0.403573, 1, 0, 1, 0.554688, 1, 0, 0.953125, 1, 1, 0, 0.390625, 1, 1, 0.382812, 0, 1, 1, 1, 0, 0.820312, 1, 1, 0, 0, 1, 1, 0.611765, 0.611765, 0 ) + +[resource] +gradient = SubResource( 1 ) diff --git a/src/ThirdParty/Images/irs.png b/src/ThirdParty/Images/irs.png new file mode 100644 index 0000000..1ce88f1 Binary files /dev/null and b/src/ThirdParty/Images/irs.png differ diff --git a/src/ThirdParty/Images/irs.png.import b/src/ThirdParty/Images/irs.png.import new file mode 100644 index 0000000..54482f4 --- /dev/null +++ b/src/ThirdParty/Images/irs.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/irs.png-dbed701ff1f1618c8da9c69410d8a49a.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://src/ThirdParty/Images/irs.png" +dest_files=[ "res://.import/irs.png-dbed701ff1f1618c8da9c69410d8a49a.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=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=false +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/src/ThirdParty/Shader/iridescence.shader b/src/ThirdParty/Shader/iridescence.shader new file mode 100644 index 0000000..9ded21e --- /dev/null +++ b/src/ThirdParty/Shader/iridescence.shader @@ -0,0 +1,29 @@ +shader_type spatial; +render_mode unshaded; + +uniform float wavelength = 10.0; +uniform float wavespeed = 1.0; +uniform float alpha = 0.25; +uniform float displacement = 0.0; +uniform float displacement_speed = 1.0; + +uniform sampler2D noise_texture; +uniform sampler2D noise_displacement_texture; +uniform sampler2D gradiant; + +void vertex() +{ + vec3 perlin = texture(noise_displacement_texture, UV + (TIME * displacement_speed)).rgb; + VERTEX = VERTEX + (perlin * NORMAL * displacement); +} + + +void fragment() +{ + vec3 perlin = texture(noise_texture, UV).rgb; + float ndotp = dot(VIEW, perlin) * wavelength; + float waves = (1.0 + sin(ndotp + TIME * wavespeed)) / 2.0; + vec4 color = texture(gradiant, vec2(waves, 0.5)); + ALBEDO = color.rgb; + ALPHA = min(color.a, alpha); +} \ No newline at end of file diff --git a/src/ThirdParty/Shader/iridescence_cullfront.shader b/src/ThirdParty/Shader/iridescence_cullfront.shader new file mode 100644 index 0000000..e87e50d --- /dev/null +++ b/src/ThirdParty/Shader/iridescence_cullfront.shader @@ -0,0 +1,29 @@ +shader_type spatial; +render_mode unshaded, cull_front; + +uniform float wavelength = 10.0; +uniform float wavespeed = 1.0; +uniform float alpha = 0.25; +uniform float displacement = 0.0; +uniform float displacement_speed = 1.0; + +uniform sampler2D noise_texture; +uniform sampler2D noise_displacement_texture; +uniform sampler2D gradiant; + +void vertex() +{ + vec3 perlin = texture(noise_displacement_texture, UV + (TIME * displacement_speed)).rgb; + VERTEX = VERTEX + (perlin * NORMAL * displacement); +} + + +void fragment() +{ + vec3 perlin = texture(noise_texture, UV).rgb; + float ndotp = dot(VIEW, perlin) * wavelength; + float waves = (1.0 + sin(ndotp + TIME * wavespeed)) / 2.0; + vec4 color = texture(gradiant, vec2(waves, 0.5)); + ALBEDO = color.rgb; + ALPHA = min(color.a, alpha); +} \ No newline at end of file diff --git a/src/ThirdParty/iridescence.shader b/src/ThirdParty/iridescence.shader new file mode 100644 index 0000000..e69de29