Heads now stick to glass tables (and bleed).
This commit is contained in:
parent
a13f274767
commit
ab0a4e24f7
5 changed files with 56 additions and 7 deletions
|
|
@ -7,6 +7,8 @@ var shader_active = false
|
||||||
var pause = false
|
var pause = false
|
||||||
var target = null
|
var target = null
|
||||||
|
|
||||||
|
@onready var head_splat = preload("res://sprites/head_splat.png")
|
||||||
|
|
||||||
func start(pos):
|
func start(pos):
|
||||||
position = pos
|
position = pos
|
||||||
|
|
||||||
|
|
@ -50,8 +52,15 @@ func _on_area_entered(area: Area2D) -> void:
|
||||||
if area.is_in_group("shards"):
|
if area.is_in_group("shards"):
|
||||||
print("Shards hit!")
|
print("Shards hit!")
|
||||||
area.hit_detection()
|
area.hit_detection()
|
||||||
#stick_to_target(target)
|
# stick_to_target(target)
|
||||||
queue_free()
|
reparent(area)
|
||||||
|
$Sprite2D.texture = head_splat
|
||||||
|
$Sprite2D.hframes = 1
|
||||||
|
position = Vector2.ZERO
|
||||||
|
pause = true
|
||||||
|
$Sprite2D/GPUParticles2D.hide()
|
||||||
|
monitoring = false
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
"mirror":
|
"mirror":
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ var enemy_type: String = "shards"
|
||||||
@onready var child_node = get_node("Player")
|
@onready var child_node = get_node("Player")
|
||||||
|
|
||||||
func hit_detection():
|
func hit_detection():
|
||||||
print("Shift!")
|
#print("Shift!")
|
||||||
#var tween = create_tween().set_parallel(true)
|
#var tween = create_tween().set_parallel(true)
|
||||||
#tween.tween_property($Sprite, "position:y", 4, 0.1)
|
#tween.tween_property($Sprite, "position:y", 4, 0.1)
|
||||||
#tween.tween_property($Sprite, "position:y", 0, 0.05)
|
#tween.tween_property($Sprite, "position:y", 0, 0.05)
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ func _ready():
|
||||||
|
|
||||||
func spawn_enemies():
|
func spawn_enemies():
|
||||||
|
|
||||||
if wave_count == 2: #This is for CHICKENS
|
if wave_count == 1: #This is for CHICKENS
|
||||||
print("Enemy Wave: ", wave_count)
|
print("Enemy Wave: ", wave_count)
|
||||||
enemy = CHICKEN
|
enemy = CHICKEN
|
||||||
for x in range(COLS):
|
for x in range(COLS):
|
||||||
|
|
@ -53,7 +53,7 @@ func spawn_enemies():
|
||||||
enemy_count = rows_mod * cols_mod
|
enemy_count = rows_mod * cols_mod
|
||||||
await get_tree().process_frame
|
await get_tree().process_frame
|
||||||
|
|
||||||
if wave_count == 3 : #This if for Mirror
|
if wave_count == 0 : #This if for Mirror
|
||||||
print("Enemy Wave: ", wave_count)
|
print("Enemy Wave: ", wave_count)
|
||||||
|
|
||||||
# Spawn Table
|
# Spawn Table
|
||||||
|
|
@ -89,7 +89,7 @@ func spawn_enemies():
|
||||||
s.start_all_animations()
|
s.start_all_animations()
|
||||||
|
|
||||||
|
|
||||||
if wave_count == 0 : #This is for Boss
|
if wave_count == 2 : #This is for Boss
|
||||||
|
|
||||||
# Hide the player
|
# Hide the player
|
||||||
|
|
||||||
|
|
|
||||||
BIN
sprites/head_splat.png
Normal file
BIN
sprites/head_splat.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 210 B |
40
sprites/head_splat.png.import
Normal file
40
sprites/head_splat.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://whgwb5c750lk"
|
||||||
|
path="res://.godot/imported/head_splat.png-2dd7aa8d11d236451176ca1dc6411bb6.ctex"
|
||||||
|
metadata={
|
||||||
|
"vram_texture": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://sprites/head_splat.png"
|
||||||
|
dest_files=["res://.godot/imported/head_splat.png-2dd7aa8d11d236451176ca1dc6411bb6.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
compress/uastc_level=0
|
||||||
|
compress/rdo_quality_loss=0.0
|
||||||
|
compress/hdr_compression=1
|
||||||
|
compress/normal_map=0
|
||||||
|
compress/channel_pack=0
|
||||||
|
mipmaps/generate=false
|
||||||
|
mipmaps/limit=-1
|
||||||
|
roughness/mode=0
|
||||||
|
roughness/src_normal=""
|
||||||
|
process/channel_remap/red=0
|
||||||
|
process/channel_remap/green=1
|
||||||
|
process/channel_remap/blue=2
|
||||||
|
process/channel_remap/alpha=3
|
||||||
|
process/fix_alpha_border=true
|
||||||
|
process/premult_alpha=false
|
||||||
|
process/normal_map_invert_y=false
|
||||||
|
process/hdr_as_srgb=false
|
||||||
|
process/hdr_clamp_exposure=false
|
||||||
|
process/size_limit=0
|
||||||
|
detect_3d/compress_to=1
|
||||||
Loading…
Add table
Add a link
Reference in a new issue