• If you have a mod, tool or prefab, please use the Resources section. Click Mods at the top of the forums.

Smitty's Sirens & Alarms

I’m personally interested in it :)  I have some/all of the sentence structure worked out, but haven’t actually done any work for sounds.  I’ll have to manually do a lot of “padding” to make it work well.  And trying to make the localization make sense is going to be weird...
 

If nothing else, I could throw in some extra phrases and get this request and the mod I was thinking about out in the same mod. 
 

so yeah, if you can generate a nice voice .wav files from text (my method is very janky and old, but “free”) and want to send them to me, let me know and I’ll message you the words/phrases!  If it’s someone “literally speaking and recording it” and not some text to voice conversion, I can write out all the phrases instead. 

 
Hi,,

This mod does not work for me for some reason. It's installed properly along with my other mods, and they work fine. And the items from this mod do show up in-game, but when I try to craft them, it says I must have the Speaker Schematic (which I have), 1 speaker to craft (which I do), and the Advanced Engineer Perk - which I also have. But the sirens still remain locked; when I try to craft and can press the Up arrow to craft (I use my controller so not sure what the PC button is), it just says "Perk" and opens up the Advanced Engineer perk when pressed. 

Am I being stupid and missed something vital? 😅

 
Hi,,

This mod does not work for me for some reason. It's installed properly along with my other mods, and they work fine. And the items from this mod do show up in-game, but when I try to craft them, it says I must have the Speaker Schematic (which I have), 1 speaker to craft (which I do), and the Advanced Engineer Perk - which I also have. But the sirens still remain locked; when I try to craft and can press the Up arrow to craft (I use my controller so not sure what the PC button is), it just says "Perk" and opens up the Advanced Engineer perk when pressed. 

Am I being stupid and missed something vital? 😅
- What version of the game are you running?

- Can you provide a list of mods you have installed?

I’ll try to test this weekend on whatever version you’re running.  Getting the schematic or the perk should unlock them.  I believe I tested that when the mod was made.

also: I didn’t test using a controller, but I believe there’s a thing where if an item is still locked, and you click /choose options for it it will take you to the required perk. So maybe that’s what’s happening, as they are still locked.

 
Last edited:
- What version of the game are you running?

- Can you provide a list of mods you have installed?

I’ll try to test this weekend on whatever version you’re running.  Getting the schematic or the perk should unlock them.  I believe I tested that when the mod was made.

also: I didn’t test using a controller, but I believe there’s a thing where if an item is still locked, and you click /choose options for it it will take you to the required perk. So maybe that’s what’s happening, as they are still locked.


Hi, thanks for the fast response :)

I'm running Alpha 19.4, the newest version; I have the following 10 mods; Duriel's Lethal Headshots, Jakmeister999's REASONABLE Large Stacks (A19), JRB_ZombieLootDrop_25, More Skill Points, PhD Better Lights 3.3 (A19), PhD Bigger Crafting Queue x 10 1.3 (A19), Smitty-SirensAndAlerts, WorkingWoodBurningStove, ZT-FunctionalElevator and ZT_IBBI (Unnecessarily Beautiful But Immersive)

 
I believe I have found a fix for this mod to get it to work in a19.4 stable.  There was also an existing bug I found, possibly 2 (if changes were made in 19.4 that broke it).

I cannot upload the fixed files here (the forum blocking xml uploads) so for now, here's what you have to do to fix it. You should be able to make these changes in an existing game and it "just works" as we're not creating or removing any new resources/blocks/items/etc.

NOTE: You have to have Perk Engineering up to level 3 (in the fixed version) for the perk to unlock them as that's when the normal vanilla speaker unlocks.

NOTE: I could not replicate the "schematic not unlocking them" issue.  Using the schematic in the old version (and the new) should unlock them all without the perk.

NOTE: I will leave it up to Smitty to update and relink a "a19.4 stable" version, or patch and test however they see fit, or not update, etc.

Bug 1: "Speaker - Alarm Siren 2" is not working.

Change the SoundDataNode block for everything for speaker 16 in sounds.xml to the XML below

The actual change is just changing a single underscore to a space for the AudioClip (the wrong sound was named "alarm_siren_2"), but this is easier to document as the entire XML block

