You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Babushka/prefabs/farm/plants/base_plant.tscn

217 lines
7.4 KiB

[gd_scene load_steps=11 format=3 uid="uid://gishbn0a8eke"]
[ext_resource type="Script" uid="uid://cms357f23fmfy" path="res://scripts/CSharp/Common/Farming/PlantBehaviour2D.cs" id="1_66p1c"]
[ext_resource type="Texture2D" uid="uid://mrnc81ukugh6" path="res://art/farm/farming/farmobjekte/plant_template.png" id="2_oyl0t"]
[ext_resource type="Shader" uid="uid://braevmqauoek7" path="res://shader/swaying_plant.gdshader" id="3_7hdur"]
[ext_resource type="PackedScene" uid="uid://cqc72e4hq6bcd" path="res://prefabs/interactions/interaction_area_2d.tscn" id="5_3j24b"]
[ext_resource type="PackedScene" uid="uid://dpbbroif2tnil" path="res://prefabs/interactions/generic_item_on_ground_2d.tscn" id="6_gdrin"]
[ext_resource type="Resource" uid="uid://blr8tine5m0ma" path="res://resources/items/tomato.tres" id="7_vjw4j"]
[ext_resource type="Texture2D" uid="uid://bleimj6jr1jka" path="res://art/general/rectangle.png" id="9_vjw4j"]
[sub_resource type="ShaderMaterial" id="ShaderMaterial_u4cty"]
shader = ExtResource("3_7hdur")
shader_parameter/speed = 2.0
shader_parameter/minStrength = 0.05
shader_parameter/maxStrength = 0.206
shader_parameter/strengthScale = 100.0
shader_parameter/interval = 3.5
shader_parameter/detail = 1.0
shader_parameter/distortion = 0.0
shader_parameter/heightOffset = 0.635
shader_parameter/offset = 0.0
[sub_resource type="CircleShape2D" id="CircleShape2D_vjw4j"]
resource_local_to_scene = true
radius = 300.0
[sub_resource type="CircleShape2D" id="CircleShape2D_7hdur"]
resource_local_to_scene = true
radius = 300.0
[node name="BasePlant" type="Node2D" node_paths=PackedStringArray("_seeds", "_smallPlants", "_bigPlants", "_readyPlants", "_harvestablePlant", "_magicEffect")]
z_index = 1
y_sort_enabled = true
script = ExtResource("1_66p1c")
_seeds = [NodePath("Seeds/Seed1"), NodePath("Seeds/Seed2"), NodePath("Seeds/Seed3")]
_smallPlants = [NodePath("SmallPlant/01"), NodePath("SmallPlant/02"), NodePath("SmallPlant/03")]
_bigPlants = [NodePath("BigPlant/01"), NodePath("BigPlant/02"), NodePath("BigPlant/03")]
_readyPlants = [NodePath("ReadyPlantInventoryItem/ReadyPlant/01"), NodePath("ReadyPlantInventoryItem/ReadyPlant/02"), NodePath("ReadyPlantInventoryItem/ReadyPlant/03")]
_harvestablePlant = NodePath("ReadyPlantInventoryItem")
_magicEffect = NodePath("magic vfx")
_magicWordNeeded = false
[node name="Seeds" type="Node2D" parent="."]
position = Vector2(0, 0.5)
[node name="Seed1" type="Sprite2D" parent="Seeds"]
visible = false
y_sort_enabled = true
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(524, 1182, 294, 284)
[node name="Seed2" type="Sprite2D" parent="Seeds"]
visible = false
y_sort_enabled = true
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(930, 1182, 296, 289)
[node name="Seed3" type="Sprite2D" parent="Seeds"]
visible = false
y_sort_enabled = true
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(1328, 1184, 282, 292)
[node name="SmallPlant" type="Node2D" parent="."]
position = Vector2(0, 0.5)
[node name="01" type="Sprite2D" parent="SmallPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(1810, 1190, 258, 299)
[node name="02" type="Sprite2D" parent="SmallPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(2206, 1182, 274, 306)
[node name="03" type="Sprite2D" parent="SmallPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(2588, 1178, 282, 300)
[node name="BigPlant" type="Node2D" parent="."]
position = Vector2(0, -300)
[node name="01" type="Sprite2D" parent="BigPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(2.5, -56.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(3454, 133, 850, 895)
[node name="02" type="Sprite2D" parent="BigPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(12.5, -44.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(4498, 134, 764, 903)
[node name="03" type="Sprite2D" parent="BigPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(16.5, -37.5)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(5416, 136, 647, 895)
[node name="GrowingInteractionArea" parent="." instance=ExtResource("5_3j24b")]
position = Vector2(0, 2.3)
_useOutline = false
_useSprite = false
[node name="CollisionShape3D" parent="GrowingInteractionArea/Area2D" index="0"]
shape = SubResource("CircleShape2D_vjw4j")
[node name="ReadyPlantInventoryItem" parent="." instance=ExtResource("6_gdrin")]
position = Vector2(0, 2.3)
IsActive = false
[node name="SpawnWithItem" parent="ReadyPlantInventoryItem" index="0"]
_blueprint = ExtResource("7_vjw4j")
[node name="ItemLabel" parent="ReadyPlantInventoryItem" index="1"]
visible = false
z_index = 100
text = "[E] harvest"
[node name="PickupErrorLabel" parent="ReadyPlantInventoryItem" index="2"]
visible = false
[node name="PickupInteractionArea" parent="ReadyPlantInventoryItem" index="3"]
visible = false
[node name="CollisionShape3D" parent="ReadyPlantInventoryItem/PickupInteractionArea/Area2D" index="0"]
shape = SubResource("CircleShape2D_7hdur")
[node name="Icon" parent="ReadyPlantInventoryItem" index="4"]
visible = false
[node name="ReadyPlant" type="Node2D" parent="ReadyPlantInventoryItem"]
position = Vector2(0, -400)
[node name="01" type="Sprite2D" parent="ReadyPlantInventoryItem/ReadyPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(-24.5, 50.2)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(474, 130, 752, 887)
[node name="02" type="Sprite2D" parent="ReadyPlantInventoryItem/ReadyPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(-1.5, 49.2)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(1418, 134, 843, 887)
[node name="03" type="Sprite2D" parent="ReadyPlantInventoryItem/ReadyPlant"]
visible = false
y_sort_enabled = true
material = SubResource("ShaderMaterial_u4cty")
position = Vector2(0.5, 49.2)
texture = ExtResource("2_oyl0t")
region_enabled = true
region_rect = Rect2(2461, 134, 841, 878)
[node name="magic vfx" type="CPUParticles2D" parent="."]
position = Vector2(-133, -347)
rotation = -0.333807
emitting = false
amount = 20
texture = ExtResource("9_vjw4j")
lifetime = 0.5
randomness = 1.0
local_coords = true
draw_order = 1
emission_shape = 2
emission_sphere_radius = 128.0
linear_accel_min = 44.07
linear_accel_max = 78.81
scale_amount_min = 0.01
scale_amount_max = 0.1
color = Color(0.400601, 0.62444, 0.791217, 1)
hue_variation_max = 0.4
[connection signal="Interacted" from="GrowingInteractionArea" to="." method="Grow"]
[connection signal="SuccessfulPickUp" from="ReadyPlantInventoryItem" to="." method="queue_free"]
[editable path="GrowingInteractionArea"]
[editable path="ReadyPlantInventoryItem"]
[editable path="ReadyPlantInventoryItem/PickupInteractionArea"]