diff --git a/assets/MOUSE.png b/assets/MOUSE.png new file mode 100644 index 0000000..d3ed865 Binary files /dev/null and b/assets/MOUSE.png differ diff --git a/assets/MOUSE.png.import b/assets/MOUSE.png.import new file mode 100644 index 0000000..853a1e8 --- /dev/null +++ b/assets/MOUSE.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dmmm5xr6m7lb8" +path="res://.godot/imported/MOUSE.png-713d73e5cc1325cdd5d58068cf19d8bf.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/MOUSE.png" +dest_files=["res://.godot/imported/MOUSE.png-713d73e5cc1325cdd5d58068cf19d8bf.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/chores.png b/assets/chores.png new file mode 100644 index 0000000..001b117 Binary files /dev/null and b/assets/chores.png differ diff --git a/assets/chores.png.import b/assets/chores.png.import new file mode 100644 index 0000000..d17a133 --- /dev/null +++ b/assets/chores.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://3cpa43wrk5ih" +path="res://.godot/imported/chores.png-4701f6260e41a338783c1947d3947064.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/chores.png" +dest_files=["res://.godot/imported/chores.png-4701f6260e41a338783c1947d3947064.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/dog/face.png b/assets/dog/face.png new file mode 100644 index 0000000..ce5d15a Binary files /dev/null and b/assets/dog/face.png differ diff --git a/assets/dog/face.png.import b/assets/dog/face.png.import new file mode 100644 index 0000000..6e03038 --- /dev/null +++ b/assets/dog/face.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dddx6l8owf5x6" +path="res://.godot/imported/face.png-15f0401002d7cba90f186eb3e32d598b.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/dog/face.png" +dest_files=["res://.godot/imported/face.png-15f0401002d7cba90f186eb3e32d598b.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/dog/head.png b/assets/dog/head.png new file mode 100644 index 0000000..b57bd9f Binary files /dev/null and b/assets/dog/head.png differ diff --git a/assets/dog/head.png.import b/assets/dog/head.png.import new file mode 100644 index 0000000..3fb2c1d --- /dev/null +++ b/assets/dog/head.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bn4k2g7ye2jrq" +path="res://.godot/imported/head.png-723d11f6d9ef6f4495bc33a80fe25922.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/dog/head.png" +dest_files=["res://.godot/imported/head.png-723d11f6d9ef6f4495bc33a80fe25922.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/dog/torso.png b/assets/dog/torso.png new file mode 100644 index 0000000..83104db Binary files /dev/null and b/assets/dog/torso.png differ diff --git a/assets/dog/torso.png.import b/assets/dog/torso.png.import new file mode 100644 index 0000000..6501b05 --- /dev/null +++ b/assets/dog/torso.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dl013bmiia5bo" +path="res://.godot/imported/torso.png-9a87a70a9ed92213ad6b77fdb045bea7.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/dog/torso.png" +dest_files=["res://.godot/imported/torso.png-9a87a70a9ed92213ad6b77fdb045bea7.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/joel/face.png b/assets/joel/face.png new file mode 100644 index 0000000..3a240fa Binary files /dev/null and b/assets/joel/face.png differ diff --git a/assets/joel/face.png.import b/assets/joel/face.png.import new file mode 100644 index 0000000..8e74a69 --- /dev/null +++ b/assets/joel/face.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dm41mixjdfa07" +path="res://.godot/imported/face.png-c0a9df339b85055712b832eaad601d09.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/joel/face.png" +dest_files=["res://.godot/imported/face.png-c0a9df339b85055712b832eaad601d09.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/joel/head.png b/assets/joel/head.png new file mode 100644 index 0000000..bbd2900 Binary files /dev/null and b/assets/joel/head.png differ diff --git a/assets/joel/head.png.import b/assets/joel/head.png.import new file mode 100644 index 0000000..b63647e --- /dev/null +++ b/assets/joel/head.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://c7emacib0c1o7" +path="res://.godot/imported/head.png-a251a122079d3beb38f6d48573713730.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/joel/head.png" +dest_files=["res://.godot/imported/head.png-a251a122079d3beb38f6d48573713730.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/joel/torso.png b/assets/joel/torso.png new file mode 100644 index 0000000..73636a9 Binary files /dev/null and b/assets/joel/torso.png differ diff --git a/assets/joel/torso.png.import b/assets/joel/torso.png.import new file mode 100644 index 0000000..7db761a --- /dev/null +++ b/assets/joel/torso.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bq2ck85m7c6ai" +path="res://.godot/imported/torso.png-476a000523c4d6c89615518c782d5827.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/joel/torso.png" +dest_files=["res://.godot/imported/torso.png-476a000523c4d6c89615518c782d5827.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/sheet02.png b/assets/sheet02.png new file mode 100644 index 0000000..d444c3a Binary files /dev/null and b/assets/sheet02.png differ diff --git a/assets/sheet02.png.import b/assets/sheet02.png.import new file mode 100644 index 0000000..8aba52c --- /dev/null +++ b/assets/sheet02.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dw415r5q7gjav" +path="res://.godot/imported/sheet02.png-0118eec9ffb962618662fb98c07a6c2d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/sheet02.png" +dest_files=["res://.godot/imported/sheet02.png-0118eec9ffb962618662fb98c07a6c2d.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/tailor/bowtie.png b/assets/tailor/bowtie.png new file mode 100644 index 0000000..7498fbb Binary files /dev/null and b/assets/tailor/bowtie.png differ diff --git a/assets/tailor/bowtie.png.import b/assets/tailor/bowtie.png.import new file mode 100644 index 0000000..a7df5ea --- /dev/null +++ b/assets/tailor/bowtie.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b1ftt3c06srb" +path="res://.godot/imported/bowtie.png-de3366fa1ac49f34877092b9de1bb318.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/tailor/bowtie.png" +dest_files=["res://.godot/imported/bowtie.png-de3366fa1ac49f34877092b9de1bb318.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/tailor/face.png b/assets/tailor/face.png new file mode 100644 index 0000000..bb916ad Binary files /dev/null and b/assets/tailor/face.png differ diff --git a/assets/tailor/face.png.import b/assets/tailor/face.png.import new file mode 100644 index 0000000..df6665c --- /dev/null +++ b/assets/tailor/face.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cw3ia2pxvrjnb" +path="res://.godot/imported/face.png-39d1cba2b542964f3a90bebb8cef73d4.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/tailor/face.png" +dest_files=["res://.godot/imported/face.png-39d1cba2b542964f3a90bebb8cef73d4.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/tailor/head.png b/assets/tailor/head.png new file mode 100644 index 0000000..ca217f9 Binary files /dev/null and b/assets/tailor/head.png differ diff --git a/assets/tailor/head.png.import b/assets/tailor/head.png.import new file mode 100644 index 0000000..a0ea945 --- /dev/null +++ b/assets/tailor/head.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b8046hu2mejxq" +path="res://.godot/imported/head.png-3896e46b7b4e8b5edc5b04f5e7fd600f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/tailor/head.png" +dest_files=["res://.godot/imported/head.png-3896e46b7b4e8b5edc5b04f5e7fd600f.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/assets/tailor/torso.png b/assets/tailor/torso.png new file mode 100644 index 0000000..3431eb0 Binary files /dev/null and b/assets/tailor/torso.png differ diff --git a/assets/tailor/torso.png.import b/assets/tailor/torso.png.import new file mode 100644 index 0000000..2d561c7 --- /dev/null +++ b/assets/tailor/torso.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bxjhummaioy11" +path="res://.godot/imported/torso.png-f035b88c735aeb63941829d5cf838f15.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/tailor/torso.png" +dest_files=["res://.godot/imported/torso.png-f035b88c735aeb63941829d5cf838f15.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +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/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 diff --git a/mouseparticle.gd b/mouseparticle.gd new file mode 100644 index 0000000..138a918 --- /dev/null +++ b/mouseparticle.gd @@ -0,0 +1,13 @@ +extends Line2D + +var maxlen = 2 + +func _process(delta): + var pos = get_global_mouse_position() + add_point(pos) + + +func _physics_process(delta): + if len(points) >= maxlen: + + remove_point(0) diff --git a/project.godot b/project.godot index 57d4dc7..c589853 100644 --- a/project.godot +++ b/project.godot @@ -15,6 +15,10 @@ config/features=PackedStringArray("4.2", "Forward Plus") boot_splash/bg_color=Color(1, 1, 1, 1) config/icon="res://icon.svg" +[autoload] + +Playmouseparticle="*res://tscn/playmouseparticle.tscn" + [display] window/size/viewport_width=576 @@ -24,6 +28,9 @@ window/size/window_width_override=1152 window/size/window_height_override=648 window/stretch/mode="canvas_items" window/stretch/scale_mode="integer" +mouse_cursor/custom_image="res://assets/MOUSE.png" +mouse_cursor/custom_image_hotspot=Vector2(6, 6) +mouse_cursor/tooltip_position_offset=Vector2(6, 6) [input] @@ -57,6 +64,11 @@ interact={ "events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":32,"key_label":0,"unicode":32,"echo":false,"script":null) ] } +shoot={ +"deadzone": 0.5, +"events": [Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":1,"position":Vector2(161, 20),"global_position":Vector2(165, 61),"factor":1.0,"button_index":1,"canceled":false,"pressed":true,"double_click":false,"script":null) +] +} [rendering] diff --git a/scripts/main.gd b/scripts/main.gd index 2b7ff7e..1afad0a 100644 --- a/scripts/main.gd +++ b/scripts/main.gd @@ -1,14 +1,20 @@ extends Node2D -@onready var dial = $CharacterBody2D/CanvasLayer +@onready var dial = $plr/CanvasLayer # Called when the node enters the scene tree for the first time. func _ready(): await get_tree().create_timer(3).timeout dial.typewrite("Oh what a wonderful day today!", load("res://sfx/meow.wav"),2, false) await dial.Done dial.typewrite("I should do my chores!", load("res://sfx/meow.wav"),2, true) + $plr/chores/Sprite2D2.position.x += 100 + $plr/chores/Sprite2D2.visible = true + var tweener = get_tree().create_tween() + tweener.set_trans(Tween.TRANS_CUBIC) + tweener.set_ease(Tween.EASE_IN_OUT) + tweener.tween_property($plr/chores/Sprite2D2,"position", Vector2(519,70),1) await dial.Done - $CharacterBody2D.moving = true + $plr.moving = true # Called every frame. 'delta' is the elapsed time since the previous frame. func _process(delta): diff --git a/scripts/plr.gd b/scripts/plr.gd index d7716e6..9daee97 100644 --- a/scripts/plr.gd +++ b/scripts/plr.gd @@ -3,19 +3,26 @@ extends CharacterBody2D signal interact signal interact2 const SPEED = 300.0 - +@onready var gun = $gun +var has_gun = false @export var moving = true - +var bullets = 0 +var can_shoot = true # Get the gravity from the project settings to be synced with RigidBody nodes. func handle_layer(direction): if round(direction.y) == -1: $character/body/tail.z_index = 1 + $gun.z_index = -1 $character/body/face.visible = false elif round(direction.y) == 1: $character/body/tail.z_index = 0 + $gun.z_index = 0 $character/body/face.visible = true +func _ready(): + if not has_gun: + $gun.visible = false func _physics_process(_delta): if Input.is_action_just_pressed("interact"): @@ -27,12 +34,24 @@ func _physics_process(_delta): # Get the input direction and handle the movement/deceleration. # As good practice, you should replace UI actions with custom gawameplay actions. var direction = Input.get_vector("left","right","up","down") + if Input.is_action_pressed("shoot") and can_shoot and has_gun: + var bullet = preload("res://tscn/bullet.tscn").instantiate() + bullet.position = gun.global_position + bullet.z_index = gun.z_index + var dir = (get_global_mouse_position() - gun.global_position).normalized() + bullet.global_rotation = dir.angle() + PI / 2.0 + bullet.direction = dir + get_tree().current_scene.add_child(bullet) + $cooldown.start() + can_shoot = false + + if direction == Vector2(0,0): $AnimationPlayer.current_animation = "idle" else: handle_layer(direction) - - print(direction.x) + + if not direction.x == 0: $character.scale.x = round(direction.x) @@ -44,3 +63,9 @@ func _physics_process(_delta): move_and_slide() + + + + +func _on_cooldown_timeout(): + can_shoot = true diff --git a/tscn/bullet.gd b/tscn/bullet.gd new file mode 100644 index 0000000..262dc07 --- /dev/null +++ b/tscn/bullet.gd @@ -0,0 +1,20 @@ +extends CharacterBody2D + + +var direction = Vector2.LEFT +@export var speed = 6# pixels / s +@export var damage = 4 + + +func _physics_process(delta): + var mover = move_and_collide(direction * speed) + + + +func _on_visible_on_screen_notifier_2d_screen_exited(): + queue_free() + +func _on_area_2d_body_entered(body): + if not body.name == "plr": + body.die() + queue_free() diff --git a/tscn/bullet.tscn b/tscn/bullet.tscn new file mode 100644 index 0000000..2848f82 --- /dev/null +++ b/tscn/bullet.tscn @@ -0,0 +1,53 @@ +[gd_scene load_steps=8 format=3 uid="uid://cm6t7t21qai2k"] + +[ext_resource type="Script" path="res://tscn/bullet.gd" id="1_xkvd4"] +[ext_resource type="Texture2D" uid="uid://dw415r5q7gjav" path="res://assets/sheet02.png" id="2_u4orb"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_0degb"] +atlas = ExtResource("2_u4orb") +region = Rect2(166, 36, 5, 3) + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_6i4pj"] +size = Vector2(5, 3) + +[sub_resource type="Curve" id="Curve_0a7jy"] +_data = [Vector2(0.0225989, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), 0.0, 0.0, 0, 0] +point_count = 2 + +[sub_resource type="CurveTexture" id="CurveTexture_jkm6o"] +curve = SubResource("Curve_0a7jy") + +[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_4tm8h"] +particle_flag_disable_z = true +gravity = Vector3(-50, 0, 0) +color = Color(0, 0, 0, 1) +alpha_curve = SubResource("CurveTexture_jkm6o") + +[node name="bullet" type="CharacterBody2D"] +script = ExtResource("1_xkvd4") + +[node name="Sprite2D" type="Sprite2D" parent="."] +position = Vector2(-2, -1) +texture = SubResource("AtlasTexture_0degb") +centered = false + +[node name="VisibleOnScreenNotifier2D" type="VisibleOnScreenNotifier2D" parent="."] +position = Vector2(0.5, 0.5) +scale = Vector2(0.25, 0.15) + +[node name="Area2D" type="Area2D" parent="."] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"] +position = Vector2(0.5, 0.5) +shape = SubResource("RectangleShape2D_6i4pj") + +[node name="GPUParticles2D" type="GPUParticles2D" parent="."] +position = Vector2(-1, 0.5) +process_material = SubResource("ParticleProcessMaterial_4tm8h") +lifetime = 0.4 +trail_enabled = true +trail_sections = 2 +trail_section_subdivisions = 6 + +[connection signal="screen_exited" from="VisibleOnScreenNotifier2D" to="." method="_on_visible_on_screen_notifier_2d_screen_exited"] +[connection signal="body_entered" from="Area2D" to="." method="_on_area_2d_body_entered"] diff --git a/tscn/city.gd b/tscn/city.gd new file mode 100644 index 0000000..7f46e2c --- /dev/null +++ b/tscn/city.gd @@ -0,0 +1,12 @@ +extends Node2D + + +# Called when the node enters the scene tree for the first time. +func _ready(): + $plr.has_gun = true + $plr/gun.visible = true + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + pass diff --git a/tscn/city.tscn b/tscn/city.tscn new file mode 100644 index 0000000..f6f5323 --- /dev/null +++ b/tscn/city.tscn @@ -0,0 +1,297 @@ +[gd_scene load_steps=14 format=3 uid="uid://dn6qw8d2vmwbn"] + +[ext_resource type="PackedScene" uid="uid://cab0u1jewvqun" path="res://tscn/lines.tscn" id="1_380dk"] +[ext_resource type="Script" path="res://tscn/city.gd" id="1_wusia"] +[ext_resource type="Texture2D" uid="uid://tyvdq4i2kfx7" path="res://assets/lines.png" id="2_v8fo1"] +[ext_resource type="PackedScene" uid="uid://ceqnn4bkdnnkg" path="res://tscn/plr.tscn" id="3_wha8j"] +[ext_resource type="Texture2D" uid="uid://bq2ck85m7c6ai" path="res://assets/joel/torso.png" id="4_a8t6b"] +[ext_resource type="Texture2D" uid="uid://c7emacib0c1o7" path="res://assets/joel/head.png" id="5_e7dox"] +[ext_resource type="Texture2D" uid="uid://dm41mixjdfa07" path="res://assets/joel/face.png" id="6_skr4v"] +[ext_resource type="PackedScene" uid="uid://dx20e0gj3og1l" path="res://tscn/enemyhitbox.tscn" id="7_6fex8"] +[ext_resource type="Script" path="res://tscn/die.gd" id="8_cre0a"] +[ext_resource type="PackedScene" uid="uid://bpjluewfoh3fx" path="res://tscn/dog.tscn" id="9_1v6uv"] + +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_5rlqc"] +texture = ExtResource("2_v8fo1") +texture_region_size = Vector2i(10, 10) +0:7/0 = 0 +0:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:7/0/physics_layer_0/angular_velocity = 0.0 +1:7/0 = 0 +1:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:7/0/physics_layer_0/angular_velocity = 0.0 +2:7/0 = 0 +2:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:7/0/physics_layer_0/angular_velocity = 0.0 +3:7/0 = 0 +3:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:7/0/physics_layer_0/angular_velocity = 0.0 +4:7/0 = 0 +4:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:7/0/physics_layer_0/angular_velocity = 0.0 +5:7/0 = 0 +5:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:7/0/physics_layer_0/angular_velocity = 0.0 +5:6/0 = 0 +5:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:6/0/physics_layer_0/angular_velocity = 0.0 +4:6/0 = 0 +4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:6/0/physics_layer_0/angular_velocity = 0.0 +3:6/0 = 0 +3:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:6/0/physics_layer_0/angular_velocity = 0.0 +2:6/0 = 0 +2:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:6/0/physics_layer_0/angular_velocity = 0.0 +1:6/0 = 0 +1:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:6/0/physics_layer_0/angular_velocity = 0.0 +0:6/0 = 0 +0:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:6/0/physics_layer_0/angular_velocity = 0.0 +1:5/0 = 0 +1:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:5/0/physics_layer_0/angular_velocity = 0.0 +1:4/0 = 0 +1:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:4/0/physics_layer_0/angular_velocity = 0.0 +1:3/0 = 0 +1:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:3/0/physics_layer_0/angular_velocity = 0.0 +1:2/0 = 0 +1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:2/0/physics_layer_0/angular_velocity = 0.0 +0:2/0 = 0 +0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:2/0/physics_layer_0/angular_velocity = 0.0 +0:1/0 = 0 +0:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:1/0/physics_layer_0/angular_velocity = 0.0 +0:0/0 = 0 +0:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:0/0/physics_layer_0/angular_velocity = 0.0 +0:3/0 = 0 +0:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:3/0/physics_layer_0/angular_velocity = 0.0 +0:4/0 = 0 +0:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:4/0/physics_layer_0/angular_velocity = 0.0 +0:5/0 = 0 +0:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:5/0/physics_layer_0/angular_velocity = 0.0 +1:0/0 = 0 +1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:0/0/physics_layer_0/angular_velocity = 0.0 +1:1/0 = 0 +1:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:1/0/physics_layer_0/angular_velocity = 0.0 +2:5/0 = 0 +2:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:5/0/physics_layer_0/angular_velocity = 0.0 +2:4/0 = 0 +2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:4/0/physics_layer_0/angular_velocity = 0.0 +2:3/0 = 0 +2:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:3/0/physics_layer_0/angular_velocity = 0.0 +2:2/0 = 0 +2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:2/0/physics_layer_0/angular_velocity = 0.0 +2:1/0 = 0 +2:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:1/0/physics_layer_0/angular_velocity = 0.0 +2:0/0 = 0 +2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:0/0/physics_layer_0/angular_velocity = 0.0 +3:1/0 = 0 +3:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:1/0/physics_layer_0/angular_velocity = 0.0 +4:1/0 = 0 +4:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:1/0/physics_layer_0/angular_velocity = 0.0 +4:0/0 = 0 +4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:0/0/physics_layer_0/angular_velocity = 0.0 +3:0/0 = 0 +3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:0/0/physics_layer_0/angular_velocity = 0.0 +5:0/0 = 0 +5:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:0/0/physics_layer_0/angular_velocity = 0.0 +5:1/0 = 0 +5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:1/0/physics_layer_0/angular_velocity = 0.0 +4:2/0 = 0 +4:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:2/0/physics_layer_0/angular_velocity = 0.0 +4:3/0 = 0 +4:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:3/0/physics_layer_0/angular_velocity = 0.0 +4:4/0 = 0 +4:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:4/0/physics_layer_0/angular_velocity = 0.0 +4:5/0 = 0 +4:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:5/0/physics_layer_0/angular_velocity = 0.0 +5:5/0 = 0 +5:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:5/0/physics_layer_0/angular_velocity = 0.0 +5:4/0 = 0 +5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:4/0/physics_layer_0/angular_velocity = 0.0 +5:3/0 = 0 +5:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:3/0/physics_layer_0/angular_velocity = 0.0 +5:2/0 = 0 +5:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:2/0/physics_layer_0/angular_velocity = 0.0 +3:3/0 = 0 +3:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:3/0/physics_layer_0/angular_velocity = 0.0 +3:4/0 = 0 +3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:4/0/physics_layer_0/angular_velocity = 0.0 +3:5/0 = 0 +3:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:5/0/physics_layer_0/angular_velocity = 0.0 +3:2/0 = 0 +3:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:2/0/physics_layer_0/angular_velocity = 0.0 + +[sub_resource type="TileSet" id="TileSet_sjps1"] +tile_size = Vector2i(10, 10) +physics_layer_0/collision_layer = 1 +terrain_set_0/mode = 0 +terrain_set_0/terrain_0/name = "line" +terrain_set_0/terrain_0/color = Color(0, 0, 0, 1) +sources/0 = SubResource("TileSetAtlasSource_5rlqc") + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_4itch"] + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_wusia") + +[node name="ParallaxLayer" type="ParallaxLayer" parent="."] + +[node name="TileMap" parent="." instance=ExtResource("1_380dk")] +tile_set = SubResource("TileSet_sjps1") +layer_0/tile_data = PackedInt32Array(393214, 196608, 4, 393215, 327680, 2, 327680, 131072, 4, 327681, 131072, 4, 327682, 0, 0, 327683, 262144, 0, 327684, 0, 0, 327685, 196608, 4, 327686, 327680, 2, 327687, 262144, 0, 327688, 262144, 0, 327689, 0, 4, 327690, 131072, 0, 327691, 327680, 0, 327692, 196608, 0, 393212, 327680, 4, 393213, 327680, 4, 393206, 65536, 4, 393207, 65536, 0, 393208, 327680, 2, 393209, 0, 4, 393210, 262144, 4, 393211, 196608, 0, 327693, 0, 4, 327694, 131072, 4, 327695, 327680, 0, 327696, 262144, 0, 327697, 0, 0, 327698, 131072, 2, 327699, 131072, 4, 393205, 196608, 0, 393204, 262144, 0, 393203, 196608, 4, 393202, 0, 0, 393201, 196608, 0, 393200, 131072, 0, 393199, 327680, 0, 393198, 0, 0, 393197, 131072, 0, 393196, 262144, 2, 393195, 0, 0, 393194, 0, 0, 393193, 65536, 0, 393192, 327680, 0, 393191, 0, 0, 393190, 262144, 0, 393189, 327680, 4, 393188, 262144, 0, 327700, 65536, 4, 327701, 0, 2, 327702, 262144, 0, 327703, 262144, 2, 327704, 131072, 0, 327705, 0, 4, 327706, 262144, 2, 327707, 262144, 4, 327708, 262144, 2, 327709, 65536, 0, 327710, 327680, 2, 327711, 327680, 2, 327712, 262144, 2, 327713, 327680, 0, 327714, 131072, 2, 327715, 196608, 4, 327716, 196608, 0, 327717, 131072, 0, 327718, 196608, 0, 327719, 65536, 0, 327720, 196608, 0, 327721, 196608, 2, 393187, 0, 0, 393186, 196608, 2, 393185, 327680, 0, 393184, 196608, 0, 393183, 262144, 0, 393182, 65536, 0, 393181, 196608, 0, 393180, 327680, 0, 393179, 65536, 0, 393178, 65536, 2, 131038, 262144, 2, 131039, 262144, 4, 131040, 0, 4, 131041, 131072, 2, 131042, 0, 4, 131043, 327680, 2, 131046, 0, 0, 131047, 262144, 2, 131048, 65536, 4, 131049, 327680, 0, 131050, 131072, 0, 131057, 131072, 2, 131058, 0, 2, 131059, 0, 0, 131060, 327680, 4, 131061, 196608, 2, 131068, 196608, 4, 131069, 0, 2, 131070, 196608, 4, 131071, 262144, 4, 65536, 196608, 2, 65537, 196608, 2, 65543, 131072, 4, 65544, 65536, 4, 65545, 196608, 4, 65546, 262144, 0, 65547, 196608, 2, 65554, 0, 4, 65555, 131072, 2, 65556, 262144, 0, 65557, 131072, 4, 65558, 131072, 0, 65565, 327680, 4, 65566, 196608, 0, 65567, 196608, 4, 65568, 65536, 0, 65573, 196608, 0, 65574, 65536, 0, 65575, 327680, 0, 65576, 131072, 0, -196567, 0, 805306372, -196568, 327680, 805306372, -196569, 327680, 805306370, -196570, 0, 805306370, -196571, 262144, 805306372, -196572, 327680, 805306372, -196573, 262144, 805306368, -196574, 327680, 805306370, -196575, 131072, 805306368, -196576, 196608, 805306370, -196577, 327680, 805306368, -196578, 65536, 805306372, -196579, 0, 805306372, -196580, 131072, 805306370, -196581, 131072, 805306372, -196582, 327680, 805306368, -196583, 327680, 805306372, -196584, 327680, 805306370, -196585, 196608, 805306368, -196586, 65536, 805306370, -196587, 327680, 805306370, -196588, 327680, 805306372, -196589, 65536, 805306370, -196590, 131072, 805306372, -196591, 0, 805306372, -196592, 0, 805306370, -196593, 262144, 805306370, -196594, 131072, 805306370, -196595, 262144, 805306368, -196596, 327680, 805306372, -196597, 196608, 805306370, -196598, 262144, 805306370, -196599, 327680, 805306372, -196600, 131072, 805306370, -196601, 65536, 805306368, -196602, 131072, 805306368, -196603, 327680, 805306368, -196604, 262144, 805306368, -196605, 327680, 805306372, -196606, 65536, 805306372, -196607, 262144, 805306368, -196608, 131072, 805306368, -131073, 327680, 805306368, -131074, 327680, 805306368, -131075, 131072, 805306368, -131076, 196608, 805306372, -131077, 262144, 805306370, -131078, 327680, 805306372, -131079, 131072, 805306372, -131080, 196608, 805306370, -131081, 262144, 805306370, -131082, 196608, 805306370, -131083, 131072, 805306372, -131084, 131072, 805306370, -131085, 262144, 805306370, -131086, 262144, 805306368, -131087, 65536, 805306370, -131088, 327680, 805306370, -131089, 0, 805306368, -131090, 131072, 805306372, -131091, 196608, 805306372, -131092, 0, 805306370, -131093, 262144, 805306370, -131094, 262144, 805306372, -131095, 0, 805306372, -131096, 262144, 805306372, -131097, 196608, 805306370, -131098, 0, 805306372, -131099, 0, 805306370, -131100, 0, 805306368, -131101, 262144, 805306372, -131102, 131072, 805306368, -131103, 262144, 805306368, -131104, 131072, 805306372, -131105, 262144, 805306370, -131106, 65536, 805306372, -131107, 65536, 805306372, -131108, 327680, 805306368, -131109, 0, 805306370, -131110, 131072, 805306372, 786394, 131072, 4, 786395, 327680, 4, 786396, 327680, 2, 786397, 131072, 4, 786398, 262144, 2, 786399, 131072, 0, 786400, 327680, 4, 786401, 196608, 4, 786402, 327680, 2, 786403, 327680, 4, 786404, 131072, 4, 786405, 65536, 4, 786406, 196608, 2, 786407, 131072, 2, 786408, 196608, 4, 786409, 327680, 0, 786410, 196608, 0, 786411, 262144, 4, 786412, 327680, 4, 786413, 262144, 2, 786414, 0, 2, 786415, 196608, 4, 786416, 327680, 2, 786417, 196608, 4, 786418, 131072, 0, 786419, 0, 0, 786420, 65536, 2, 786421, 65536, 2, 786422, 262144, 2, 786423, 196608, 2, 786424, 131072, 0, 786425, 131072, 4, 786426, 262144, 4, 786427, 196608, 2, 786428, 196608, 0, 786429, 196608, 2, 786430, 0, 4, 786431, 196608, 0, 720896, 65536, 0, 720897, 131072, 0, 720898, 196608, 4, 720899, 196608, 4, 720900, 0, 2, 720901, 196608, 0, 720902, 131072, 0, 720903, 262144, 4, 720904, 196608, 4, 720905, 262144, 2, 720906, 131072, 2, 720907, 131072, 2, 720908, 262144, 4, 720909, 0, 4, 720910, 0, 2, 720911, 262144, 4, 720912, 327680, 4, 720913, 196608, 4, 720914, 327680, 2, 720915, 0, 2, 720916, 65536, 4, 720917, 65536, 4, 720918, 0, 4, 720919, 0, 2, 720920, 262144, 4, 720921, 327680, 2, 720922, 327680, 4, 720923, 131072, 4, 720924, 327680, 4, 720925, 196608, 0, 720926, 327680, 2, 720927, 65536, 0, 720928, 131072, 0, 720929, 65536, 4, 720930, 196608, 0, 720931, 262144, 2, 720932, 131072, 0, 720933, 196608, 4, 720934, 131072, 0, 720935, 196608, 0, 720936, 262144, 4, 720937, 131072, 0) + +[node name="TileMap2" parent="." instance=ExtResource("1_380dk")] +tile_set = SubResource("TileSet_sjps1") +layer_0/tile_data = PackedInt32Array(393214, 196608, 4, 393215, 327680, 2, 327680, 131072, 4, 327681, 131072, 4, 327682, 0, 0, 327683, 262144, 0, 327684, 0, 0, 327685, 196608, 4, 327686, 327680, 2, 327687, 262144, 0, 327688, 262144, 0, 327689, 0, 4, 327690, 131072, 0, 327691, 327680, 0, 327692, 196608, 0, 393212, 327680, 4, 393213, 327680, 4, 393206, 65536, 4, 393207, 65536, 0, 393208, 327680, 2, 393209, 0, 4, 393210, 262144, 4, 393211, 196608, 0, 327693, 0, 4, 327694, 131072, 4, 327695, 327680, 0, 327696, 262144, 0, 327697, 0, 0, 327698, 131072, 2, 327699, 131072, 4, 393205, 196608, 0, 393204, 262144, 0, 393203, 196608, 4, 393202, 0, 0, 393201, 196608, 0, 393200, 131072, 0, 393199, 327680, 0, 393198, 0, 0, 393197, 131072, 0, 393196, 262144, 2, 393195, 0, 0, 393194, 0, 0, 393193, 65536, 0, 393192, 327680, 0, 393191, 0, 0, 393190, 262144, 0, 393189, 327680, 4, 393188, 262144, 0, 327700, 65536, 4, 327701, 0, 2, 327702, 262144, 0, 327703, 262144, 2, 327704, 131072, 0, 327705, 0, 4, 327706, 262144, 2, 327707, 262144, 4, 327708, 262144, 2, 327709, 65536, 0, 327710, 327680, 2, 327711, 327680, 2, 327712, 262144, 2, 327713, 327680, 0, 327714, 131072, 2, 327715, 196608, 4, 327716, 196608, 0, 327717, 131072, 0, 327718, 196608, 0, 327719, 65536, 0, 327720, 196608, 0, 327721, 196608, 2, 393187, 0, 0, 393186, 196608, 2, 393185, 327680, 0, 393184, 196608, 0, 393183, 262144, 0, 393182, 65536, 0, 393181, 196608, 0, 393180, 327680, 0, 393179, 65536, 0, 393178, 65536, 2, 131038, 262144, 2, 131039, 262144, 4, 131040, 0, 4, 131041, 131072, 2, 131042, 0, 4, 131043, 327680, 2, 131046, 0, 0, 131047, 262144, 2, 131048, 65536, 4, 131049, 327680, 0, 131050, 131072, 0, 131057, 131072, 2, 131058, 0, 2, 131059, 0, 0, 131060, 327680, 4, 131061, 196608, 2, 131068, 196608, 4, 131069, 0, 2, 131070, 196608, 4, 131071, 262144, 4, 65536, 196608, 2, 65537, 196608, 2, 65543, 131072, 4, 65544, 65536, 4, 65545, 196608, 4, 65546, 262144, 0, 65547, 196608, 2, 65554, 0, 4, 65555, 131072, 2, 65556, 262144, 0, 65557, 131072, 4, 65558, 131072, 0, 65565, 327680, 4, 65566, 196608, 0, 65567, 196608, 4, 65568, 65536, 0, 65573, 196608, 0, 65574, 65536, 0, 65575, 327680, 0, 65576, 131072, 0, -196567, 0, 805306372, -196568, 327680, 805306372, -196569, 327680, 805306370, -196570, 0, 805306370, -196571, 262144, 805306372, -196572, 327680, 805306372, -196573, 262144, 805306368, -196574, 327680, 805306370, -196575, 131072, 805306368, -196576, 196608, 805306370, -196577, 327680, 805306368, -196578, 65536, 805306372, -196579, 0, 805306372, -196580, 131072, 805306370, -196581, 131072, 805306372, -196582, 327680, 805306368, -196583, 327680, 805306372, -196584, 327680, 805306370, -196585, 196608, 805306368, -196586, 65536, 805306370, -196587, 327680, 805306370, -196588, 327680, 805306372, -196589, 65536, 805306370, -196590, 131072, 805306372, -196591, 0, 805306372, -196592, 0, 805306370, -196593, 262144, 805306370, -196594, 131072, 805306370, -196595, 262144, 805306368, -196596, 327680, 805306372, -196597, 196608, 805306370, -196598, 262144, 805306370, -196599, 327680, 805306372, -196600, 131072, 805306370, -196601, 65536, 805306368, -196602, 131072, 805306368, -196603, 327680, 805306368, -196604, 262144, 805306368, -196605, 327680, 805306372, -196606, 65536, 805306372, -196607, 262144, 805306368, -196608, 131072, 805306368, -131073, 327680, 805306368, -131074, 327680, 805306368, -131075, 131072, 805306368, -131076, 196608, 805306372, -131077, 262144, 805306370, -131078, 327680, 805306372, -131079, 131072, 805306372, -131080, 196608, 805306370, -131081, 262144, 805306370, -131082, 196608, 805306370, -131083, 131072, 805306372, -131084, 131072, 805306370, -131085, 262144, 805306370, -131086, 262144, 805306368, -131087, 65536, 805306370, -131088, 327680, 805306370, -131089, 0, 805306368, -131090, 131072, 805306372, -131091, 196608, 805306372, -131092, 0, 805306370, -131093, 262144, 805306370, -131094, 262144, 805306372, -131095, 0, 805306372, -131096, 262144, 805306372, -131097, 196608, 805306370, -131098, 0, 805306372, -131099, 0, 805306370, -131100, 0, 805306368, -131101, 262144, 805306372, -131102, 131072, 805306368, -131103, 262144, 805306368, -131104, 131072, 805306372, -131105, 262144, 805306370, -131106, 65536, 805306372, -131107, 65536, 805306372, -131108, 327680, 805306368, -131109, 0, 805306370, -131110, 131072, 805306372, 786394, 131072, 4, 786395, 327680, 4, 786396, 327680, 2, 786397, 131072, 4, 786398, 262144, 2, 786399, 131072, 0, 786400, 327680, 4, 786401, 196608, 4, 786402, 327680, 2, 786403, 327680, 4, 786404, 131072, 4, 786405, 65536, 4, 786406, 196608, 2, 786407, 131072, 2, 786408, 196608, 4, 786409, 327680, 0, 786410, 196608, 0, 786411, 262144, 4, 786412, 327680, 4, 786413, 262144, 2, 786414, 0, 2, 786415, 196608, 4, 786416, 327680, 2, 786417, 196608, 4, 786418, 131072, 0, 786419, 0, 0, 786420, 65536, 2, 786421, 65536, 2, 786422, 262144, 2, 786423, 196608, 2, 786424, 131072, 0, 786425, 131072, 4, 786426, 262144, 4, 786427, 196608, 2, 786428, 196608, 0, 786429, 196608, 2, 786430, 0, 4, 786431, 196608, 0, 720896, 65536, 0, 720897, 131072, 0, 720898, 196608, 4, 720899, 196608, 4, 720900, 0, 2, 720901, 196608, 0, 720902, 131072, 0, 720903, 262144, 4, 720904, 196608, 4, 720905, 262144, 2, 720906, 131072, 2, 720907, 131072, 2, 720908, 262144, 4, 720909, 0, 4, 720910, 0, 2, 720911, 262144, 4, 720912, 327680, 4, 720913, 196608, 4, 720914, 327680, 2, 720915, 0, 2, 720916, 65536, 4, 720917, 65536, 4, 720918, 0, 4, 720919, 0, 2, 720920, 262144, 4, 720921, 327680, 2, 720922, 327680, 4, 720923, 131072, 4, 720924, 327680, 4, 720925, 196608, 0, 720926, 327680, 2, 720927, 65536, 0, 720928, 131072, 0, 720929, 65536, 4, 720930, 196608, 0, 720931, 262144, 2, 720932, 131072, 0, 720933, 196608, 4, 720934, 131072, 0, 720935, 196608, 0, 720936, 262144, 4, 720937, 131072, 0, -458790, 131072, 4, -458789, 327680, 4, -458788, 327680, 2, -458787, 131072, 4, -458786, 262144, 2, -458785, 131072, 0, -458784, 327680, 4, -458783, 196608, 4, -458782, 327680, 2, -458781, 327680, 4, -458780, 131072, 4, -458779, 65536, 4, -458778, 196608, 2, -458777, 131072, 2, -458776, 196608, 4, -458775, 327680, 0, -458774, 196608, 0, -458773, 262144, 4, -458772, 327680, 4, -458771, 262144, 2, -458770, 0, 2, -458769, 196608, 4, -458768, 327680, 2, -458767, 196608, 4, -458766, 131072, 0, -458765, 0, 0, -458764, 65536, 2, -458763, 65536, 2, -458762, 262144, 2, -458761, 196608, 2, -458760, 131072, 0, -458759, 131072, 4, -458758, 262144, 4, -458757, 196608, 2, -458756, 196608, 0, -458755, 196608, 2, -458754, 0, 4, -458753, 196608, 0, -524288, 65536, 0, -524287, 131072, 0, -524286, 196608, 4, -524285, 196608, 4, -524284, 0, 2, -524283, 196608, 0, -524282, 131072, 0, -524281, 262144, 4, -524280, 196608, 4, -524279, 262144, 2, -524278, 131072, 2, -524277, 131072, 2, -524276, 262144, 4, -524275, 0, 4, -524274, 0, 2, -524273, 262144, 4, -524272, 327680, 4, -524271, 196608, 4, -524270, 327680, 2, -524269, 0, 2, -524268, 65536, 4, -524267, 65536, 4, -524266, 0, 4, -524265, 0, 2, -524264, 262144, 4, -524263, 327680, 2, -524262, 327680, 4, -524261, 131072, 4, -524260, 327680, 4, -524259, 196608, 0, -524258, 327680, 2, -524257, 65536, 0, -524256, 131072, 0, -524255, 65536, 4, -524254, 196608, 0, -524253, 262144, 2, -524252, 131072, 0, -524251, 196608, 4, -524250, 131072, 0, -524249, 196608, 0, -524248, 262144, 4, -524247, 131072, 0) + +[node name="plr" parent="." instance=ExtResource("3_wha8j")] +position = Vector2(-16, 7) + +[node name="CharacterBody2D2" type="CharacterBody2D" parent="."] +position = Vector2(52, 27) +script = ExtResource("8_cre0a") + +[node name="torso" type="Node2D" parent="CharacterBody2D2"] + +[node name="Torso" type="Sprite2D" parent="CharacterBody2D2/torso"] +position = Vector2(0, 10) +texture = ExtResource("4_a8t6b") + +[node name="head" type="Node2D" parent="CharacterBody2D2"] + +[node name="Head" type="Sprite2D" parent="CharacterBody2D2/head"] +position = Vector2(-1, -11) +texture = ExtResource("5_e7dox") + +[node name="face" type="Node2D" parent="CharacterBody2D2"] +position = Vector2(2, -8) + +[node name="Face" type="Sprite2D" parent="CharacterBody2D2/face"] +texture = ExtResource("6_skr4v") + +[node name="GPUParticles2D" parent="CharacterBody2D2" instance=ExtResource("7_6fex8")] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="CharacterBody2D2"] +shape = SubResource("RectangleShape2D_4itch") + +[node name="CharacterBody2D3" type="CharacterBody2D" parent="."] +position = Vector2(-140, 30) +script = ExtResource("8_cre0a") + +[node name="torso" type="Node2D" parent="CharacterBody2D3"] + +[node name="Torso" type="Sprite2D" parent="CharacterBody2D3/torso"] +position = Vector2(0, 10) +texture = ExtResource("4_a8t6b") + +[node name="head" type="Node2D" parent="CharacterBody2D3"] + +[node name="Head" type="Sprite2D" parent="CharacterBody2D3/head"] +position = Vector2(-1, -11) +texture = ExtResource("5_e7dox") + +[node name="face" type="Node2D" parent="CharacterBody2D3"] +position = Vector2(2, -8) + +[node name="Face" type="Sprite2D" parent="CharacterBody2D3/face"] +texture = ExtResource("6_skr4v") + +[node name="GPUParticles2D" parent="CharacterBody2D3" instance=ExtResource("7_6fex8")] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="CharacterBody2D3"] +shape = SubResource("RectangleShape2D_4itch") + +[node name="CharacterBody2D4" type="CharacterBody2D" parent="."] +position = Vector2(-24, -92) +script = ExtResource("8_cre0a") + +[node name="torso" type="Node2D" parent="CharacterBody2D4"] + +[node name="Torso" type="Sprite2D" parent="CharacterBody2D4/torso"] +position = Vector2(0, 10) +texture = ExtResource("4_a8t6b") + +[node name="head" type="Node2D" parent="CharacterBody2D4"] + +[node name="Head" type="Sprite2D" parent="CharacterBody2D4/head"] +position = Vector2(-1, -11) +texture = ExtResource("5_e7dox") + +[node name="face" type="Node2D" parent="CharacterBody2D4"] +position = Vector2(2, -8) + +[node name="Face" type="Sprite2D" parent="CharacterBody2D4/face"] +texture = ExtResource("6_skr4v") + +[node name="GPUParticles2D" parent="CharacterBody2D4" instance=ExtResource("7_6fex8")] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="CharacterBody2D4"] +shape = SubResource("RectangleShape2D_4itch") + +[node name="CharacterBody2D5" type="CharacterBody2D" parent="."] +position = Vector2(-22, 132) +script = ExtResource("8_cre0a") + +[node name="torso" type="Node2D" parent="CharacterBody2D5"] + +[node name="Torso" type="Sprite2D" parent="CharacterBody2D5/torso"] +position = Vector2(0, 10) +texture = ExtResource("4_a8t6b") + +[node name="head" type="Node2D" parent="CharacterBody2D5"] + +[node name="Head" type="Sprite2D" parent="CharacterBody2D5/head"] +position = Vector2(-1, -11) +texture = ExtResource("5_e7dox") + +[node name="face" type="Node2D" parent="CharacterBody2D5"] +position = Vector2(2, -8) + +[node name="Face" type="Sprite2D" parent="CharacterBody2D5/face"] +texture = ExtResource("6_skr4v") + +[node name="GPUParticles2D" parent="CharacterBody2D5" instance=ExtResource("7_6fex8")] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="CharacterBody2D5"] +shape = SubResource("RectangleShape2D_4itch") + +[node name="dog" parent="." instance=ExtResource("9_1v6uv")] +position = Vector2(201, 77) diff --git a/tscn/die.gd b/tscn/die.gd new file mode 100644 index 0000000..4e71ce9 --- /dev/null +++ b/tscn/die.gd @@ -0,0 +1,10 @@ +extends CharacterBody2D + + + +func die(): + var emitter = preload("res://tscn/enemyhitbox.tscn").instantiate() + get_parent().add_child(emitter) + emitter.position = self.position + emitter.emitting = true + queue_free() diff --git a/tscn/dog.gd b/tscn/dog.gd new file mode 100644 index 0000000..408411a --- /dev/null +++ b/tscn/dog.gd @@ -0,0 +1,27 @@ +extends CharacterBody2D + +@onready var plr = get_tree().current_scene.get_node("plr") +const SPEED = 300 +func _physics_process(delta): + # Add the gravity. + if position.distance_to(plr.position) <= 200: + $AnimationPlayer.current_animation = "attack" + set_process(true) + + +func _ready(): + set_process(false) + +func _process(delta): + var dir = (plr.position - self.global_position).normalized() + velocity = dir * SPEED + if not round(dir.x) == 0: + $body.scale.x = round(dir.x) + move_and_slide() + +func die(): + var emitter = preload("res://tscn/enemyhitbox.tscn").instantiate() + get_parent().add_child(emitter) + emitter.position = self.position + emitter.emitting = true + queue_free() diff --git a/tscn/dog.tscn b/tscn/dog.tscn new file mode 100644 index 0000000..39a223b --- /dev/null +++ b/tscn/dog.tscn @@ -0,0 +1,314 @@ +[gd_scene load_steps=10 format=3 uid="uid://bpjluewfoh3fx"] + +[ext_resource type="Texture2D" uid="uid://dl013bmiia5bo" path="res://assets/dog/torso.png" id="1_5vi4g"] +[ext_resource type="Script" path="res://tscn/dog.gd" id="1_oog3t"] +[ext_resource type="Texture2D" uid="uid://bn4k2g7ye2jrq" path="res://assets/dog/head.png" id="2_hw6xc"] +[ext_resource type="Texture2D" uid="uid://dddx6l8owf5x6" path="res://assets/dog/face.png" id="3_soffl"] + +[sub_resource type="Animation" id="Animation_o38oe"] +resource_name = "Idle" +length = 2.0 +loop_mode = 1 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("body/Torso2:position") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(0, 0)] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("body/Torso2:rotation") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("body/Head2:position") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0, 1), +"transitions": PackedFloat32Array(2, 2), +"update": 0, +"values": [Vector2(0, 0), Vector2(0, 2)] +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("body/Head2:rotation") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0, 1), +"transitions": PackedFloat32Array(2, 2), +"update": 0, +"values": [0.0, 0.0] +} +tracks/4/type = "value" +tracks/4/imported = false +tracks/4/enabled = true +tracks/4/path = NodePath("body/Face2:position") +tracks/4/interp = 2 +tracks/4/loop_wrap = true +tracks/4/keys = { +"times": PackedFloat32Array(0, 0.31058, 1, 1.3), +"transitions": PackedFloat32Array(1, 1, 1, 1), +"update": 0, +"values": [Vector2(2, -8), Vector2(2, -8), Vector2(2, -6), Vector2(2, -6)] +} +tracks/5/type = "value" +tracks/5/imported = false +tracks/5/enabled = true +tracks/5/path = NodePath("body/Face2:rotation") +tracks/5/interp = 1 +tracks/5/loop_wrap = true +tracks/5/keys = { +"times": PackedFloat32Array(0, 0.31058, 1, 1.3), +"transitions": PackedFloat32Array(1, 1, 1, 1), +"update": 0, +"values": [0.0, 0.0, 0.0, 0.0] +} +tracks/6/type = "value" +tracks/6/imported = false +tracks/6/enabled = true +tracks/6/path = NodePath("body/Torso2:skew") +tracks/6/interp = 1 +tracks/6/loop_wrap = true +tracks/6/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} + +[sub_resource type="Animation" id="Animation_0l02f"] +length = 0.001 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("body/Torso2:position") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(0, 0)] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("body/Torso2:rotation") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("body/Head2:position") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(0, 0)] +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("body/Head2:rotation") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/4/type = "value" +tracks/4/imported = false +tracks/4/enabled = true +tracks/4/path = NodePath("body/Face2:position") +tracks/4/interp = 1 +tracks/4/loop_wrap = true +tracks/4/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(2, -8)] +} +tracks/5/type = "value" +tracks/5/imported = false +tracks/5/enabled = true +tracks/5/path = NodePath("body/Face2:rotation") +tracks/5/interp = 1 +tracks/5/loop_wrap = true +tracks/5/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/6/type = "value" +tracks/6/imported = false +tracks/6/enabled = true +tracks/6/path = NodePath("body/Torso2:skew") +tracks/6/interp = 1 +tracks/6/loop_wrap = true +tracks/6/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} + +[sub_resource type="Animation" id="Animation_gbjf2"] +resource_name = "attack" +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("body/Torso2:position") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(0, 0)] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("body/Torso2:rotation") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("body/Head2:position") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(0, 0)] +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("body/Head2:rotation") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/4/type = "value" +tracks/4/imported = false +tracks/4/enabled = true +tracks/4/path = NodePath("body/Face2:position") +tracks/4/interp = 1 +tracks/4/loop_wrap = true +tracks/4/keys = { +"times": PackedFloat32Array(0, 1), +"transitions": PackedFloat32Array(1, 1), +"update": 0, +"values": [Vector2(2, -8), Vector2(3, -6)] +} +tracks/5/type = "value" +tracks/5/imported = false +tracks/5/enabled = true +tracks/5/path = NodePath("body/Face2:rotation") +tracks/5/interp = 1 +tracks/5/loop_wrap = true +tracks/5/keys = { +"times": PackedFloat32Array(0, 1), +"transitions": PackedFloat32Array(1, 1), +"update": 0, +"values": [0.0, 0.0] +} +tracks/6/type = "value" +tracks/6/imported = false +tracks/6/enabled = true +tracks/6/path = NodePath("body/Torso2:skew") +tracks/6/interp = 1 +tracks/6/loop_wrap = true +tracks/6/keys = { +"times": PackedFloat32Array(0, 0.5), +"transitions": PackedFloat32Array(1, 1), +"update": 0, +"values": [0.0, 0.380482] +} + +[sub_resource type="AnimationLibrary" id="AnimationLibrary_7yvlc"] +_data = { +"Idle": SubResource("Animation_o38oe"), +"RESET": SubResource("Animation_0l02f"), +"attack": SubResource("Animation_gbjf2") +} + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_nakw7"] +size = Vector2(20, 26.5) + +[node name="dog" type="CharacterBody2D"] +script = ExtResource("1_oog3t") + +[node name="body" type="Node2D" parent="."] + +[node name="Torso2" type="Node2D" parent="body"] + +[node name="Torso" type="Sprite2D" parent="body/Torso2"] +position = Vector2(0, 9) +texture = ExtResource("1_5vi4g") + +[node name="Head2" type="Node2D" parent="body"] + +[node name="Head" type="Sprite2D" parent="body/Head2"] +position = Vector2(0, -11) +texture = ExtResource("2_hw6xc") + +[node name="Face2" type="Node2D" parent="body"] +position = Vector2(2, -8) + +[node name="Face" type="Sprite2D" parent="body/Face2"] +position = Vector2(-1, 0) +texture = ExtResource("3_soffl") + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +libraries = { +"": SubResource("AnimationLibrary_7yvlc") +} +autoplay = "Idle" +blend_times = [&"attack", &"Idle", 2.0] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +position = Vector2(0, -1.75) +shape = SubResource("RectangleShape2D_nakw7") diff --git a/tscn/enemyhitbox.tscn b/tscn/enemyhitbox.tscn new file mode 100644 index 0000000..21f13e7 --- /dev/null +++ b/tscn/enemyhitbox.tscn @@ -0,0 +1,23 @@ +[gd_scene load_steps=2 format=3 uid="uid://dx20e0gj3og1l"] + +[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_oatse"] +particle_flag_disable_z = true +angular_velocity_min = 720.0 +angular_velocity_max = 720.0 +radial_velocity_min = -82.29 +radial_velocity_max = 251.04 +gravity = Vector3(0, 98, 0) +linear_accel_min = -37.25 +linear_accel_max = 100.0 +tangential_accel_min = -100.0 +tangential_accel_max = 100.0 +damping_max = 100.0 +color = Color(1, 0.34902, 0.266667, 1) + +[node name="GPUParticles2D" type="GPUParticles2D"] +emitting = false +amount = 26 +process_material = SubResource("ParticleProcessMaterial_oatse") +one_shot = true +explosiveness = 1.0 +randomness = 1.0 diff --git a/tscn/gun.gd b/tscn/gun.gd new file mode 100644 index 0000000..495d6fb --- /dev/null +++ b/tscn/gun.gd @@ -0,0 +1,17 @@ +extends Node2D + + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + var dir = (get_global_mouse_position() - global_position).normalized() + global_rotation = dir.angle() + PI / 2.0 + if global_rotation < 0: + $Sprite2D.flip_v = true + else: + $Sprite2D.flip_v = false + diff --git a/tscn/lines.tscn b/tscn/lines.tscn index 228af9c..f680b84 100644 --- a/tscn/lines.tscn +++ b/tscn/lines.tscn @@ -2,12 +2,99 @@ [ext_resource type="Texture2D" uid="uid://tyvdq4i2kfx7" path="res://assets/lines.png" id="1_pcy5j"] -[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_5rlqc"] +[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_off2p"] texture = ExtResource("1_pcy5j") texture_region_size = Vector2i(10, 10) -0:7/0 = 0 -0:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:7/0/physics_layer_0/angular_velocity = 0.0 +0:0/0 = 0 +0:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:0/0/physics_layer_0/angular_velocity = 0.0 +0:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +1:0/0 = 0 +1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:0/0/physics_layer_0/angular_velocity = 0.0 +1:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +2:0/0 = 0 +2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:0/0/physics_layer_0/angular_velocity = 0.0 +2:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +3:0/0 = 0 +3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:0/0/physics_layer_0/angular_velocity = 0.0 +3:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +4:0/0 = 0 +4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:0/0/physics_layer_0/angular_velocity = 0.0 +4:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +5:0/0 = 0 +5:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:0/0/physics_layer_0/angular_velocity = 0.0 +5:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +0:2/0 = 0 +0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:2/0/physics_layer_0/angular_velocity = 0.0 +0:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +1:2/0 = 0 +1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:2/0/physics_layer_0/angular_velocity = 0.0 +1:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +2:2/0 = 0 +2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:2/0/physics_layer_0/angular_velocity = 0.0 +2:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +3:2/0 = 0 +3:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:2/0/physics_layer_0/angular_velocity = 0.0 +3:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +4:2/0 = 0 +4:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:2/0/physics_layer_0/angular_velocity = 0.0 +4:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +5:2/0 = 0 +5:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:2/0/physics_layer_0/angular_velocity = 0.0 +5:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +0:4/0 = 0 +0:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:4/0/physics_layer_0/angular_velocity = 0.0 +0:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +1:4/0 = 0 +1:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:4/0/physics_layer_0/angular_velocity = 0.0 +1:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +2:4/0 = 0 +2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:4/0/physics_layer_0/angular_velocity = 0.0 +2:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +3:4/0 = 0 +3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:4/0/physics_layer_0/angular_velocity = 0.0 +3:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +4:4/0 = 0 +4:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:4/0/physics_layer_0/angular_velocity = 0.0 +4:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +5:4/0 = 0 +5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:4/0/physics_layer_0/angular_velocity = 0.0 +5:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -3.5, 5, -3.5, 5, 0, -5, 0) +1:5/0 = 0 +1:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) +1:5/0/physics_layer_0/angular_velocity = 0.0 +0:6/0 = 0 +0:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +0:6/0/physics_layer_0/angular_velocity = 0.0 +2:6/0 = 0 +2:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +2:6/0/physics_layer_0/angular_velocity = 0.0 +3:6/0 = 0 +3:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +3:6/0/physics_layer_0/angular_velocity = 0.0 +4:6/0 = 0 +4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +4:6/0/physics_layer_0/angular_velocity = 0.0 +5:6/0 = 0 +5:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) +5:6/0/physics_layer_0/angular_velocity = 0.0 1:7/0 = 0 1:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) 1:7/0/physics_layer_0/angular_velocity = 0.0 @@ -23,150 +110,6 @@ texture_region_size = Vector2i(10, 10) 5:7/0 = 0 5:7/0/physics_layer_0/linear_velocity = Vector2(0, 0) 5:7/0/physics_layer_0/angular_velocity = 0.0 -5:6/0 = 0 -5:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:6/0/physics_layer_0/angular_velocity = 0.0 -4:6/0 = 0 -4:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:6/0/physics_layer_0/angular_velocity = 0.0 -3:6/0 = 0 -3:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:6/0/physics_layer_0/angular_velocity = 0.0 -2:6/0 = 0 -2:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:6/0/physics_layer_0/angular_velocity = 0.0 -1:6/0 = 0 -1:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:6/0/physics_layer_0/angular_velocity = 0.0 -0:6/0 = 0 -0:6/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:6/0/physics_layer_0/angular_velocity = 0.0 -1:5/0 = 0 -1:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:5/0/physics_layer_0/angular_velocity = 0.0 -1:4/0 = 0 -1:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:4/0/physics_layer_0/angular_velocity = 0.0 -1:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -1:3/0 = 0 -1:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:3/0/physics_layer_0/angular_velocity = 0.0 -1:2/0 = 0 -1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:2/0/physics_layer_0/angular_velocity = 0.0 -1:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -0:2/0 = 0 -0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:2/0/physics_layer_0/angular_velocity = 0.0 -0:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -0:1/0 = 0 -0:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:1/0/physics_layer_0/angular_velocity = 0.0 -0:0/0 = 0 -0:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:0/0/physics_layer_0/angular_velocity = 0.0 -0:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -0:3/0 = 0 -0:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:3/0/physics_layer_0/angular_velocity = 0.0 -0:4/0 = 0 -0:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:4/0/physics_layer_0/angular_velocity = 0.0 -0:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -0:5/0 = 0 -0:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -0:5/0/physics_layer_0/angular_velocity = 0.0 -1:0/0 = 0 -1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:0/0/physics_layer_0/angular_velocity = 0.0 -1:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -1:1/0 = 0 -1:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -1:1/0/physics_layer_0/angular_velocity = 0.0 -2:5/0 = 0 -2:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:5/0/physics_layer_0/angular_velocity = 0.0 -2:4/0 = 0 -2:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:4/0/physics_layer_0/angular_velocity = 0.0 -2:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -2:3/0 = 0 -2:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:3/0/physics_layer_0/angular_velocity = 0.0 -2:2/0 = 0 -2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:2/0/physics_layer_0/angular_velocity = 0.0 -2:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -2:1/0 = 0 -2:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:1/0/physics_layer_0/angular_velocity = 0.0 -2:0/0 = 0 -2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -2:0/0/physics_layer_0/angular_velocity = 0.0 -2:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -3:1/0 = 0 -3:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:1/0/physics_layer_0/angular_velocity = 0.0 -4:1/0 = 0 -4:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:1/0/physics_layer_0/angular_velocity = 0.0 -4:0/0 = 0 -4:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:0/0/physics_layer_0/angular_velocity = 0.0 -4:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -3:0/0 = 0 -3:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:0/0/physics_layer_0/angular_velocity = 0.0 -3:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -5:0/0 = 0 -5:0/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:0/0/physics_layer_0/angular_velocity = 0.0 -5:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -5:1/0 = 0 -5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:1/0/physics_layer_0/angular_velocity = 0.0 -4:2/0 = 0 -4:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:2/0/physics_layer_0/angular_velocity = 0.0 -4:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -4:3/0 = 0 -4:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:3/0/physics_layer_0/angular_velocity = 0.0 -4:4/0 = 0 -4:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:4/0/physics_layer_0/angular_velocity = 0.0 -4:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -4:5/0 = 0 -4:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -4:5/0/physics_layer_0/angular_velocity = 0.0 -5:5/0 = 0 -5:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:5/0/physics_layer_0/angular_velocity = 0.0 -5:4/0 = 0 -5:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:4/0/physics_layer_0/angular_velocity = 0.0 -5:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -5:3/0 = 0 -5:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:3/0/physics_layer_0/angular_velocity = 0.0 -5:2/0 = 0 -5:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -5:2/0/physics_layer_0/angular_velocity = 0.0 -5:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -3:3/0 = 0 -3:3/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:3/0/physics_layer_0/angular_velocity = 0.0 -3:4/0 = 0 -3:4/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:4/0/physics_layer_0/angular_velocity = 0.0 -3:4/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) -3:5/0 = 0 -3:5/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:5/0/physics_layer_0/angular_velocity = 0.0 -3:2/0 = 0 -3:2/0/physics_layer_0/linear_velocity = Vector2(0, 0) -3:2/0/physics_layer_0/angular_velocity = 0.0 -3:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-5, -4, 5, -4, 5, -2.125, -5, -2.125) [sub_resource type="TileSet" id="TileSet_uqloi"] tile_size = Vector2i(10, 10) @@ -174,7 +117,7 @@ physics_layer_0/collision_layer = 1 terrain_set_0/mode = 0 terrain_set_0/terrain_0/name = "line" terrain_set_0/terrain_0/color = Color(0, 0, 0, 1) -sources/0 = SubResource("TileSetAtlasSource_5rlqc") +sources/1 = SubResource("TileSetAtlasSource_off2p") [node name="TileMap" type="TileMap"] tile_set = SubResource("TileSet_uqloi") diff --git a/tscn/main.tscn b/tscn/main.tscn index 2fcc936..3dbef6d 100644 --- a/tscn/main.tscn +++ b/tscn/main.tscn @@ -35,12 +35,12 @@ flip_h = true [node name="TileMap" parent="." instance=ExtResource("2_s78l6")] layer_0/name = "decoration" -layer_0/tile_data = PackedInt32Array(1376272, 131072, 4, 1376273, 65536, 0, 1376274, 327680, 4, 1376275, 65536, 2, 1376276, 327680, 4, 1376277, 327680, 4, 1376278, 196608, 2, 1376279, 0, 0, 1376280, 131072, 0, 1376281, 196608, 0, 1376282, 327680, 2, 1376283, 327680, 2, 1376284, 262144, 0, 1376285, 196608, 4, 1376286, 262144, 2, 1376287, 65536, 2, 1376288, 262144, 2, 1376289, 262144, 4, 1376290, 196608, 2, 1376291, 327680, 2) +layer_0/tile_data = PackedInt32Array(1376272, 327681, 0, 1376273, 262145, 0, 1376274, 196609, 0, 1376275, 65537, 0, 1376276, 65537, 0, 1376277, 196609, 0, 1376278, 196609, 0, 1376279, 196609, 0, 1376280, 327681, 0, 1376281, 1, 0, 1376282, 1, 0, 1376283, 1, 0, 1376284, 196609, 0, 1376285, 327681, 0, 1376286, 65537, 0, 1376287, 327681, 0, 1376288, 196609, 0, 1376289, 1, 0, 1376290, 131073, 0, 1376291, 262145, 0) layer_1/name = "lines" layer_1/z_index = 1 -layer_1/tile_data = PackedInt32Array(2097173, 0, 0, 2097174, 65536, 0, 2097175, 131072, 0, 2097176, 0, 0, 2097177, 65536, 0, 2097178, 131072, 0, 2097179, 0, 0, 2097180, 65536, 0, 2097181, 131072, 0, 2097182, 0, 0, 2097183, 65536, 0, 2097184, 131072, 0, 2097185, 196608, 0, 2097186, 262144, 0, 2097187, 327680, 0, 1900580, 131072, 1610612738, 1966116, 65536, 1610612738, 2031652, 0, 1610612738, 1703972, 131072, 1610612738, 1769508, 65536, 1610612738, 1835044, 0, 1610612738, 1507364, 131072, 1610612738, 1572900, 65536, 1610612738, 1638436, 0, 1610612738, 1310756, 131072, 1610612738, 1376292, 65536, 1610612738, 1441828, 0, 1610612738, 1114148, 131072, 1610612738, 1179684, 65536, 1610612738, 1245220, 0, 1610612738, 2097171, 0, 0, 2097172, 65536, 0, 2097168, 0, 0, 2097169, 65536, 0, 2097170, 65536, 2, 2097188, 0, 6, 2097167, 0, 268435462, 1900559, 131072, 1342177284, 1966095, 196608, 1342177284, 2031631, 262144, 1342177284, 1835023, 327680, 1342177284, 1638415, 65536, 1342177282, 1703951, 131072, 1342177282, 1769487, 196608, 1342177282, 1441807, 65536, 1342177280, 1507343, 131072, 1342177280, 1572879, 196608, 1342177280, 1310735, 65536, 1342177282, 1376271, 131072, 1342177282, 1114127, 65536, 1342177282, 1179663, 131072, 1342177282, 1245199, 196608, 1342177282, 720913, 196608, 536870914, 720914, 0, 536870916, 720915, 131072, 536870916, 720916, 327680, 536870916, 720917, 0, 536870914, 720918, 131072, 536870912, 720919, 131072, 536870914, 720920, 0, 536870916, 720921, 327680, 536870914, 720922, 327680, 536870912, 720923, 262144, 536870916, 720924, 196608, 536870916, 720925, 327680, 536870912, 720926, 327680, 536870916, 720927, 262144, 536870912, 720928, 262144, 536870916, 720929, 327680, 536870914, 720930, 327680, 536870916, 720931, 327680, 536870912, 852004, 262144, 1073741828, 917540, 196608, 1073741826, 983076, 327680, 1073741826, 1048612, 65536, 1073741824, 786468, 262144, 1073741824, 1048591, 327680, 1879048194, 983055, 131072, 1879048194, 917519, 262144, 1879048194, 851983, 262144, 1879048196, 786447, 327680, 1879048192, 720912, 131072, 536870914, 720932, 0, 1610612742, 720911, 0, 1879048198) +layer_1/tile_data = PackedInt32Array(2097173, 262145, 2, 2097174, 196609, 0, 2097175, 196609, 0, 2097176, 327681, 0, 2097177, 65537, 2, 2097178, 1, 2, 2097179, 327681, 2, 2097180, 327681, 2, 2097181, 327681, 0, 2097182, 131073, 2, 2097183, 327681, 2, 2097184, 131073, 0, 2097185, 262145, 2, 2097186, 131073, 0, 2097187, 65537, 2, 1900580, 65537, 1610612736, 1966116, 1, 1610612738, 2031652, 196609, 1610612738, 1703972, 196609, 1610612736, 1769508, 262145, 1610612736, 1835044, 196609, 1610612736, 1507364, 196609, 1610612738, 1572900, 1, 1610612736, 1638436, 1, 1610612736, 1310756, 1, 1610612738, 1376292, 65537, 1610612738, 1441828, 196609, 1610612736, 1114148, 196609, 1610612738, 1179684, 196609, 1610612736, 1245220, 196609, 1610612738, 2097171, 65537, 0, 2097172, 196609, 0, 2097168, 262145, 2, 2097169, 327681, 2, 2097170, 131073, 2, 2097188, 1, 6, 2097167, 1, 1342177286, 1900559, 196609, 1342177280, 1966095, 196609, 1342177282, 2031631, 131073, 1342177284, 1835023, 262145, 1342177284, 1638415, 1, 1342177282, 1703951, 262145, 1342177280, 1769487, 65537, 1342177282, 1441807, 327681, 1342177282, 1507343, 262145, 1342177282, 1572879, 1, 1342177284, 1310735, 131073, 1342177280, 1376271, 131073, 1342177280, 1114127, 1, 1342177282, 1179663, 131073, 1342177280, 1245199, 65537, 1342177282, 720913, 196609, 805306372, 720914, 196609, 805306370, 720915, 196609, 805306368, 720916, 65537, 805306372, 720917, 327681, 805306370, 720918, 327681, 805306368, 720919, 196609, 805306368, 720920, 131073, 805306368, 720921, 131073, 805306372, 720922, 327681, 805306368, 720923, 327681, 805306370, 720924, 327681, 805306368, 720925, 131073, 805306370, 720926, 262145, 805306372, 720927, 65537, 805306372, 720928, 262145, 805306368, 720929, 196609, 805306368, 720930, 327681, 805306372, 720931, 1, 805306370, 852004, 327681, 1610612738, 917540, 327681, 1610612738, 983076, 1, 1610612738, 1048612, 1, 1610612738, 786468, 262145, 1610612736, 1048591, 262145, 1342177280, 983055, 196609, 1342177282, 917519, 1, 1342177282, 851983, 1, 1342177284, 786447, 196609, 1342177282, 720912, 262145, 805306370, 720932, 1, 1610612742, 720911, 1, 805306374) -[node name="CharacterBody2D" parent="." instance=ExtResource("1_wgp3w")] +[node name="plr" parent="." instance=ExtResource("1_wgp3w")] position = Vector2(266, 225) moving = false diff --git a/tscn/playmouseparticle.tscn b/tscn/playmouseparticle.tscn new file mode 100644 index 0000000..3b238a1 --- /dev/null +++ b/tscn/playmouseparticle.tscn @@ -0,0 +1,22 @@ +[gd_scene load_steps=3 format=3 uid="uid://d3s7rw1f7fct7"] + +[ext_resource type="Script" path="res://mouseparticle.gd" id="2_2bcct"] + +[sub_resource type="Curve" id="Curve_meyv8"] +bake_resolution = 2 +_data = [Vector2(0, 0), 0.0, 0.0, 0, 0, Vector2(1, 1), 0.0, 0.0, 0, 0] +point_count = 2 + +[node name="GPUParticles2D" type="Line2D"] +process_priority = 2 +process_physics_priority = 2 +process_thread_group = 2 +process_thread_group_order = 0 +process_thread_messages = 3 +width = 2.0 +width_curve = SubResource("Curve_meyv8") +default_color = Color(0, 0, 0, 1) +joint_mode = 2 +begin_cap_mode = 2 +end_cap_mode = 2 +script = ExtResource("2_2bcct") diff --git a/tscn/plr.tscn b/tscn/plr.tscn index 3b1bafb..5344fa3 100644 --- a/tscn/plr.tscn +++ b/tscn/plr.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=17 format=3 uid="uid://ceqnn4bkdnnkg"] +[gd_scene load_steps=21 format=3 uid="uid://ceqnn4bkdnnkg"] [ext_resource type="Script" path="res://scripts/plr.gd" id="1_37nf0"] [ext_resource type="Texture2D" uid="uid://cw5k2tw74rt44" path="res://assets/plr/face.png" id="1_kh4l2"] @@ -7,8 +7,15 @@ [ext_resource type="Texture2D" uid="uid://e61exatotusn" path="res://assets/plr/torso.png" id="3_llt4k"] [ext_resource type="Texture2D" uid="uid://b2wwc74rumj6b" path="res://assets/textbox.png" id="5_ljw5m"] [ext_resource type="Script" path="res://scripts/typewrite.gd" id="6_bjl34"] +[ext_resource type="Texture2D" uid="uid://dw415r5q7gjav" path="res://assets/sheet02.png" id="6_c11rc"] [ext_resource type="FontFile" uid="uid://dit6605nx68qb" path="res://assets/HackerBasic.ttf" id="6_m1vy8"] +[ext_resource type="Script" path="res://tscn/gun.gd" id="6_qq4o0"] [ext_resource type="AudioStream" uid="uid://wc2udhbh21la" path="res://sfx/meow.wav" id="9_kn63i"] +[ext_resource type="Texture2D" uid="uid://3cpa43wrk5ih" path="res://assets/chores.png" id="10_relgi"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_2fw5x"] +atlas = ExtResource("6_c11rc") +region = Rect2(152, 35, 11, 8) [sub_resource type="Animation" id="Animation_kxab8"] length = 0.001 @@ -477,7 +484,7 @@ RichTextLabel/fonts/normal_font = ExtResource("6_m1vy8") [sub_resource type="RectangleShape2D" id="RectangleShape2D_171aa"] size = Vector2(24, 15) -[node name="CharacterBody2D" type="CharacterBody2D"] +[node name="plr" type="CharacterBody2D"] script = ExtResource("1_37nf0") [node name="character" type="Node2D" parent="."] @@ -521,6 +528,15 @@ position = Vector2(-5, -4) texture = ExtResource("1_kh4l2") centered = false +[node name="gun" type="Node2D" parent="."] +position = Vector2(-8, 28) +script = ExtResource("6_qq4o0") + +[node name="Sprite2D" type="Sprite2D" parent="gun"] +position = Vector2(0, -3) +rotation = -1.57079 +texture = SubResource("AtlasTexture_2fw5x") + [node name="AnimationPlayer" type="AnimationPlayer" parent="."] libraries = { "": SubResource("AnimationLibrary_8tlfi") @@ -561,7 +577,71 @@ stream = ExtResource("9_kn63i") [node name="Camera2D" type="Camera2D" parent="."] position = Vector2(-1, -1) +position_smoothing_enabled = true +drag_horizontal_enabled = true +drag_vertical_enabled = true +drag_left_margin = 0.3 +drag_top_margin = 0.3 +drag_right_margin = 0.3 +drag_bottom_margin = 0.3 [node name="CollisionShape2D" type="CollisionShape2D" parent="."] position = Vector2(-2, 28.5) shape = SubResource("RectangleShape2D_171aa") + +[node name="chores" type="CanvasLayer" parent="."] + +[node name="Sprite2D2" type="Sprite2D" parent="chores"] +visible = false +position = Vector2(519, 70) +texture = ExtResource("10_relgi") + +[node name="RichTextLabel2" type="RichTextLabel" parent="chores/Sprite2D2"] +modulate = Color(1, 1, 1, 0.407843) +clip_contents = false +offset_left = -43.0 +offset_top = -34.0 +offset_right = 49.0 +offset_bottom = 58.0 +theme = SubResource("Theme_lpkn8") +theme_override_font_sizes/normal_font_size = 22 +text = "Buy fish + +talk to friends + +Do homework + +thanks. + + -you" +scroll_active = false + +[node name="1" type="ColorRect" parent="chores/Sprite2D2"] +visible = false +offset_left = -45.0 +offset_top = -23.0 +offset_right = 7.0 +offset_bottom = -21.0 +color = Color(0.52549, 0.52549, 0.52549, 1) + +[node name="2" type="ColorRect" parent="chores/Sprite2D2"] +visible = false +offset_left = -44.0 +offset_top = -5.0 +offset_right = 47.0 +offset_bottom = -3.0 +color = Color(0.52549, 0.52549, 0.52549, 1) + +[node name="3" type="ColorRect" parent="chores/Sprite2D2"] +visible = false +offset_left = -45.0 +offset_top = 13.0 +offset_right = 32.0 +offset_bottom = 15.0 +color = Color(0.52549, 0.52549, 0.52549, 1) + +[node name="cooldown" type="Timer" parent="."] +wait_time = 0.6 +one_shot = true + +[connection signal="timeout" from="cooldown" to="." method="_on_cooldown_timeout"]