<!-- Speaker 16 -->
<SoundDataNode name="smitty_siren16">
<AudioSource name="Sounds/AudioSource_VO_Announce"/>
<AudioClip ClipName="#@modfolder:Resources/smittylv_envato_sounds.unity3d?alarm_siren 2" Loop="true"/>
<LocalCrouchVolumeScale name="1.0"/>
<CrouchNoiseScale name="0.5"/>
<NoiseScale name="1"/>
<MaxVoices value="10"/>
<MaxRepeatRate value="0"/>
</SoundDataNode>




Bug 2: Perk AdvancedEngineering not working to unlock the speakers

I don't know why (maybe it didn't work before?) but this gets it to work in a19.4 stable:

1. Create a new file in the mod under the Config folder and call it: progression.xml (note: On windows, you might need to have visible file name extensions "on" or you might end up creating progression.xml.txt instead)

2. Add this XML to the file

<Smitty>
<append xpath="/progression/perks/perk[@name='perkAdvancedEngineering']/effect_group">
<passive_effect name="RecipeTagUnlocked" operation="base_set" level="3,5" value="1" tags="smittySpeaker1,smittySpeaker2,smittySpeaker3,smittySpeaker4,smittySpeaker5,smittySpeaker6,smittySpeaker7,smittySpeaker8,smittySpeaker9,smittySpeaker10,smittySpeaker11,smittySpeaker12,smittySpeaker13,smittySpeaker14,smittySpeaker15,smittySpeaker16,smittySpeaker17,smittySpeaker18,smittySpeaker19"/>
</append>
</Smitty>




Also:

If you want to be super pedantic/accurate, you would also change the Version line in ModInfo.xml from 1.0.0 to 1.0.1 or something different from the original.  Using 2.0.0 might also be accurate if it doesn't work in the original version of the game it was built on. I'm not sure, just 1.0.1 indicates its not the original

Code:
<Version value="1.0.1" />
 
Last edited:
I believe I have found a fix for this mod to get it to work in a19.4 stable.  There was also an existing bug I found, possibly 2 (if changes were made in 19.4 that broke it).

I cannot upload the fixed files here (the forum blocking xml uploads) so for now, here's what you have to do to fix it. You should be able to make these changes in an existing game and it "just works" as we're not creating or removing any new resources/blocks/items/etc.

NOTE: You have to have Perk Engineering up to level 3 (in the fixed version) for the perk to unlock them as that's when the normal vanilla speaker unlocks.

NOTE: I could not replicate the "schematic not unlocking them" issue.  Using the schematic in the old version (and the new) should unlock them all without the perk.

NOTE: I will leave it up to Smitty to update and relink a "a19.4 stable" version, or patch and test however they see fit, or not update, etc.

Bug 1: "Speaker - Alarm Siren 2" is not working.

Change the SoundDataNode block for everything for speaker 16 in sounds.xml to the XML below

The actual change is just changing a single underscore to a space for the AudioClip (the wrong sound was named "alarm_siren_2"), but this is easier to document as the entire XML block

<!-- Speaker 16 -->
<SoundDataNode name="smitty_siren16">
<AudioSource name="Sounds/AudioSource_VO_Announce"/>
<AudioClip ClipName="#@modfolder:Resources/smittylv_envato_sounds.unity3d?alarm_siren 2" Loop="true"/>
<LocalCrouchVolumeScale name="1.0"/>
<CrouchNoiseScale name="0.5"/>
<NoiseScale name="1"/>
<MaxVoices value="10"/>
<MaxRepeatRate value="0"/>
</SoundDataNode>




Bug 2: Perk AdvancedEngineering not working to unlock the speakers

I don't know why (maybe it didn't work before?) but this gets it to work in a19.4 stable:

1. Create a new file in the mod under the Config folder and call it: progression.xml (note: On windows, you might need to have visible file name extensions "on" or you might end up creating progression.xml.txt instead)

2. Add this XML to the file

<Smitty>
<append xpath="/progression/perks/perk[@name='perkAdvancedEngineering']/effect_group">
<passive_effect name="RecipeTagUnlocked" operation="base_set" level="3,5" value="1" tags="smittySpeaker1,smittySpeaker2,smittySpeaker3,smittySpeaker4,smittySpeaker5,smittySpeaker6,smittySpeaker7,smittySpeaker8,smittySpeaker9,smittySpeaker10,smittySpeaker11,smittySpeaker12,smittySpeaker13,smittySpeaker14,smittySpeaker15,smittySpeaker16,smittySpeaker17,smittySpeaker18,smittySpeaker19"/>
</append>
</Smitty>




