1
0
Fork 0

add hoover

This commit is contained in:
Manu 2021-04-24 23:31:38 +02:00
parent 84fd007069
commit 6bb8b41602
3 changed files with 51 additions and 48 deletions

46
Player.tres Normal file
View File

@ -0,0 +1,46 @@
[gd_resource type="SpriteFrames" load_steps=6 format=2]
[ext_resource path="res://character.png" type="Texture" id=1]
[sub_resource type="AtlasTexture" id=3]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 0, 0, 160, 240 )
[sub_resource type="AtlasTexture" id=4]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 320, 0, 160, 240 )
[sub_resource type="AtlasTexture" id=5]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 160, 0, 160, 240 )
[sub_resource type="AtlasTexture" id=6]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 480, 0, 160, 240 )
[resource]
animations = [ {
"frames": [ SubResource( 3 ) ],
"loop": true,
"name": "left",
"speed": 5.0
}, {
"frames": [ SubResource( 4 ) ],
"loop": true,
"name": "right",
"speed": 5.0
}, {
"frames": [ SubResource( 5 ) ],
"loop": true,
"name": "front",
"speed": 5.0
}, {
"frames": [ SubResource( 6 ) ],
"loop": true,
"name": "back",
"speed": 5.0
} ]

View File

@ -1,52 +1,9 @@
[gd_scene load_steps=9 format=2]
[gd_scene load_steps=4 format=2]
[ext_resource path="res://character.png" type="Texture" id=1]
[ext_resource path="res://Player.tres" type="SpriteFrames" id=1]
[ext_resource path="res://Player.gd" type="Script" id=3]
[sub_resource type="AtlasTexture" id=3]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 0, 0, 112, 210 )
[sub_resource type="AtlasTexture" id=4]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 224, 0, 112, 210 )
[sub_resource type="AtlasTexture" id=5]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 112, 0, 112, 210 )
[sub_resource type="AtlasTexture" id=6]
flags = 4
atlas = ExtResource( 1 )
region = Rect2( 336, 0, 112, 210 )
[sub_resource type="SpriteFrames" id=1]
animations = [ {
"frames": [ SubResource( 3 ) ],
"loop": true,
"name": "left",
"speed": 5.0
}, {
"frames": [ SubResource( 4 ) ],
"loop": true,
"name": "right",
"speed": 5.0
}, {
"frames": [ SubResource( 5 ) ],
"loop": true,
"name": "front",
"speed": 5.0
}, {
"frames": [ SubResource( 6 ) ],
"loop": true,
"name": "back",
"speed": 5.0
} ]
[sub_resource type="CapsuleShape2D" id=2]
[sub_resource type="CapsuleShape2D" id=1]
radius = 32.0
height = 0.0
@ -58,9 +15,9 @@ __meta__ = {
[node name="AnimatedSprite" type="AnimatedSprite" parent="."]
position = Vector2( 0, -96 )
frames = SubResource( 1 )
frames = ExtResource( 1 )
animation = "front"
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
position = Vector2( 0, -16 )
shape = SubResource( 2 )
shape = SubResource( 1 )

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

After

Width:  |  Height:  |  Size: 5.3 KiB