4g3t1t Posted December 24, 2016 Share Posted December 24, 2016 I can't get my beard to work. It crashes the game. I'm using Wilson's beard and code. I made it custom by coloring it yellow and used the TEXtool to make the zip with Wilson's atlas-0, anim & build. I can't figure out why it won't work. Any ideas? And, is the beard.lua in the components folder needed? Link to comment Share on other sites More sharing options...
Aquaterion Posted December 25, 2016 Share Posted December 25, 2016 9 hours ago, 4g3t1t said: I can't get my beard to work. It crashes the game. I'm using Wilson's beard and code. I made it custom by coloring it yellow and used the TEXtool to make the zip with Wilson's atlas-0, anim & build. I can't figure out why it won't work. Any ideas? And, is the beard.lua in the components folder needed? what exactly did you change from Wilson's beard.zip? You need to swap out the atlas-0.tex with your new atlas-0.tex, and use BuilderRenamer to change the internal name of build.bin to something new and unique Link to comment Share on other sites More sharing options...
4g3t1t Posted December 25, 2016 Author Share Posted December 25, 2016 8 hours ago, Aquaterion said: what exactly did you change from Wilson's beard.zip? You need to swap out the atlas-0.tex with your new atlas-0.tex, and use BuilderRenamer to change the internal name of build.bin to something new and unique i unzipped it and used TEXTool to save atlas-0. then in photoshop i made the beard yellow, used TEXCreator to save it back to a tex file, zipped the 3 files and renamed it mm_beard. i copied the code from wilson.lua. in my character's lua i added mm_beard because i've seen that in a couple other character mods. i figured it would work because it's all Wilson's stuff. i've never hear of BuilderRenamer. where can i get it? and in this case, being that it's Wilson's files, is it necessary? thanks for your help. Link to comment Share on other sites More sharing options...
Aquaterion Posted December 25, 2016 Share Posted December 25, 2016 idk where u can dl it but here's mine BuildRenamer.zip Link to comment Share on other sites More sharing options...
4g3t1t Posted December 25, 2016 Author Share Posted December 25, 2016 thanks! Link to comment Share on other sites More sharing options...
4g3t1t Posted December 25, 2016 Author Share Posted December 25, 2016 btw--in the dst data folder there's a components folder with a beard.lua file. do you know if that's needed for insulation or does Wilson's code already have it? thanks for your help. Link to comment Share on other sites More sharing options...
Aquaterion Posted December 25, 2016 Share Posted December 25, 2016 2 minutes ago, 4g3t1t said: btw--in the dst data folder there's a components folder with a beard.lua file. do you know if that's needed for insulation or does Wilson's code already have it? thanks for your help. there's a default value which is used in the sum: CurrentBeardStage(1-16) x 15 x InsulationFactor(1) You can only change the InsulationFactor by writing this in your character's master_postinit function inst.components.beard.insulation_factor = 1 --change 1 to any multiplier Link to comment Share on other sites More sharing options...
4g3t1t Posted December 26, 2016 Author Share Posted December 26, 2016 Ah, then i did 1 thing right. I found that in Webber's lua. My character is working, but the beard doesn't grow/show. If it's not too much trouble, can you see if this is right? local common_postinit = function(inst) --bearded (from beard component) added to pristine state for optimization inst:AddTag("bearded") -- Minimap icon inst.MiniMapEntity:SetIcon( "mm.tex" ) end local function OnResetBeard(inst) inst.AnimState:ClearOverrideSymbol("beard") end --tune the beard economy... local BEARD_DAYS = { 4, 8, 16 } local BEARD_BITS = { 1, 3, 9 } local function OnGrowShortBeard(inst) inst.AnimState:OverrideSymbol("beard", "mm_beard", "beard_short") inst.components.beard.bits = BEARD_BITS[1] end local function OnGrowMediumBeard(inst) inst.AnimState:OverrideSymbol("beard", "mm_beard", "beard_medium") inst.components.beard.bits = BEARD_BITS[2] end local function OnGrowLongBeard(inst) inst.AnimState:OverrideSymbol("beard", "mm_beard", "beard_long") inst.components.beard.bits = BEARD_BITS[3] end local master_postinit = function(inst) inst:AddComponent("beard") inst.components.beard.insulation_factor = TUNING.INSULATION_MED inst.components.beard.onreset = OnResetBeard inst.components.beard.prize = "beardhair" inst.components.beard:AddCallback(BEARD_DAYS[1], OnGrowShortBeard) inst.components.beard:AddCallback(BEARD_DAYS[2], OnGrowMediumBeard) inst.components.beard:AddCallback(BEARD_DAYS[3], OnGrowLongBeard) -- choose which sounds this character will play inst.soundsname = "woodie" -- Uncomment if "wathgrithr"(Wigfrid) or "webber" voice is used --inst.talker_path_override = "dontstarve_DLC001/characters/" -- Stats inst.components.health:SetMaxHealth(100) inst.components.hunger:SetMax(150) inst.components.sanity:SetMax(100) end Link to comment Share on other sites More sharing options...
4g3t1t Posted December 26, 2016 Author Share Posted December 26, 2016 Something is definitely wrong. I tried using Wilson's beard and that doesn't work. I copied the code as-is and no beard grows. I have no ideas. Link to comment Share on other sites More sharing options...
Aquaterion Posted December 26, 2016 Share Posted December 26, 2016 (edited) I'm not sure.. did you use buildrenamer to rename your build to mm_beard? did you add the asset at the top? Is this all the code you have t or did you just not copy it all? Also the insulation factor should be somewhere around 1-4, you made it over 100, which is way too high Edited December 26, 2016 by Aquaterion Link to comment Share on other sites More sharing options...
4g3t1t Posted December 26, 2016 Author Share Posted December 26, 2016 Thanks so much for your help. I tried using buildrenamer and added it under ghost_mm_build.zip, but the beard didn't grow. I thought it may be because I changed the color, so I got curious and decided to go simple and use Wilson's beard and code. It still didn't grow. I'm obviously doing something wrong. I just don't know what. Here's the updated code using Wilson's beard: local MakePlayerCharacter = require "prefabs/player_common" local assets = { Asset( "ANIM", "anim/player_basic.zip" ), Asset( "ANIM", "anim/player_idles_shiver.zip" ), Asset( "ANIM", "anim/player_actions.zip" ), Asset( "ANIM", "anim/player_actions_axe.zip" ), Asset( "ANIM", "anim/player_actions_pickaxe.zip" ), Asset( "ANIM", "anim/player_actions_shovel.zip" ), Asset( "ANIM", "anim/player_actions_blowdart.zip" ), Asset( "ANIM", "anim/player_actions_eat.zip" ), Asset( "ANIM", "anim/player_actions_item.zip" ), Asset( "ANIM", "anim/player_actions_uniqueitem.zip" ), Asset( "ANIM", "anim/player_actions_bugnet.zip" ), Asset( "ANIM", "anim/player_actions_fishing.zip" ), Asset( "ANIM", "anim/player_actions_boomerang.zip" ), Asset( "ANIM", "anim/player_bush_hat.zip" ), Asset( "ANIM", "anim/player_attacks.zip" ), Asset( "ANIM", "anim/player_idles.zip" ), Asset( "ANIM", "anim/player_rebirth.zip" ), Asset( "ANIM", "anim/player_jump.zip" ), Asset( "ANIM", "anim/player_amulet_resurrect.zip" ), Asset( "ANIM", "anim/player_teleport.zip" ), Asset( "ANIM", "anim/wilson_fx.zip" ), Asset( "ANIM", "anim/player_one_man_band.zip" ), Asset( "ANIM", "anim/shadow_hands.zip" ), Asset( "SOUND", "sound/sfx.fsb" ), Asset( "SOUND", "sound/wilson.fsb" ), Asset( "ANIM", "anim/beard.zip" ), Asset( "ANIM", "anim/mm.zip" ), Asset( "ANIM", "anim/ghost_mm_build.zip" ), } local prefabs = { "beardhair", } -- Custom starting items local start_inv = { } -- Sanity gain from killing local function onkilltarget(inst, data) --inst is the player, data.victim is the target if data.victim:HasTag("largecreature") then--if the target is a largecreature inst.components.sanity:DoDelta(50) else -- If the target isnt a largecreature inst.components.sanity:DoDelta(10) end end -- When the character is revived from human local function onbecamehuman(inst) -- Set speed when loading or reviving from ghost (optional) inst.components.locomotor.walkspeed = (TUNING.WILSON_WALK_SPEED * 1.2) inst.components.locomotor.runspeed = (TUNING.WILSON_RUN_SPEED * 1.5) end -- When loading or spawning the character local function onload(inst) inst:ListenForEvent("ms_respawnedfromghost", onbecamehuman) inst:ListenForEvent("ms_becameghost", onbecameghost) if inst:HasTag("playerghost") then onbecameghost(inst) else onbecamehuman(inst) end end -- This initializes for both the server and client. Tags can be added here. local common_postinit = function(inst) --bearded (from beard component) added to pristine state for optimization inst:AddTag("bearded") -- Minimap icon inst.MiniMapEntity:SetIcon( "mm.tex" ) end local function OnResetBeard(inst) inst.AnimState:ClearOverrideSymbol("beard") end --tune the beard economy... local BEARD_DAYS = { 4, 8, 16 } local BEARD_BITS = { 1, 3, 9 } local function OnGrowShortBeard(inst) inst.AnimState:OverrideSymbol("beard", "beard", "beard_short") inst.components.beard.bits = BEARD_BITS[1] end local function OnGrowMediumBeard(inst) inst.AnimState:OverrideSymbol("beard", "beard", "beard_medium") inst.components.beard.bits = BEARD_BITS[2] end local function OnGrowLongBeard(inst) inst.AnimState:OverrideSymbol("beard", "beard", "beard_long") inst.components.beard.bits = BEARD_BITS[3] end -- This initializes for the server only. Components are added here. local master_postinit = function(inst) inst:AddComponent("beard") inst.components.beard.insulation_factor = TUNING.INSULATION_MED --Is this the insulation you're talking about? inst.components.beard.onreset = OnResetBeard inst.components.beard.prize = "beardhair" inst.components.beard:AddCallback(BEARD_DAYS[1], OnGrowShortBeard) inst.components.beard:AddCallback(BEARD_DAYS[2], OnGrowMediumBeard) inst.components.beard:AddCallback(BEARD_DAYS[3], OnGrowLongBeard) -- choose which sounds this character will play inst.soundsname = "wolfgang" -- Uncomment if "wathgrithr"(Wigfrid) or "webber" voice is used --inst.talker_path_override = "dontstarve_DLC001/characters/" --sanity gain from killing inst:ListenForEvent("killed", onkilltarget) -- Stats inst.components.health:SetMaxHealth(100) inst.components.hunger:SetMax(150) inst.components.sanity:SetMax(100) --Hates night monsters inst.components.sanity.night_drain_mult = 1.1 --Military jacket adds small waterproofness and insulation --waterproofer (from waterproofer component) added to pristine state for optimization inst:AddTag("waterproofer") inst.entity:SetPristine() if not TheWorld.ismastersim then return inst end inst:AddComponent("waterproofer") inst:AddComponent("insulator") inst.components.waterproofer:SetEffectiveness(TUNING.WATERPROOFNESS_SMALL) inst.components.insulator:SetInsulation(TUNING.INSULATION_SMALL) --Be carful when it's hot inst.components.temperature.overheattemp = 100 inst.OnLoad = onload inst.OnNewSpawn = onload end return MakePlayerCharacter("mm", prefabs, assets, common_postinit, master_postinit, start_inv) Link to comment Share on other sites More sharing options...
Aquaterion Posted December 26, 2016 Share Posted December 26, 2016 1. yes that's the insulation im talkin bout 2. what do you mean by added under ghost_mm_build? The beard should be its own zip. called mm_beard.zip, with the atlas-0.tex containing the new beard textures, and build.bin being a copy of wilson's beard's build.bin but renamed to mm_beard internally Link to comment Share on other sites More sharing options...
4g3t1t Posted December 26, 2016 Author Share Posted December 26, 2016 In the assets under Asset( "ANIM", "anim/ghost_mm_build.zip" ), I added Asset( "ANIM", "anim/mm_beard.zip" ). I did exactly that. The beard still doesn't grow. Link to comment Share on other sites More sharing options...
4g3t1t Posted December 26, 2016 Author Share Posted December 26, 2016 (edited) I zipped it in case you'd like to look at the complete mod. Thanks so much for all your help. mm.zip (The head isn't correct, I'm fixing that now) Edited December 26, 2016 by 4g3t1t Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now