Search the Community

Showing results for tags 'script'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Hot Lava
    • [Hot Lava] - General Discussion
    • [Hot Lava] - Suggestions and Feedback
    • [Hot Lava] - Bug Tracker
    • [Hot Lava] - Strats and Records
    • [Hot Lava] - Developer Log
    • Hot Lava Latest Update
  • Griftlands
    • [Griftlands Early Access] - General Discussion
    • [Griftlands Early Access] - Suggestions and Feedback
    • [Griftlands Early Access] - Mods and Tools
    • [Griftlands Early Access] - Localization
    • [Griftlands Early Access] - Bug Tracker
    • [Griftlands Early Access] - Developer log
  • Oxygen Not Included
    • Oxygen Not Included FAQ
    • [Oxygen Not Included] - Developer log
    • [Oxygen Not Included] - General Discussion
    • [Oxygen Not Included] - Mods and Tools
    • [Oxygen Not Included] - Suggestions and Feedback
    • [Oxygen Not Included] - Bug Tracker
    • [Oxygen Not Included] Art, Music & Lore
    • Community Challenges
    • [Oxygen Not Included] - Latest Content Update
    • [Oxygen Not Included] - Latest Animated Short
  • Don't Starve Together
    • Don't Starve Together FAQ
    • [Don't Starve Together] Developer log
    • [Don't Starve Together] General Discussion
    • [Don't Starve Together] Return of Them
    • [Don't Starve Together] PS4
    • [Don't Starve Together] Xbox One
    • [Don't Starve Together] Bug Tracker
    • [Don't Starve Together] Trading
    • [Don't Starve Together] Server Bulletin
    • [Don't Starve Together] Dedicated Server Discussion
    • [Don't Starve Together] Mods and Tools
    • [Don't Starve Together] Tales of Life and Death
    • [DS + DST] Art, Music and Lore
    • [Don't Starve Together] Suggestions and Feedback
    • [Don't Starve Together] The Forge
    • [Don't Starve Together] The Gorge
    • [Archived Bugs]
  • Don't Starve
    • Don't Starve FAQ
    • [Don't Starve: Pocket Edition] iOS / Android
    • [Don't Starve] General Discussion
    • [Don't Starve] Mods and tools
    • [Don't Starve] Art, Music & Lore
    • [Don't Starve] Suggestions and Feedback
    • [Don't Starve] Videos
    • [Don't Starve] Bug Tracker
    • [Don't Starve] Trading
    • [Don't Starve] Testing Discussion (archive)
  • Klei Entertainment Games
  • Other Stuff

Categories

  • Don't Starve
    • Custom Character and Skins
    • Game Modifications
    • Language Packs
    • Modding Tools, Tutorials & Examples
    • Custom Maps

Categories

  • Oxygen Not Included
  • Griftlands - [Early Access]
  • Don't Starve: Hamlet
  • Don't Starve: Hamlet Early Access
  • Don't Starve Together
  • Don't Starve Together: Return of Them
  • Don't Starve Together: The Gorge
  • Don't Starve Together: The Forge
  • Don't Starve Together: The Forge (Archive)
  • [Don't Starve Together] PS4
  • [Don't Starve Together] Xbox One
  • Don't Starve: Shipwrecked
  • Don't Starve: Shipwrecked [archive]
  • [Don't Starve Together] PS4 (archive)
  • [iOS] Don't Starve: Shipwrecked
  • Don't Starve: Hamlet Closed Beta (ARCHIVE)

Categories

  • Oxygen Not Included
  • Griftlands - [Early Access]
  • Hot Lava
  • Don't Starve Together
  • [PS4] Don't Starve Together
  • [Xbox One] Don't Starve Together
  • Don't Starve: Hamlet
  • Don't Starve: Shipwrecked

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End



Biography


Location


Interests


Occupation


Favorite Game


Modder


Chester Kickstarter


Chester Kickstarter


Chester Kickstarter


Chester Kickstarter


Chester Kickstarter


Klei Featured Artist


Early Supporter


Early Supporter


Don't Starve


Don't Starve Together

Found 8 results

  1. Hi Guys, Loko back from my long break of don't starve modding, Been a while saw a lot of posts on the steam forums, and wiki about moving volt goats, it's such a hassle to move them slowly rather than a quick alternative, Course some people just kill them all and spawn a new one at their base or where ever, but people like me, coutn that as cheating and don't really want to do that, So i want to create a mod to pick up said "lightninggoats" and drop them where we want them while setting a home for them in that specific location, inst:AddComponent("inspectable") inst:AddComponent("inventoryitem") inst.components.inventoryitem.canbepickedup = true inst.components.inventoryitem.cangoincontainer = true inst.components.inventoryitem.nobounce = false Is what i have at the moment to pick up said goat, and drop them, however, they will constantly move at the wall trying to get to their "home" location, and they also spawn with the light that gives off the aura when they are stricken with lightning. The script im using is the basegame lightninggoat script, which is here. Any help would be appreciated. local assets = { Asset("ANIM", "anim/lightning_goat_build.zip"), Asset("ANIM", "anim/lightning_goat_shocked_build.zip"), Asset("ANIM", "anim/lightning_goat_basic.zip"), Asset("ANIM", "anim/lightning_goat_actions.zip"), Asset("SOUND", "sound/lightninggoat.fsb"), } local prefabs = { "meat", "lightninggoathorn", "goatmilk", "lightninggoatherd", } local brain = require("brains/lightninggoatbrain") SetSharedLootTable( 'lightninggoat', { {'meat', 1.00}, {'meat', 1.00}, {'lightninggoathorn', 0.25}, }) SetSharedLootTable( 'chargedlightninggoat', { {'meat', 1.00}, {'meat', 1.00}, {'goatmilk', 1.00}, {'lightninggoathorn', 0.25}, }) local function RetargetFn(inst) if inst.charged then local function CheckTarget(guy) return inst.components.combat:CanTarget(guy) end return -- Look for non-wall targets first FindEntity( inst, TUNING.LIGHTNING_GOAT_TARGET_DIST, CheckTarget, { "_combat" }, { "lightninggoat", "wall" }) or -- If none, look for walls FindEntity( inst, TUNING.LIGHTNING_GOAT_TARGET_DIST, CheckTarget, { "_combat", "wall" }, { "lightninggoat" }) or nil end end local function KeepTargetFn(inst, target) if target:HasTag("wall") then --Don't keep wall target if a non-wall target is available return FindEntity( inst, TUNING.LIGHTNING_GOAT_TARGET_DIST, function(guy) return inst.components.combat:CanTarget(guy) end, { "_combat" }, { "lightninggoat", "wall" }) == nil end --Don't keep target if we chased too far from our herd local herd = inst.components.herdmember ~= nil and inst.components.herdmember:GetHerd() or nil return herd == nil or inst:IsNear(herd, TUNING.LIGHTNING_GOAT_CHASE_DIST) end local function discharge(inst) inst:RemoveTag("charged") inst.components.lootdropper:SetChanceLootTable('lightninggoat') inst.sg:GoToState("discharge") inst.AnimState:ClearBloomEffectHandle() inst.charged = false inst.Light:Enable(false) inst.chargeleft = nil end local function ReduceCharges(inst) if inst.chargeleft then inst.chargeleft = inst.chargeleft - 1 if inst.chargeleft <= 0 then discharge(inst) end end end local function setcharged(inst, instant) inst:AddTag("charged") inst.components.lootdropper:SetChanceLootTable('chargedlightninggoat') inst.AnimState:SetBuild("lightning_goat_shocked_build") inst.AnimState:Show("fx") if not instant then inst.sg:GoToState("shocked") end inst.AnimState:SetBloomEffectHandle("shaders/anim.ksh") inst.charged = true inst.chargeleft = 3 inst.Light:Enable(true) inst:WatchWorldState("cycles", ReduceCharges) end local function IsChargedGoat(dude) return dude:HasTag("lightninggoat") and dude:HasTag("charged") end local function OnAttacked(inst, data) if data ~= nil and data.attacker ~= nil then if inst.charged then if data.attacker.components.health ~= nil and not data.attacker.components.health:IsDead() and (data.weapon == nil or ((data.weapon.components.weapon == nil or data.weapon.components.weapon.projectile == nil) and data.weapon.components.projectile == nil)) and not (data.attacker.components.inventory ~= nil and data.attacker.components.inventory:IsInsulated()) then data.attacker.components.health:DoDelta(-TUNING.LIGHTNING_GOAT_DAMAGE, nil, inst.prefab, nil, inst) if data.attacker:HasTag("player") then data.attacker.sg:GoToState("electrocute") end end elseif data.weapon ~= nil and data.weapon.components.weapon ~= nil and data.weapon.components.weapon.stimuli == "electric" then setcharged(inst) end inst.components.combat:SetTarget(data.attacker) inst.components.combat:ShareTarget(data.attacker, 20, IsChargedGoat, 3) end end local function OnSave(inst, data) if inst.charged then data.charged = inst.charged data.chargeleft = inst.chargeleft end end local function OnLoad(inst, data) if data and data.charged and data.chargeleft then setcharged(inst, true) inst.chargeleft = data.chargeleft end end local function getstatus(inst) return inst.charged and "CHARGED" or nil end local function fn() local inst = CreateEntity() inst.entity:AddTransform() inst.entity:AddAnimState() inst.entity:AddSoundEmitter() inst.entity:AddDynamicShadow() inst.entity:AddLight() inst.entity:AddNetwork() inst.DynamicShadow:SetSize(1.75, .75) inst.Transform:SetFourFaced() MakeCharacterPhysics(inst, 100, .5) inst.AnimState:SetBank("lightning_goat") inst.AnimState:SetBuild("lightning_goat_build") inst.AnimState:PlayAnimation("idle_loop", true) inst.AnimState:Hide("fx") ------------------------------------------ inst:AddTag("lightninggoat") inst:AddTag("animal") inst:AddTag("lightningrod") --herdmember (from herdmember component) added to pristine state for optimization inst:AddTag("herdmember") --saltlicker (from saltlicker component) added to pristine state for optimization inst:AddTag("saltlicker") inst.Light:Enable(false) inst.Light:SetRadius(.85) inst.Light:SetFalloff(0.5) inst.Light:SetIntensity(.75) inst.Light:SetColour(255 / 255, 255 / 255, 236 / 255) inst.entity:SetPristine() if not TheWorld.ismastersim then return inst end ------------------------------------------ inst:AddComponent("health") inst.components.health:SetMaxHealth(TUNING.LIGHTNING_GOAT_HEALTH) ------------------ inst:AddComponent("combat") inst.components.combat:SetDefaultDamage(TUNING.LIGHTNING_GOAT_DAMAGE) inst.components.combat:SetRange(TUNING.LIGHTNING_GOAT_ATTACK_RANGE) inst.components.combat.hiteffectsymbol = "lightning_goat_body" inst.components.combat:SetAttackPeriod(TUNING.LIGHTNING_GOAT_ATTACK_PERIOD) inst.components.combat:SetRetargetFunction(1, RetargetFn) inst.components.combat:SetKeepTargetFunction(KeepTargetFn) inst.components.combat:SetHurtSound("dontstarve_DLC001/creatures/lightninggoat/hurt") ------------------------------------------ inst:AddComponent("sleeper") inst.components.sleeper:SetResistance(4) ------------------------------------------ inst:AddComponent("lootdropper") inst.components.lootdropper:SetChanceLootTable('lightninggoat') ------------------------------------------ inst:AddComponent("inspectable") inst.components.inspectable.getstatus = getstatus inst:AddComponent("inventoryitem") inst.components.inventoryitem.canbepickedup = true inst.components.inventoryitem.cangoincontainer = true inst.components.inventoryitem.nobounce = false ------------------------------------------ inst:AddComponent("knownlocations") inst:AddComponent("herdmember") inst.components.herdmember:SetHerdPrefab("lightninggoatherd") ------------------------------------------ inst:ListenForEvent("attacked", OnAttacked) ------------------------------------------ inst:AddComponent("timer") inst:AddComponent("saltlicker") inst.components.saltlicker:SetUp(TUNING.SALTLICK_LIGHTNINGGOAT_USES) ------------------------------------------ MakeMediumBurnableCharacter(inst, "lightning_goat_body") MakeMediumFreezableCharacter(inst, "lightning_goat_body") inst:ListenForEvent("lightningstrike", setcharged) inst.setcharged = setcharged inst.OnSave = OnSave inst.OnLoad = OnLoad ------------------------------------------ inst:AddComponent("locomotor") inst.components.locomotor.walkspeed = TUNING.LIGHTNING_GOAT_WALK_SPEED inst.components.locomotor.runspeed = TUNING.LIGHTNING_GOAT_RUN_SPEED MakeHauntablePanic(inst) inst:SetStateGraph("SGlightninggoat") inst:SetBrain(brain) return inst end return Prefab("lightninggoat", fn, assets, prefabs)
  2. I posted this already but in a wrong section. So i try it with the "modding"-section again :3 This time I will also upload my scripts not only the error. "Here is the error-text :[string *scripts/mainfunctions.lua*]:119: Error loading file prefabs/Ren[string *../mods/Ren/scripts/prefabs/Ren.lua*]:62: function arguments expected near "="LUA ERROR strack traceback:=[C] in function 'assert'scripts/mainfunctions.lua(119.1)=(tail call) ?scripts/mods.lua(154.1)scripts/mods.lua(593.1) in function 'RegisterPrefabs'scripts/gamelogic.lua(226.1) in function 'LoadAssets' " Ren.lua hounded.lua modmain.lua
  3. I posted this already but in a wrong section. So i try it with the "modding"-section again :3 This time I will also upload my scripts not only the error. "Here is the error-text :[string *scripts/mainfunctions.lua*]:119: Error loading file prefabs/Ren[string *../mods/Ren/scripts/prefabs/Ren.lua*]:62: function arguments expected near "="LUA ERROR strack traceback:=[C] in function 'assert'scripts/mainfunctions.lua(119.1)=(tail call) ?scripts/mods.lua(154.1)scripts/mods.lua(593.1) in function 'RegisterPrefabs'scripts/gamelogic.lua(226.1) in function 'LoadAssets' " hounded.lua modmain.lua Ren.lua
  4. -I would like to have my character say only a set few phrases, like Wilton or Wilbur, but I don't know the scripts, or where to put them. -And, uh, this is kind of a weird question, but is it possible to make my character drop every tool they try to equip? Like when someone tries to pick up Lucy the Axe? They don't have arms, and it would be weird to have floating tools. I was planning on making them dependent on other players, if you're curious.
  5. This is for a Waverly mod I'm making. It needs to be able to craft Wickerbottom's books, and must make all neutral and hostile, or other, mobs to attack her on sight. Thanks in advance. ~Union
  6. hello people I follow the forum a long time,but not write much here today decided to post a picture. (sorry for my english)I could not resist....grows a magnificent bearmy dog ​​paints better than me:highly_amused:the b,w versionwilson loves the water
  7. Bug Submission Please choose a category [Gameplay] Platform SteamVersion Number - Issue title Stuck on thw world creation screen Steps to reproduce create a new test world Describe your issue i stared at the screen for maybe 2 minutes until i thought im going restart it, good news it worked and i can play still felt like it needed to be report just in case other players have the same problem