Kafaid Posted March 21, 2015 Share Posted March 21, 2015 Hello! I wanted to try to make my own custom character, which was going pretty great yesterday but somehow I broke it today when I was trying to rename her from Nimble to Wicked. (In the code I used nim -> wik ) Edit: it is fixed now! She works again Now I will slowly work on the features I wanted to add. Hopefully It will not heck up again. You can test out this mod here: If someone could give me some pointers that would be really appreciated ; u ; (Also when she was working, her sprite seemed to be glitching a little? Her head for when she wears a hat ended up showing up on top of her normal head.) Her intended traits:-runs fast (or faster when there is gold/gold tools/gems in her inventory?)-hits hard-low sanity (but gold gives her sanity boost)-picky eater (like wickerbottom)- Refusal to eat anything not a dish from crockpot- Possible custom items- No sanity drop when digging graves- Pigs see her as a monster Link to comment Share on other sites More sharing options...
Patriarachnid Posted March 21, 2015 Share Posted March 21, 2015 This is a good general guide for character making, and a lot more up-to-date than the other "artist's guide" I assume you used.http://forums.kleientertainment.com/topic/46849-tutorial-using-extended-sample-character-template/ If your mod's started crashing due to you changing the name, most likely it's just that you didn't change the name everywhere in the files. Also, there's a handy little log.txt thing in your files somewhere that will usually have a bit telling you what you've borked up that caused the crash. Also also, the "hat" head should just be the normal head sprite with the bits that will be covered by hats erased, instead of a completely seperate drawing. Also also also, just a little general character-making tip, try to make her have some big (for lack of a better word) gimmick that'll set her apart from other characters folks have made. Like... I dunno, she crafts rocks and gold into gems, or makes nifty gem weapons, or eats gems to turn into the mighty Gemzilla. There aren't really any limits to what you can do, so get creative with it. Link to comment Share on other sites More sharing options...
Auth Posted March 21, 2015 Share Posted March 21, 2015 Hate to break it to you, but, that name is already taken by another modded character. If you plan on releasing it to the workshop, I'd change her name. Link to comment Share on other sites More sharing options...
Kafaid Posted March 21, 2015 Author Share Posted March 21, 2015 @Patriarachnid Thanks for the advice! That new tutorial is much easier to follow and easier to edit lmao. It's working again but now I have to update all the sprite art. @weirdobob If I name the workshop file "WickedTheThief" will the code still work? I don't really care if other people have already used the name as long as it doesn't affect the code lol; Link to comment Share on other sites More sharing options...
Corrosive Posted March 21, 2015 Share Posted March 21, 2015 @Kafaid, Select some text in a person's post for the little popup that allows you to mention them to appear. That way they get notifications when you respond to them. Anyhoo-- the workshop name doesn't matter at all. You'll want to give it a unique name though. You'll also probably want to make sure that the code internally refers to wicked as something other than what the other mod's character uses. It appears that the other mod's character is internally called 'wik', so you should be safe. Link to comment Share on other sites More sharing options...
seronis Posted March 21, 2015 Share Posted March 21, 2015 More important people should STOP CARING ABOUT W'S. Ugh Link to comment Share on other sites More sharing options...
Kafaid Posted March 21, 2015 Author Share Posted March 21, 2015 @Corrosive Oh thanks! I didn't realize I had to do that lol. (used to another forum where you just use the @) I might change the name back to Nimble again but it just depends how tired I am when I'm done updating the sprite lol.I finally got the character to work again and don't want to break it the same way as last time. > . > @seronis, I wasn't sure how much people cared about it, (or against it I guess lol?). I just wanted to make a character that was consistent-ish with the style of the core game. The name was actually different before I realized all the names started with Ws. Link to comment Share on other sites More sharing options...
Patriarachnid Posted March 21, 2015 Share Posted March 21, 2015 More important people should STOP CARING ABOUT W'S. Ugh The truth, right here There are only so many names that start with W, and even fewer that aren't either dumb or taken. Link to comment Share on other sites More sharing options...
Corrosive Posted March 21, 2015 Share Posted March 21, 2015 @Kafaid, @Patriarachnid, I still like the W constriction Link to comment Share on other sites More sharing options...
Coski Posted March 22, 2015 Share Posted March 22, 2015 looks good @Kafaid, Link to comment Share on other sites More sharing options...
Kafaid Posted March 25, 2015 Author Share Posted March 25, 2015 Added a work in progress version to steam workshop You guys can now test it out if you like. http://steamcommunity.com/sharedfiles/filedetails/?id=412698227 Link to comment Share on other sites More sharing options...
Kafaid Posted March 27, 2015 Author Share Posted March 27, 2015 Also I've been having issues trying to figure out how to set it so she can only eat crock pot foods. these are the only pre-determined fuctions I can find, and non of them are exclusively crockpot. Is there an easy way to define my own? I'm not really sure what Eater:OnRemoveFromEntity() does and what parameters are necessary.function Eater:SetVegetarian()self.foodprefs = { FOODTYPE.VEGGIE }endfunction Eater:SetCarnivore()self.foodprefs = { FOODTYPE.MEAT }endfunction Eater:SetInsectivore()self.foodprefs = { FOODTYPE.INSECT }endfunction Eater:SetBird()self.foodprefs = { FOODTYPE.SEEDS }endfunction Eater:SetSmallBird()self.foodprefs = { FOODGROUP.BERRIES_AND_SEEDS }endfunction Eater:SetBeaver()self.foodprefs = { FOODTYPE.WOOD }endfunction Eater:SetElemental()self.foodprefs = { FOODTYPE.ELEMENTAL }end Link to comment Share on other sites More sharing options...
Mobbstar Posted March 27, 2015 Share Posted March 27, 2015 Also I've been having issues trying to figure out how to set it so she can only eat crock pot foods. these are the only pre-determined fuctions I can find, and non of them are exclusively crockpot. Is there an easy way to define my own? I'm not really sure what Eater:OnRemoveFromEntity() does and what parameters are necessary.function Eater:SetVegetarian()self.foodprefs = { FOODTYPE.VEGGIE }endfunction Eater:SetCarnivore()self.foodprefs = { FOODTYPE.MEAT }endfunction Eater:SetInsectivore()self.foodprefs = { FOODTYPE.INSECT }endfunction Eater:SetBird()self.foodprefs = { FOODTYPE.SEEDS }endfunction Eater:SetSmallBird()self.foodprefs = { FOODGROUP.BERRIES_AND_SEEDS }endfunction Eater:SetBeaver()self.foodprefs = { FOODTYPE.WOOD }endfunction Eater:SetElemental()self.foodprefs = { FOODTYPE.ELEMENTAL }end You should set a caneattest to somehow limit the choice of food to what you want. Foodprefs aren't suitable for this kind of limitation. samplelocal function CanEat(inst, food)--test for whether it's prepared food[...]end local function fn() --or 'local fn = function()', it doesn't matter[...] inst.components.eater.caneattest = CanEat return instend EDIT: In the test function, you'd have to use an if-block like so:if [is_prepared_dish] then return trueendreturn false --can't return when the function already returned true Link to comment Share on other sites More sharing options...
Corrosive Posted March 27, 2015 Share Posted March 27, 2015 @Kafaid, Just to tack on to what Mobbstar said... Foods cooked in a crockpot generally all share the same base initialization function, which is located in preparedfoods.lua. You'll notice that it adds the tag "preparedfood" to every instance. Your caneattest function can be very simple:local function caneattestfn(inst) return inst:HasTag("preparedfood")endYou can modify it however you want, if you want to be more specific. The function needs to return the value true when the character is able to eat the instance of food passed to it, and false when not. Link to comment Share on other sites More sharing options...
Discophone Posted March 28, 2015 Share Posted March 28, 2015 Is there a list of functionalities and different commands and attributes somewhere? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.
Please be aware that the content of this thread may be outdated and no longer applicable.