cute lil prototype
This commit is contained in:
parent
57f147236a
commit
0e4a55d7bd
19 changed files with 305 additions and 2 deletions
18
Prefabs/obstacle.tscn
Normal file
18
Prefabs/obstacle.tscn
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
[gd_scene load_steps=4 format=3 uid="uid://jb677rdhbj83"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://cnapenyo7b610" path="res://Prefabs/spinny.gd" id="1_htne5"]
|
||||
[ext_resource type="Texture2D" uid="uid://x8huf40a6dhq" path="res://Sprites/testObstacle.png" id="1_ifkp4"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_vef74"]
|
||||
size = Vector2(64, 64)
|
||||
|
||||
[node name="Obstacle" type="RigidBody2D"]
|
||||
gravity_scale = 0.0
|
||||
angular_damp_mode = 1
|
||||
script = ExtResource("1_htne5")
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("1_ifkp4")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource("RectangleShape2D_vef74")
|
||||
12
Prefabs/spare_battery.tscn
Normal file
12
Prefabs/spare_battery.tscn
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://cfdsa5scvso6m"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://1uqioi3jaw62" path="res://Sprites/batteryOutline.png" id="1_extsq"]
|
||||
[ext_resource type="Texture2D" uid="uid://1gx13iy21l2a" path="res://Sprites/batteryfull.png" id="2_n31ms"]
|
||||
|
||||
[node name="Battery2" type="TextureProgressBar"]
|
||||
max_value = 16.0
|
||||
value = 16.0
|
||||
fill_mode = 3
|
||||
texture_under = ExtResource("1_extsq")
|
||||
texture_progress = ExtResource("2_n31ms")
|
||||
tint_progress = Color(0, 1, 0, 1)
|
||||
11
Prefabs/spinny.gd
Normal file
11
Prefabs/spinny.gd
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
extends RigidBody2D
|
||||
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready() -> void:
|
||||
angular_velocity = randf_range(1,3)
|
||||
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta: float) -> void:
|
||||
pass
|
||||
1
Prefabs/spinny.gd.uid
Normal file
1
Prefabs/spinny.gd.uid
Normal file
|
|
@ -0,0 +1 @@
|
|||
uid://cnapenyo7b610
|
||||
Loading…
Add table
Add a link
Reference in a new issue