fixed the parity between air and land enemies. +added a lot of new cards
This commit is contained in:
@ -1,15 +1,19 @@
|
||||
[gd_resource type="Resource" script_class="Card" load_steps=5 format=3 uid="uid://1xke2uy2vfuf"]
|
||||
[gd_resource type="Resource" script_class="Card" load_steps=7 format=3 uid="uid://1xke2uy2vfuf"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/Resources/card.gd" id="1_xmwih"]
|
||||
[ext_resource type="Resource" uid="uid://5ywipj3632u8" path="res://Resources/TurretStats/flametower.tres" id="2_80w0f"]
|
||||
[ext_resource type="Texture2D" uid="uid://jmxhiwsiw1f5" path="res://Assets/TextureAtlases/g_glue_gun.tres" id="2_ukaax"]
|
||||
[ext_resource type="PackedScene" uid="uid://dvqk2lysu02gf" path="res://PCs/Universal/ClassCards/Flamethrower/tower_flamethrower.tscn" id="3_yfmjg"]
|
||||
[ext_resource type="Resource" uid="uid://c4ihsd13o1esd" path="res://Resources/WeaponStats/flamethrower.tres" id="4_rdoaa"]
|
||||
[ext_resource type="PackedScene" uid="uid://cprppqfd2wf6s" path="res://PCs/Universal/ClassCards/Flamethrower/weapon_flamethrower.tscn" id="5_6v5br"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_xmwih")
|
||||
title = "Flamethrower"
|
||||
rarity = 3
|
||||
rarity = 2
|
||||
faction = 0
|
||||
sprite = ExtResource("2_ukaax")
|
||||
turret = ExtResource("3_yfmjg")
|
||||
weapon = ExtResource("5_6v5br")
|
||||
weapon_stats = ExtResource("4_rdoaa")
|
||||
tower_stats = ExtResource("2_80w0f")
|
||||
|
@ -17,12 +17,9 @@ func _process(delta: float) -> void:
|
||||
func shoot():
|
||||
for index in shapecast.get_collision_count():
|
||||
var target = shapecast.get_collider(index) as CharacterBody3D
|
||||
#TODO: its shit the way the enemy and status have to know about each other
|
||||
var status = StatusOnFire.new()
|
||||
status.affected = target.get_parent()
|
||||
status.stats = status_stats
|
||||
target.get_parent().status_manager.add_effect(status)
|
||||
target.get_parent().add_child(status)
|
||||
target.status_manager.add_effect(status)
|
||||
|
||||
|
||||
func aim():
|
||||
|
@ -5,9 +5,9 @@
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_kkqms"]
|
||||
offsets = PackedFloat32Array(0.00591716, 1)
|
||||
colors = PackedColorArray(0.898039, 0.447059, 0, 1, 1, 0, 0, 1)
|
||||
colors = PackedColorArray(0.898039, 0.447059, 0, 1, 1, 0, 0, 0.34902)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_gpquw"]
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_4cwgw"]
|
||||
gradient = SubResource("Gradient_kkqms")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_2nhns"]
|
||||
@ -18,13 +18,14 @@ initial_velocity_min = 5.0
|
||||
initial_velocity_max = 5.0
|
||||
damping_min = 4.464
|
||||
damping_max = 4.464
|
||||
color_ramp = SubResource("GradientTexture1D_gpquw")
|
||||
color_ramp = SubResource("GradientTexture1D_4cwgw")
|
||||
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_2yd7w"]
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_ycjd1"]
|
||||
transparency = 1
|
||||
vertex_color_use_as_albedo = true
|
||||
|
||||
[sub_resource type="BoxMesh" id="BoxMesh_q83y7"]
|
||||
material = SubResource("StandardMaterial3D_2yd7w")
|
||||
material = SubResource("StandardMaterial3D_ycjd1")
|
||||
size = Vector3(0.3, 0.3, 0.3)
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_vck5q"]
|
||||
@ -49,15 +50,15 @@ minimap_range_sphere = NodePath("Model/CSGSphere3D2")
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0)
|
||||
|
||||
[node name="CSGBox3D" type="CSGBox3D" parent="Model"]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.569646, 0)
|
||||
size = Vector3(1, 1.78698, 1)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.968366, 0)
|
||||
size = Vector3(1, 1.25244, 1)
|
||||
|
||||
[node name="CSGBox3D2" type="CSGBox3D" parent="Model"]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.00567371, -0.274218, -0.514041)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.00567371, -0.780982, -0.514041)
|
||||
size = Vector3(0.481654, 0.427749, 1.38438)
|
||||
|
||||
[node name="Node3D" type="Node3D" parent="Model"]
|
||||
transform = Transform3D(1, 0, 0, 0, -4.37114e-08, 1, 0, -1, -4.37114e-08, 0, -0.301084, -1.2154)
|
||||
transform = Transform3D(1, 0, 0, 0, -4.37114e-08, 1, 0, -1, -4.37114e-08, 0, -0.807848, -1.2154)
|
||||
|
||||
[node name="GPUParticles3D" type="GPUParticles3D" parent="Model/Node3D"]
|
||||
amount = 48
|
||||
|
30
PCs/Universal/ClassCards/Flamethrower/weapon_flamethrower.gd
Normal file
30
PCs/Universal/ClassCards/Flamethrower/weapon_flamethrower.gd
Normal file
@ -0,0 +1,30 @@
|
||||
extends Weapon
|
||||
|
||||
@export var shapecast : ShapeCast3D
|
||||
@export var particlesystem : GPUParticles3D
|
||||
@export var status_stats : StatusStats
|
||||
|
||||
|
||||
func _ready() -> void:
|
||||
cooldown = 1.0 / stats.fire_rate
|
||||
|
||||
|
||||
func set_raycast_origin(node):
|
||||
pass
|
||||
|
||||
|
||||
func shoot():
|
||||
if other_cooldown <= 0 and stats != null:
|
||||
other_cooldown = cooldown
|
||||
particlesystem.emitting = true
|
||||
$AnimationPlayer.play("shoot")
|
||||
for index in shapecast.get_collision_count():
|
||||
var target = shapecast.get_collider(index) as CharacterBody3D
|
||||
var status = StatusOnFire.new()
|
||||
status.stats = status_stats
|
||||
target.status_manager.add_effect(status)
|
||||
|
||||
|
||||
func release_trigger():
|
||||
trigger_held = false
|
||||
particlesystem.emitting = false
|
100
PCs/Universal/ClassCards/Flamethrower/weapon_flamethrower.tscn
Normal file
100
PCs/Universal/ClassCards/Flamethrower/weapon_flamethrower.tscn
Normal file
@ -0,0 +1,100 @@
|
||||
[gd_scene load_steps=14 format=3 uid="uid://cprppqfd2wf6s"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://jmxhiwsiw1f5" path="res://Assets/TextureAtlases/g_glue_gun.tres" id="1_kpb2q"]
|
||||
[ext_resource type="Script" path="res://PCs/Universal/ClassCards/Flamethrower/weapon_flamethrower.gd" id="2_18t5l"]
|
||||
[ext_resource type="Resource" uid="uid://dbanx8taicddm" path="res://Resources/StatusEffects/on_fire.tres" id="3_2sa8l"]
|
||||
[ext_resource type="Resource" uid="uid://c4ihsd13o1esd" path="res://Resources/WeaponStats/flamethrower.tres" id="4_ih15j"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_n8b32"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath(".:texture:region")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Rect2(0, 0, 64, 64)]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_g0h8q"]
|
||||
resource_name = "shoot"
|
||||
length = 0.15
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath(".:texture:region")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 0.15),
|
||||
"transitions": PackedFloat32Array(0, 0),
|
||||
"update": 0,
|
||||
"values": [Rect2(64, 0, 64, 64), Rect2(0, 0, 64, 64)]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_ntl6p"]
|
||||
_data = {
|
||||
"RESET": SubResource("Animation_n8b32"),
|
||||
"shoot": SubResource("Animation_g0h8q")
|
||||
}
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_q7gll"]
|
||||
size = Vector3(3, 3, 4)
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_nneoo"]
|
||||
offsets = PackedFloat32Array(0.00591716, 1)
|
||||
colors = PackedColorArray(0.898039, 0.447059, 0, 1, 1, 0, 0, 0.34902)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_gpquw"]
|
||||
gradient = SubResource("Gradient_nneoo")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_cp5dw"]
|
||||
direction = Vector3(0, 1, 0)
|
||||
spread = 20.0
|
||||
gravity = Vector3(0, 0, 0)
|
||||
initial_velocity_min = 5.0
|
||||
initial_velocity_max = 5.0
|
||||
damping_min = 1.9
|
||||
damping_max = 1.9
|
||||
color_ramp = SubResource("GradientTexture1D_gpquw")
|
||||
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_2yd7w"]
|
||||
transparency = 1
|
||||
vertex_color_use_as_albedo = true
|
||||
|
||||
[sub_resource type="BoxMesh" id="BoxMesh_ggcx2"]
|
||||
material = SubResource("StandardMaterial3D_2yd7w")
|
||||
size = Vector3(0.3, 0.3, 0.3)
|
||||
|
||||
[node name="Weapon" type="Sprite3D" node_paths=PackedStringArray("shapecast", "particlesystem")]
|
||||
layers = 2
|
||||
billboard = 1
|
||||
texture_filter = 0
|
||||
texture = ExtResource("1_kpb2q")
|
||||
script = ExtResource("2_18t5l")
|
||||
shapecast = NodePath("ShapeCast3D")
|
||||
particlesystem = NodePath("GPUParticles3D")
|
||||
status_stats = ExtResource("3_2sa8l")
|
||||
stats = ExtResource("4_ih15j")
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
"": SubResource("AnimationLibrary_ntl6p")
|
||||
}
|
||||
|
||||
[node name="ShapeCast3D" type="ShapeCast3D" parent="."]
|
||||
transform = Transform3D(0.975695, 0, 0.219131, 0, 1, 0, -0.219131, 0, 0.975695, 0, 0, 0)
|
||||
shape = SubResource("BoxShape3D_q7gll")
|
||||
target_position = Vector3(0, 0, -2)
|
||||
collision_mask = 4
|
||||
|
||||
[node name="GPUParticles3D" type="GPUParticles3D" parent="."]
|
||||
transform = Transform3D(0.975695, -0.219131, -9.57852e-09, 0, -4.37114e-08, 1, -0.219131, -0.975695, -4.2649e-08, 0, 0, 0)
|
||||
amount = 32
|
||||
visibility_aabb = AABB(-2.2922, -3.14731, -1.92995, 4.5844, 6.29461, 3.85991)
|
||||
process_material = SubResource("ParticleProcessMaterial_cp5dw")
|
||||
draw_pass_1 = SubResource("BoxMesh_ggcx2")
|
Reference in New Issue
Block a user