sawedoffsob Posted December 21, 2015 Share Posted December 21, 2015 Hi, i'm trying to figure out how to add multiple items to beard drop from shaving.. I tried! inst:AddComponent("beard") inst.components.beard.insulation_factor = TUNING.WEBBER_BEARD_INSULATION_FACTOR inst.components.beard.onreset = OnResetBeard inst.components.beard.prize = ("silk") inst.components.beard.prize = ("beardhair") I also tried inst.components.beard.prize = ("silk", "beardhair") But it didn't work either... I only get 2 silk or either 2 beard hair.. The first part of the code is local BEARD_DAYS = { 2, 4, 6 }local BEARD_BITS = { 2, 6, 9 } thanks for the help in advance.. What I would like is 1 silk + 1 beard hair per Beard_Day Link to comment https://forums.kleientertainment.com/forums/topic/61124-help-with-code-for-beard-shave-items/ Share on other sites More sharing options...
ZupaleX Posted December 21, 2015 Share Posted December 21, 2015 Neither of the two can work because prize is supposed to be a string. The first one will set first "silk" as a drop, then the next line just replace the value "silk" by "beardhair".The second makes no sense and probably crashed (?). You'll have to modify the Shave function from the beard.lua component if you want to have multiple loot from shaving the beard because it is madein a way that it just spawn one kind of prefab, which is the string you assigned to the member prize. Link to comment https://forums.kleientertainment.com/forums/topic/61124-help-with-code-for-beard-shave-items/#findComment-700034 Share on other sites More sharing options...
YiinHikari Posted December 25, 2015 Share Posted December 25, 2015 This is really helpful!Hi, I am trying to use the beard system for other thing... that works ib the same way but just look different (a hairtail instead of beard in the face) but I need to know how to add this in a character mod, and also and most important, how can I do to fit the art for this? because I found the atlas-0 of wilson's beard, but since I don't have the spriter or exported files (like in the extended character sample) I can't know how I may edit that atlas to make it work, yet don't know if editing that atlas will work (beeing a file/anim already compiled) in the first place!Please (if you understand my message... sorry if my english is bad) can you guide me with this idea? Thank you!!!! Link to comment https://forums.kleientertainment.com/forums/topic/61124-help-with-code-for-beard-shave-items/#findComment-701954 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