Jump to content

DST character mod sound crashing


Recommended Posts

Hello! I'm having a pretty big problem with getting a custom character in a DST mod to 'talk'. At first, none of the assets worked and they were mute like wes pretty much, no sound when talking. However, when I realized I had missed a line of code to call the fsv file, everything just started crashing right away, and I have no idea what I'm doing. Please help, thank you!


character.lua:
 

-- adds Wotzo tag
    inst:AddTag("wotzo")
 
    --inst.soundsname = "soundssomething"
 
    --inst.talker_path_override = "soundssomething/"
    inst.soundsname = "wotzo"


files for audio(screenshot):
image.png.f7dd07b8d3ade529c432bb4add7d0104.png
mod main:

Assets = {
    Asset("SOUNDPACKAGE", "sound/soundssomething.fev"),
    Asset("SOUND", "sound/soundssomething.fsb"),
}
-- loading the asset
 
-- setting the sound bank name
inst.soundsname = "soundssomething.fsb"
 
-- setting the talker path override (.fev file name with a /)
inst.talker_path_override = "soundssomething.fev"
 
Link to comment
Share on other sites

Hi, in order to figure out the exact reason you're crashing we'll need to take a look at your log, or a screenshot of the crash. The log can be found in Documents/Klei/DoNotStarveTogether/master_server_log.txt.

The code you're putting in modmain might be the reason it's crashing though, as you don't need to put anything in modmain to make this work. You can add those Assets table entries to the one at the top of your character.lua, and the inst.soundsname and inst.talker_path_override stuff need to go in your master_postinit function, underneath where your health and sanity stuff is set.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
  • Create New...