Also:

If you want to be super pedantic/accurate, you would also change the Version line in ModInfo.xml from 1.0.0 to 1.0.1 or something different from the original.  Using 2.0.0 might also be accurate if it doesn't work in the original version of the game it was built on. I'm not sure, just 1.0.1 indicates its not the original

<Version value="1.0.1" />



Hello!

Your fix worked - I can craft and use the speakers now, thank you so much! I've got alarms blaring whenever zombies come near the entrances to the base now, it's super useful! :D

I did notice something else though; the friends I play with can't hear the speaker alarms even with the mod installed on their end. They play with the exact same mods as I do. Is this how it's supposed to be? We don't play on a dedicated server but just on a normal private game; I'm not sure if this matters. 

 
I did notice something else though; the friends I play with can't hear the speaker alarms even with the mod installed on their end.
That’s not supposed to happen.  I’ll see what I can figure out. All the speakers extend from the standard “speaker” so it should work (ha ha, should!).

one possibility is that the config/resources/*.unity3d file (whatever  that file is named, I forget. I’m on my phone) might be corrupt for them . It’s a very remote possibility, if everyone shared the same bad copy.  
 

can someone else craft one of these speakers, and have them place and connect it, and validate that only they can hear it?

note: there is a way to have sounds “only play in a players head” but I thought that only applies to player buffs, and had to be explicitly set as an option.   Maybe the speaker block is different and needs some explicit “play for everyone” when it is extended as sometimes properties don’t always extend, by purposeful design apparently. 

 
That’s not supposed to happen.  I’ll see what I can figure out. All the speakers extend from the standard “speaker” so it should work (ha ha, should!).

one possibility is that the config/resources/*.unity3d file (whatever  that file is named, I forget. I’m on my phone) might be corrupt for them . It’s a very remote possibility, if everyone shared the same bad copy.  
 

can someone else craft one of these speakers, and have them place and connect it, and validate that only they can hear it?

note: there is a way to have sounds “only play in a players head” but I thought that only applies to player buffs, and had to be explicitly set as an option.   Maybe the speaker block is different and needs some explicit “play for everyone” when it is extended as sometimes properties don’t always extend, by purposeful design apparently. 
Thanks for the fast reply :)

I'll have them try crafting their own alarm speaker later and see if they can hear those! 

 
Thanks for the fast reply :)

I'll have them try crafting their own alarm speaker later and see if they can hear those! 
I had both of my friends try crafting their own speakers and connecting them; they can't hear them at all. I'm not sure if they need to craft their own generator + motion sensor either; they used my extras for that, but the speakers they made on their own. They tested the Ship Siren sound for them; I could hear the noise coming from their speaker but they couldn't hear it themselves; seems like only the host can hear them. 

 
I had both of my friends try crafting their own speakers and connecting them; they can't hear them at all. I'm not sure if they need to craft their own generator + motion sensor either; they used my extras for that, but the speakers they made on their own. They tested the Ship Siren sound for them; I could hear the noise coming from their speaker but they couldn't hear it themselves; seems like only the host can hear them. 
This is really weird then. 
ummm, can you test that they/you can hear the “regular” vanilla speaker that they place and hook up themselves?

I don’t think the source of the electricity should matter, just possibly who places the block (if that matters).  I don’t know why that don’t hear anything as things like the trader speaker announcements should be heard by all (well, it’s a little special) but normal “sounds” from every other object (doors, guns, cabinets, etc) should be hearable by everyone and this  shouldn’t be any different. 
 

I looked at the xml yesterday and didn’t see anything obvious, but there’s 1 possible change I could try and can post the xml to try tonight. After that I’m out of obvious ideas and might have to see if some of the modding discord’s have an answer. I don’t have a server to test any of this on , I only have local single player games. :(
 

it’s also possible that it’s a bug  in the game for the speaker class in PvP. If the fix I’m going to send doesn’t fix it, and the Modding discord(s) doesn’t have an answer, I’ll submit a bug report with your testing info and my xml updates/etc. and see what TFP can validate it’s working properly or not (I’d say not).  It’s a mod so they might not be willing to fix it BUT it’s also just a basic “extension” of a vanilla block so maybe its an issue vs “a mod issue”. If the vanilla speaker isn’t heard by everyone then we have a much more solid case, I would think unless this is intended behaviour 

 
Last edited:
Update: IF in the game players place a vanilla speaker (non smitty's speaker) and it CAN be heard by all players, attempt this XML edit to Smitty's mod:

PvP test/XML edit #2:

Change the "blocks.xml" file to change the single "smittySpeaker1" block to look like this (below) and see if this speaker can be placed by one player and heard by all players. FYI: The block in game is called "Speaker - Ship Siren", per the Localization.txt file translation.

The difference in this code is that it is not extending the Speaker class, but copying the vanilla speaker, adding a vanilla speaker icon, and changing the sound.

If this fails to work (only the person who places the block can hear it), then it looks like a PvP only bug to me and I'll file a bug report.

If this "fixes" the issue, then I'll see if I can get ahold of smitty to update the mod with all the fixes and post it for a19.4.

Code:
<block name="smittySpeaker1">
    	<property name="CreativeMode" value="Player"/>
	    <property name="Class" value="Speaker"/>
	    <property name="CustomIcon" value="speaker"/>
	    <property name="UnlockedBy" value="perkAdvancedEngineering,speakerSchematic"/>
	    <property name="PlaySound" value="smitty_siren1"/>
	    <property name="Material" value="Mmetal_weak"/>
	    <property name="Shape" value="ModelEntity"/>
	    <property name="Model" value="Entities/Electrical/loudspeakerPrefab"/>
	    <property name="HandleFace" value="South"/>
	    <property name="ImposterDontBlock" value="true"/>
	    <property name="Collide" value="movement,melee,bullet,arrow,rocket"/>
	    <property name="LootList" value="7"/>
	    <property name="RequiredPower" value="5"/>
	    <property name="DisplayType" value="blockElectrical"/>
	    <property name="Group" value="Science"/>
	    <property class="RepairItems">
		    <property name="resourceForgedIron" value="3"/>
		    <property name="resourceElectricParts" value="2"/>
	    </property>
	    <drop event="Harvest" name="terrStone" count="0" tool_category="Disassemble"/>
	    <drop event="Harvest" name="resourceElectricParts" count="0,2" tag="salvageHarvest"/>
	    <drop event="Harvest" name="resourceScrapIron" count="5,10" tag="allHarvest"/>
	    <drop event="Destroy" count="0"/>
	    <drop event="Fall" name="scrapMetalPile" count="1" prob="0.75" stick_chance="1"/>
	    <property name="TakeDelay" value="5"/>
	    <property name="EconomicValue" value="72"/>
	    <property name="FilterTags" value="fdecor,felectrical"/>
	    <property name="SortOrder1" value="70a0"/>
    </block>
 
doughphunghus said:
Not that I’m aware of, for like “overall sounds of a specific block or sound node”.  Of course, there are some audio settings from the main menu that can be changed (music/ambiance volumes) but I don’t know setting what a speaker/block falls under.

@smitty I  consider these sounds and the mod “owned by smitty” so if they want to change it (have me tweak the sound levels and repackage the sounds ) I could do that if they asked me to but maybe this is exactly how smitty wants their mod?

I can put together a different mod with some sounds for you if you would like, the hard part is getting the sounds that are “freely available to use”. (send me some links and I’ll see if I can use them.).  It might sound weird using this limitation, but I feel weird just taking clips from others and giving them to someone else (or the forums) unless they are licensed freely. If you want, I can point you to some links on how to add your own sounds to the game and you can create/add whatever sounds you want as your own mod.  It’s not super hard but it takes some time to get unity set up/installed and do the actual xml editing. Sound converting is actually easy once you’re set up to do it.

also:  I do have the capability to create “voice alerts” that can say whatever you want (I’m using the very ancient “espeak” tool right now) but the voices are not super pretty (sounds robotic).  I’m working on this for a mech mod I’ve released, which is still in development, and the volume levels need tweaking as well.  Additionally, I might be able to create something using some tools I have to mimic a sound/alarm if you have one in mind. Basic stuff though.
Yes you can change the volume levels as you need! I did find some too loud as well. Scared the S%@T out of me lol.

Also I've had the lines recorded if you wanted to go forth with the request by one of the players here to have ones that speak lines.
I messaged you the file and it is yours to do with as you wish.

 
Back
Top