AkaiNight Posted July 14, 2017 Share Posted July 14, 2017 (edited) Hello guys this topic about some questions for making custom character custom items. I have some (lots of) question. The first of all, is there any guide topic for making a custom weapon and armor and amulet and ofcourse backpack? If there is i can't find it so i hope you guys answer my questions. The first one: How can i make my character can't wear any backpacks except my custom item can't wear anything except my custom item can't use chester (can't pick eyebone too) can't use any weapon or tool except my custom item well is it possible to add my character 3 more stats like health, sanity and hunger? first one soulholder for every kill captures 1 soul and the second one for tools when cut a tree or mine a thing or hammer a thing or razor a thing shovel a thing or pick a ground 1 points up and the third one for catch bugs or fish for every catch 1 points up or everytime you use pen of phoenix 1 points up it it possible to make this and can i make this like health bar shown of right top of screen like little health bar And the second one: How do i know if code is working or not? Because i'm using this code for Critters sanity aura local function critter_SanityAura(inst) local x, y, z = inst.Transform:GetWorldPosition() local delta = 0 local ents = TheSim:FindEntities(x, y, z, 20, {"critter_puppy", "critter_kitten"}) local bonus_sanity = nil -- initialise local distsq = nil -- initialise local totalDelta = nil -- initialise for k, v in pairs(ents) do if v ~= inst then if v.entity == "critter_puppy" then -- Lose sanity here bonus_sanity = -TUNING.SANITYAURA_MEDIUM distsq = math.max(inst:GetDistanceSqToInst(v), 1) delta = delta + bonus_sanity / distsq elseif v.entity == "critter_kitten" then -- Gain sanity here bonus_sanity = TUNING.SANITYAURA_SMALL distsq = math.max(inst:GetDistanceSqToInst(v), 1) delta = delta + bonus_sanity / distsq else -- do nothing; I like to have else clauses just in case. end end totalDelta = totalDelta + delta end if #ents > 0 then -- actually you could move this up to just before the for loop (save some processing power). totalDelta = totalDelta / #ents else totalDelta = 0 end return totalDelta end and it seems like not working but i can't be sure also i'm using a code for foods but this part is not working that should make every eatable things in game makes give 5 hunger and -10 sanity but when eat something the server stops working elseif food and food.components.edible and food.prefab == not "ice" or "fish_cooked" or "fish" or "fishtacos" or "fishsticks" then local hungerboost = 5 local sanityboost = -10 local foodcheck = food.inst.prefab == "spoiled_food" and 0 or hungerboost inst.components.health:DoDelta(0) inst.components.sanity:DoDelta(0) inst.components.hunger:DoDelta(5 - food:GetHunger() * eater.hungerabsorption) inst.components.talker:Say("I shouldn't eat that. Nya~") end and that makes game crash no error no warning just white screen inst.AddTag("fridge") And the other problem custom weapon well i'm trying to do a SUPER-MULTI-ULTRA-WEAPONTOOL here is what i want to add to weapon --fight 1-sword of immortal: makes high damage, slowly hits, restores health %3 of damage (key shift+1) 2-scythe : low damage, attacks nearby enemies too, fastly hits (key shift+2) 3-ice bow: normal damage, little fast, slows enemy (no need ammo takes 3 sanity per attack if santy less than 5 can't attack) (slows %50 for 2 seconds) (key shift+3) --light 4-wand of light: with 'c' glows and turns off, like infinity lamb (takes 30sanity per 30 sec) (if santy less then 35 can't use) (key shift+4) 5-wand of priestess: heals nearby players (3per sec) and herself (1 per sec) and nearby players gain little sanity regen (takes 10 sanity per 3 sec) (if sanity less than 50 can't use) (key shift+5) 6-instrument of heaven: gains sanity (medium) when played with a custom animation like flute (key shift+6) --dark 7-spear of lavaqueen: has long hit range, low damage, slow attack speed, burns when hit (3 seconds and 2 damage per sec) (key shift+7) 8-book of death: slows everyone on map and hit slower (takes 3 healt per sec) (if health less than 25 can't use) (key shift+8) 9-dart of snake lord: large range, hit slow, low damage, poisonly (takes 3 sanity per attack) (poison for 5 sec and makes 2 dmg per sec) (if santy less than 5 can't attack) (key shift+9) --tool 10-Rockdestroyer: Just normal pickaxe (key ctrl+1) 11-Forestkiller: Just normal axe (key ctrl+2) 12-JustShovel: As named Just shovel (key ctrl+3) 13-Destroyer: Just a hammer (key ctrl+7) 14-Groundpicker: Just a pitch fork (key ctrl+4) 15:Raazor: not a razor it's Raazor but it's just a simple razor but can't use for shave beard (key ctrl+8) --stuff 16-Rod Of Megaladon: Just an infinity rod (key ctrl+5) 17:Bugcatcher: Just a normal bug net (key ctrl+6) 18:Pen of phoenix: Just a feather pencil (key ctrl+9) and if it possible can i add my weapon lvl system but using souls, treepoints, minepoints and catch points i mean when you got 10 catch points you can use pen of phoenix. Like after kill 10 mob you can use scythe? and if it's possible to make can it change skin when changed weapon or tool type? I mean when you use the scythe it turns a scythe, when you use spear of lavaquenn it changes to a spear? and i forget to ask how i can make custom skin is there any guide for it? Edited July 15, 2017 by AkaiNight Link to comment Share on other sites More sharing options...
AkaiNight Posted July 20, 2017 Author Share Posted July 20, 2017 No answers? Link to comment Share on other sites More sharing options...
AkaiNight Posted July 27, 2017 Author Share Posted July 27, 2017 Still no answer? Link to comment Share on other sites More sharing options...
ZupaleX Posted July 27, 2017 Share Posted July 27, 2017 Hello, If you look through the threads which have been posted and answered for the past week or so you would find the answer to your first question regarding what a character can equip or not. For the rest I have to admit I saw your post but it's just too much. You are asking so many questions at once I just did not want to read. Better if you decide what task you want to focus on first and ask a question about that. When it is solved, you move on to the next one and ask for help again. Just throwing all your idea and trying to solve all the issues at once is counter productive. Link to comment Share on other sites More sharing options...
Lumina Posted July 27, 2017 Share Posted July 27, 2017 Yeah, also people are here to help. A big topic like this could create the feeling (right or false, it doesn't really matter) that they are doing too much of the work. It's important to keep things reasonable. And maybe not trying stuff too complicated if you must ask help for too many things, even if it's hard to do this when you have a lot of ideas. 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