K1NGT1GER609

Registered Users
  • Content count

    52
  • Joined

  • Last visited

Community Reputation

10 Good

About K1NGT1GER609

  • Rank
    Junior Member

Badges

Don't Starve Together
  • Contributor
Oxygen Not Included
  • Alpha Contributor

Recent Profile Visitors

2,518 profile views
  1. Has things changed?

    Theres not much new to the sample character and theres no real need to update the tutorial or theres no new up to date tutorial. It has something to do with the autocompiler malfunctioning and not picking up the scml.
  2. Some codes for custom sword

    Here you go I wasn't sure if you wanted to restore health from kill or hit. As for health 5% i'd let you customize the heal as i don't know the weapon damage. Code: local function onattack(inst, owner, target) ---restores health on kill if owner.components.health and owner.components.health:GetPercent() < 1 and not target:HasTag("wall") then owner.components.health:DoDelta(8) ---heal 8, change it to your number end end local function OnHit(inst, owner, target) ----restores health on hit if owner.components.health and owner.components.health:GetPercent() < 1 and not target:HasTag("wall") then owner.components.health:DoDelta(8) ---heal 8, change it to your number end end local function fn(colour) ---the main function of your sword if not TheWorld.ismastersim then return inst end inst.components.weapon.attackrange = 8 ----how far your weapon can hit inst.components.weapon.hitrange = 8 ----how far your hits can land inst.components.weapon.onattack = onattack ---call the function for healing on kill inst.components.weapon.OnHit = OnHit ---call the function for healing on hit end
  3. [help] can't make my perks apply

    Well the reason it doesn't work is because all the functions you put activate the moment the character spawns in and pretty much become dormant throughout your play-through and that's not what you want. So you want a function that periodically checks your hunger stat so heres the code: 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/wugul.zip" ), } local prefabs = { "poop" } local start_inv = { -- Custom starting items } local function onhungerchange (inst) ----what about inbetween? you could be stuck on high speed or slow speed if you exploit it if (inst.components.hunger:GetPercent() > .8) then ----for greater 80% hunger inst.components.locomotor.walkspeed = 3.2 inst.components.locomotor.runspeed = 3 inst.components.combat.damagemultiplier = 0.8 elseif (inst.components.hunger:GetPercent() < .4) then ----for less than 40% hunger inst.components.locomotor.walkspeed = 6 inst.components.locomotor.runspeed = 7.5 inst.components.combat.damagemultiplier = 2 end end local function poopfn(inst, food) if food and inst.components.hunger:GetPercent() == 1 then ---100% hunger but timing is tricky since the counter doesn't stop at all local poo = SpawnPrefab("poop") poo.Transform:SetPosition(inst.Transform:GetWorldPosition()) end end local fn = function(inst) -- choose which sounds this character will play inst.soundsname = "wolfgang" -- Minimap icon inst.MiniMapEntity:SetIcon( "wugul.tex" ) -- Stats inst.components.health:SetMaxHealth(200) inst.components.hunger:SetMax(180) inst.components.sanity:SetMax(150) inst:DoPeriodicTask(4, poopfn, nil, inst) ----every four seconds check for full hunger and poop but you lose one hunger per 6 seconds inst:DoPeriodicTask(.5, onhungerchange, nil, inst) ---check your hunger every half second and apply the buffs and debuffs end return MakePlayerCharacter("wugul", prefabs, assets, fn, start_inv) Few last notes your poop function was checking for 300 hunger which isn't possible as you set it to max 180, and you'll have to set a condition for inbetween 40 and 80 percent as if you hit 40% you can stay below 80% and keep the speed boost indefinitely or be stuck on slow avoiding the 40%.
  4. The difference in a nutshell is that don't starve code is outdated compared to don't starve together, so you'll have to manually input everything that webber's perks do. What makes it so that you can't do the same in don't starve together is just a guess: I don't think they expect people to mod a new webber since looking at the code I didn't think they finish making spiderwhisperer into a proper class(I don't want to explain classes if you don't mind). I mean at line 28 of the spider lua code it pretty much makes it so only webber can friend spiders and anyone else who isn't webber can't make friends with spiders regardless of having the tags. So from there option one is to put next to the code and include that file in your mod and such: or giver.prefab ~= "youcharacterprefab" The problem with this option is that it will most likely make your mod crash in shipwrecked. On my monolith character I programmed a item like a unbreakable spider hat to get around it and make it compatible with shipwrecked (check the monolithbadge file). If you decide to do this item I'd recommend downloading the sample mods-sampleprefabs: Note: Before I forget put these lines of codes in you character's main function: inst.components.locomotor.triggerscreep = false -----pretty much means don't get slowed down in the spider's web and disturb the nest local nest_recipe = Recipe("spidereggsack", {Ingredient("silk", 12), Ingredient("spidergland", 6), Ingredient("papyrus", 6)}, RECIPETABS.TOWN, TECH.NONE) nest_recipe.sortkey = 1 STRINGS.RECIPE_DESC.SPIDEREGGSACK = "Get a little help from your friends." ----this line of code means you can craft spider eggs inst.components.eater.monsterimmune = true ----eat monster meat with no penalty and in your prefabs(I don't remember if it's important but it doesn't hurt to put it): local prefabs = { "webber", } monolithbadge.lua
  5. Not sure what you're trying to do as common_postint and master_postint are dont starve together code and were in dont starve forums. If ur trying to put that code in a dont starve mod just put it in the local fn. Other than that if ur trying dont starve together modding ull have to modify the file. So thats where the difference between the functions come in: common is used for tags and minimap code, as for master is where the rest of the characters code goes. Master had the stats perks custom functions like ur code and more is stored in.
  6. For spider characters they usually have the lines of code in their character lua: inst:AddTag("spiderwhisperer") inst:AddTag("monster") The spiderwhisperer tag removes the sanity drain from spiders but requires the monster tag to be neutral to them. Theres also another problem with using the outdated dont starve code, the code only allows webber to friend spiders so if u want to friend spiders u either edit the spider lua and risk incompatability with shipedwrecked by adding ur characters prefab name with webber or figure out how to use the spider hat's ability with ur character.
  7. Well this is the wrong forum section to post your problem as this is the don't starve forum and not the don't starve together forum. Usually this glitch happens under few possiblities. First is a few lines of code that isn't there(goes in the main function): inst.entity:AddNetwork() ----makes sure that everyone on the server can get it inst.entity:SetPristine() The other is that the search paths on your mod for imagename and atlasname may be wrong, usually keeping the files the same name as the weapon is recommended. And last is that if your using the wand template that's here it causes some strange glitches that I really can't explain but in the end is just to keep trying to recreate it.
  8. Id be interested in that offer.
  9. Technically yes, I mean theres not much to get out of the summer vest besides a few lines of code (unless your going for durability on use) and the backpack is the only one that needs more work in terms placing the code to use. I don't think there's much need for additional code that isn't in those files.
  10. It is possible to make a breezy vest n backpack combination but in dst theres a problem with cave servers running along side. The breezy vest summer and winter only difference is insulation amount n looks. For the backpack it hasnt been done where they work along side cave servers. If you copy and paste the code that makes the widgets it works for noncave server games. Ive searched around large mods, forums, asked a few modders and such but theres no getting around the error in cave servers.
  11. Alright think I got it, the zip file has been placed tested it out and it may crash first time around for no real good reason(just reload the game). roxmod.zip
  12. There's no zip?
  13. White outline

    The pictures are ok, how to fix it on a spear anim file is difficult since its very limited on space so its easier to use a wand template from here. So there's the icespear zip just know to make multiple copies as the mod file is very...unpredictable and causes strange errors even though the code is right. icespear.zip
  14. There's a chance the .fsb file changes its name everytime you build. At this point the only way to help you is to see the file itself since there's no other suggestions left I think.
  15. Hmm strange I thought you already replace the mp3 files with .wav in fmod, well do that and rebuild the .fev and .fsb files. Other than that I'd say if it doesn't work then theres lots of possibilities of what is wrong.