Well-met Posted March 29, 2019 Share Posted March 29, 2019 ey I'm having trouble compiling a decent ghost .scml for my character so for now I basically just want to give up that part and force my character to use the same ghost build as the actual ghost mob. local assets = { Asset("SCRIPT", "scripts/prefabs/player_common.lua"), Asset("ANIM", "anim/player_ghost_withhat.zip"), Asset("ANIM", "anim/ghost_build.zip"), } local function onbecameghost(inst) inst.components.skinner:SetSkinMode("ghost_skin") end This is what I had so far but obviously it doesn't work. Checked how beaver woodie does it and they use inst.components.skinner:SetSkinMode("ghost_werebeaver_skin") any ideas? Link to comment https://forums.kleientertainment.com/forums/topic/104296-force-ghost-skin/ Share on other sites More sharing options...
pickleplayer Posted March 30, 2019 Share Posted March 30, 2019 That's an interesting solution, but it might get a bit more complicated than that, since the ghost build might not share everything that the player ghost builds have. If you're really lucky and the ghost mob and player ghosts have identical banks, you can probably get away with just changing the build when they turn into a ghost. inst.AnimState:SetBuild("ghost_build") inst.AnimState:PlayAnimation("idle", true) --start the idle animation Otherwise, you'll need to add inst.AnimState:SetBank("ghost") into the mix and forgo any of the ghost player's animation bank, But I imagine this could have some unintended side effects... I'd check to see if the regular ghost mob has all the same animations that the player ghosts do (haunting things, talking(?) doing whatever ghosts do) and all the same animation names. (you can generally find most animations in a mob's stategraph and do a search for "AnimState:PlayAnimation") If the ghost is missing any animation names, your character will just become invisible for those animations. Link to comment https://forums.kleientertainment.com/forums/topic/104296-force-ghost-skin/#findComment-1171553 Share on other sites More sharing options...
Well-met Posted March 31, 2019 Author Share Posted March 31, 2019 (edited) yup works just fine. Ghost Mob share 1:1 of the necessary anims/assets used by ghost players thanks man Edited March 31, 2019 by Hell-met Link to comment https://forums.kleientertainment.com/forums/topic/104296-force-ghost-skin/#findComment-1172070 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