forked from unfa/liblast
Added layers to the handgun shoot SFX.
parent
a52185f749
commit
920dceb411
|
@ -29,7 +29,9 @@ var impact_player = preload("res://Assets/Effects/ImpactBlood.tscn")
|
||||||
|
|
||||||
var ray = space_state.intersect_ray(from, to, [player])
|
var ray = space_state.intersect_ray(from, to, [player])
|
||||||
|
|
||||||
$Handgun/SFX/Shoot.play()
|
$"Handgun/SFX/Shoot A".play()
|
||||||
|
$"Handgun/SFX/Shoot B".play()
|
||||||
|
$"Handgun/SFX/Shoot C".play()
|
||||||
|
|
||||||
var impact_vfx
|
var impact_vfx
|
||||||
|
|
||||||
|
@ -54,6 +56,11 @@ var impact_player = preload("res://Assets/Effects/ImpactBlood.tscn")
|
||||||
firstblood = false
|
firstblood = false
|
||||||
if firstblood:
|
if firstblood:
|
||||||
main.get_node("Announcer").speak(main.get_node("Announcer").firstblood)
|
main.get_node("Announcer").speak(main.get_node("Announcer").firstblood)
|
||||||
|
|
||||||
|
# check for revenge (payback) - don't play if this is a duel, it'd be silly
|
||||||
|
if main.player_list.size() > 2 and ray['collider'].get_multiplayer_authority() == player.revenge_pid:
|
||||||
|
main.get_node("Announcer").speak(main.get_node("Announcer").payback)
|
||||||
|
player.revenge_pid = -1 # reset revenge
|
||||||
|
|
||||||
else:
|
else:
|
||||||
hud.get_node("Crosshair").hit()
|
hud.get_node("Crosshair").hit()
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
[gd_scene load_steps=6 format=3 uid="uid://bemrov0tiy08n"]
|
[gd_scene load_steps=8 format=3 uid="uid://bemrov0tiy08n"]
|
||||||
|
|
||||||
[ext_resource type="PackedScene" uid="uid://bci2qnohg76xa" path="res://Assets/Weapons/Handgun/Handgun.gltf" id="1"]
|
[ext_resource type="PackedScene" uid="uid://bci2qnohg76xa" path="res://Assets/Weapons/Handgun/Handgun.gltf" id="1"]
|
||||||
[ext_resource type="Script" path="res://Assets/Weapons/Weapon.gd" id="2"]
|
[ext_resource type="Script" path="res://Assets/Weapons/Weapon.gd" id="2"]
|
||||||
[ext_resource type="PackedScene" uid="uid://c5cwnfuw4go1b" path="res://Assets/Audio/SoundPlayer.tscn" id="3_q0xp7"]
|
[ext_resource type="PackedScene" uid="uid://c5cwnfuw4go1b" path="res://Assets/Audio/SoundPlayer.tscn" id="3_q0xp7"]
|
||||||
[ext_resource type="AudioStream" uid="uid://cw01fxbftb6m2" path="res://Assets/SFX/Weapons_Handgun_Shot_01_B.wav" id="4_4ao2c"]
|
[ext_resource type="AudioStream" uid="uid://cw01fxbftb6m2" path="res://Assets/SFX/Weapons_Handgun_Shot_01_B.wav" id="4_4ao2c"]
|
||||||
|
[ext_resource type="AudioStream" uid="uid://citsx20hcjj8i" path="res://Assets/SFX/Weapons_Handgun_Shot_01_A.wav" id="4_p0b4f"]
|
||||||
|
[ext_resource type="AudioStream" uid="uid://cxiy7p6qd7hyh" path="res://Assets/SFX/Weapons_Handgun_Shot_01_C.wav" id="6_w1k4v"]
|
||||||
|
|
||||||
[sub_resource type="Animation" id="1"]
|
[sub_resource type="Animation" id="1"]
|
||||||
resource_name = "Default"
|
resource_name = "Default"
|
||||||
|
@ -57,16 +59,40 @@ blend_times = []
|
||||||
[node name="SFX" type="Node3D" parent="Handgun"]
|
[node name="SFX" type="Node3D" parent="Handgun"]
|
||||||
script = null
|
script = null
|
||||||
|
|
||||||
[node name="Shoot" parent="Handgun/SFX" instance=ExtResource( "3_q0xp7" )]
|
[node name="Shoot A" parent="Handgun/SFX" instance=ExtResource( "3_q0xp7" )]
|
||||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0168038, 0.251726, 0.250185)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0168038, 0.251726, 0.250185)
|
||||||
SoundClip = "res://Assets/SFX/Weapons_HandgunShot_01.wav"
|
SoundClip = "res://Assets/SFX/Weapons_HandgunShot_01.wav"
|
||||||
Voice_Count = 2
|
Voice_Count = 2
|
||||||
|
|
||||||
[node name="AudioStreamPlayer3D" parent="Handgun/SFX/Shoot" index="0"]
|
[node name="AudioStreamPlayer3D" parent="Handgun/SFX/Shoot A" index="0"]
|
||||||
stream = ExtResource( "4_4ao2c" )
|
stream = ExtResource( "4_p0b4f" )
|
||||||
unit_db = 8.0
|
unit_db = 8.0
|
||||||
|
unit_size = 1.0
|
||||||
|
max_db = 6.0
|
||||||
|
|
||||||
|
[node name="Shoot B" parent="Handgun/SFX" instance=ExtResource( "3_q0xp7" )]
|
||||||
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0168038, 0.251726, 0.250185)
|
||||||
|
SoundClip = "res://Assets/SFX/Weapons_HandgunShot_01.wav"
|
||||||
|
Voice_Count = 2
|
||||||
|
|
||||||
|
[node name="AudioStreamPlayer3D" parent="Handgun/SFX/Shoot B" index="0"]
|
||||||
|
stream = ExtResource( "4_4ao2c" )
|
||||||
|
unit_db = 4.0
|
||||||
unit_size = 8.0
|
unit_size = 8.0
|
||||||
max_db = 6.0
|
max_db = 6.0
|
||||||
|
|
||||||
|
[node name="Shoot C" parent="Handgun/SFX" instance=ExtResource( "3_q0xp7" )]
|
||||||
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0168038, 0.251726, 0.250185)
|
||||||
|
SoundClip = "res://Assets/SFX/Weapons_HandgunShot_01.wav"
|
||||||
|
Voice_Count = 2
|
||||||
|
|
||||||
|
[node name="AudioStreamPlayer3D" parent="Handgun/SFX/Shoot C" index="0"]
|
||||||
|
stream = ExtResource( "6_w1k4v" )
|
||||||
|
unit_db = 4.0
|
||||||
|
unit_size = 16.0
|
||||||
|
max_db = 4.0
|
||||||
|
|
||||||
[editable path="Handgun"]
|
[editable path="Handgun"]
|
||||||
[editable path="Handgun/SFX/Shoot"]
|
[editable path="Handgun/SFX/Shoot A"]
|
||||||
|
[editable path="Handgun/SFX/Shoot B"]
|
||||||
|
[editable path="Handgun/SFX/Shoot C"]
|
||||||
|
|
Loading…
Reference in New Issue