Skip to content

Commit

Permalink
Petros Ambient sounds
Browse files Browse the repository at this point in the history
  • Loading branch information
UAC-MaxxLite committed Nov 2, 2024
1 parent fea8fd7 commit 94b7256
Show file tree
Hide file tree
Showing 19 changed files with 259 additions and 0 deletions.
2 changes: 2 additions & 0 deletions A3A/addons/core/functions/Base/fn_initPetros.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ if (petros == leader group petros) then {
petros setBehaviour "SAFE";
};

call A3A_fnc_unitAmbient; // adds ambient sounds to petros

// Install both moving and static actions
[petros,"petros"] remoteExec ["A3A_fnc_flagaction", 0, petros];

Expand Down
1 change: 1 addition & 0 deletions A3A/addons/patcom/CfgFunctions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ class CfgFunctions {
class createResourceCiv {};
class createRoomLight {};
class getDayState {};
class unitAmbient {};
};

class Patcom {
Expand Down
77 changes: 77 additions & 0 deletions A3A/addons/patcom/CfgSounds.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -259,4 +259,81 @@ class CfgSounds
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Fear\fear6.ogg), 0.8, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Coughing1
{
name = "A3A_Audio_Petros_Ambient_Coughing1";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Coughing1.ogg), 3, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Coughing2
{
name = "A3A_Audio_Petros_Ambient_Coughing2";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Coughing2.ogg), 1, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Scratching
{
name = "A3A_Audio_Petros_Ambient_Scratching";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Scratching.ogg), 4, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Whistle1
{
name = "A3A_Audio_Petros_Ambient_Whistle1";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Whistle1.ogg), 4, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Whistle2
{
name = "A3A_Audio_Petros_Ambient_Whistle2";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Whistle2.ogg), 2.5, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Yawn1
{
name = "A3A_Audio_Petros_Ambient_Yawn1";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Yawn1.ogg), 2.5, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Yawn2
{
name = "A3A_Audio_Petros_Ambient_Yawn2";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Yawn2.ogg), 4, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_ThroatClearing
{
name = "A3A_Audio_Petros_Ambient_ThroatClearing";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\ThroatClearing.ogg), 4.5, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Humming
{
name = "A3A_Audio_Petros_Ambient_Humming";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Humming.ogg), 5, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Sniffling
{
name = "A3A_Audio_Petros_Ambient_Sniffling";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Sniffling.ogg), 5, 1, 40};
titles[] = {};
};

class A3A_Audio_Petros_Ambient_Breathing
{
name = "A3A_Audio_Petros_Ambient_Breathing";
sound[] = {EQPATHTOFOLDER(patcom,sounds\Civilian\Ambient\Breathing.ogg), 5, 1, 40};
titles[] = {};
};
};
54 changes: 54 additions & 0 deletions A3A/addons/patcom/functions/Civilian/fn_unitAmbient.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
/*
Author: Maxx
Description:
Creates a ambient sounds from Petros.
Arguments:
Nil.
Return Value:
Petros
Scope: Any
Environment: Any
Public: No
Example:
call A3A_fnc_unitAmbient;
*/

private _musicSource = petros;

[_musicSource] spawn {
params ["_musicSource"];
// name of the sound file in CfgSounds.hpp
private _ambientSounds =
[
"A3A_Audio_Petros_Ambient_Coughing1",
"A3A_Audio_Petros_Ambient_Coughing2",
"A3A_Audio_Petros_Ambient_Scratching",
"A3A_Audio_Petros_Ambient_Whistle1",
"A3A_Audio_Petros_Ambient_Whistle2",
"A3A_Audio_Petros_Ambient_Yawn1",
"A3A_Audio_Petros_Ambient_Yawn2",
"A3A_Audio_Petros_Ambient_Humming",
"A3A_Audio_Petros_Ambient_Sniffling",
"A3A_Audio_Petros_Ambient_ThroatClearing",
"A3A_Audio_Petros_Ambient_Breathing"
];

while { (alive _musicSource) } do {
private _sound = selectRandom (_ambientSounds);

[_musicSource, _sound] remoteExec ["say3D", [1, _musicSource], true];

sleep 900;

if not (alive _musicSource) exitWith {};

sleep (random 10);
};
};

_musicSource
29 changes: 29 additions & 0 deletions A3A/addons/patcom/sounds/Civilian/Ambient/Breathing.lip
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
frame = 0.040
0.000, 0
1.080, 1
1.120, 0
1.160, 1
1.200, 0
1.880, 1
1.920, 3
1.960, 4
2.000, 7
2.040, 4
2.080, 3
2.240, 2
2.320, 1
2.400, 2
2.440, 3
2.480, 1
2.600, 2
2.640, 1
2.720, 2
2.760, 1
2.800, 2
2.840, 1
2.880, 0
2.960, 1
3.080, 0
3.240, 1
3.280, 0
4.840, -1
Binary file not shown.
34 changes: 34 additions & 0 deletions A3A/addons/patcom/sounds/Civilian/Ambient/Coughing1.lip
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
frame = 0.040
0.000, 0
1.000, 2
1.040, 3
1.080, 2
1.120, 1
1.280, 3
1.320, 1
1.360, 0
1.760, 1
1.880, 0
2.000, 1
2.080, 0
3.240, 3
3.280, 6
3.320, 2
3.400, 3
3.440, 2
3.480, 3
3.520, 7
3.560, 0
3.720, 1
3.760, 2
3.880, 1
3.920, 2
3.960, 3
4.000, 0
4.360, 1
4.480, 0
4.920, 2
4.960, 1
5.120, 2
5.200, 0
6.200, -1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
23 changes: 23 additions & 0 deletions A3A/addons/patcom/sounds/Civilian/Ambient/Yawn1.lip
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
frame = 0.040
0.000, 0
2.080, 2
2.120, 4
2.240, 3
2.320, 5
2.360, 3
2.400, 7
2.440, 6
2.480, 4
2.560, 3
2.600, 4
2.640, 2
2.680, 0
3.480, 1
3.520, 2
3.560, 3
3.640, 4
3.680, 1
3.920, 0
4.640, 1
4.680, 0
5.160, -1
Binary file not shown.
39 changes: 39 additions & 0 deletions A3A/addons/patcom/sounds/Civilian/Ambient/Yawn2.lip
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
frame = 0.040
0.000, 0
1.360, 1
1.440, 0
1.760, 1
1.800, 2
1.840, 3
1.880, 1
1.920, 2
1.960, 3
2.000, 2
2.120, 1
2.160, 2
2.200, 1
2.240, 0
2.960, 1
3.000, 2
3.040, 1
3.120, 2
3.240, 3
3.280, 2
3.320, 3
3.400, 1
3.480, 0
4.760, 1
4.840, 2
4.920, 1
4.960, 2
5.000, 3
5.040, 5
5.080, 7
5.120, 2
5.200, 1
5.240, 0
5.520, 1
5.600, 0
5.640, 1
5.720, 0
6.480, -1
Binary file not shown.

0 comments on commit 94b7256

Please sign in to comment.