Jump to content

Search the Community

Showing results for tags 'explosive'.

  • 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] - General Discussion
    • [Griftlands] - Suggestions and Feedback
    • [Griftlands] - Mods and Tools
    • [Griftlands] - Localization
    • [Griftlands] - Bug Tracker
    • [Griftlands] - Developer log
  • Oxygen Not Included
    • Oxygen Not Included FAQ
    • [Oxygen Not Included] - Developer log
    • [Oxygen Not Included] - General Discussion
    • [Oxygen Not Included] - Bug Tracker
    • [Oxygen Not Included: Spaced Out!] - Bug Tracker
    • [Oxygen Not Included] - Mods and Tools
    • [Oxygen Not Included] - Suggestions and Feedback
    • [Oxygen Not Included] Art, Music & Lore
    • Community Challenges
    • [Oxygen Not Included] - Latest Content Update
    • [Oxygen Not Included] - Latest Animated Short
    • Oxygen Not Included DLC Alpha
  • 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] Beta Branch
    • [Don't Starve Together] PlayStation
    • [Don't Starve Together] Xbox One
    • [Don't Starve Together] Nintendo Switch
    • [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
    • Eets Munchies
    • [Invisible, Inc.] General Discussion and Strategies
    • Mark of the Ninja
    • Shank
  • Other Stuff
    • Other Klei Services

Categories

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

Categories

  • Oxygen Not Included
  • Oxygen Not Included: Spaced Out!
  • Griftlands
  • Don't Starve
  • Don't Starve Together
  • Don't Starve Together: Beta Branch
  • [Don't Starve Together] Nintendo Switch
  • [Don't Starve Together] PlayStation
  • 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] Xbox One
  • Don't Starve: Shipwrecked [archive]
  • [Don't Starve Together] PS4 (archive)
  • [iOS] Don't Starve: Shipwrecked
  • Don't Starve: Hamlet [ARCHIVE]
  • Don't Starve: Shipwrecked [ARCHIVE]
  • Don't Starve: Hamlet Early Access [archive]
  • Don't Starve: Hamlet Closed Beta (ARCHIVE)

Categories

  • Oxygen Not Included
  • Oxygen Not Included: Spaced Out!
  • Griftlands
  • Hot Lava
  • Don't Starve Together
  • [Nintendo Switch] Don't Starve Together
  • [PlayStation] Don't Starve Together
  • [Xbox One] Don't Starve Together
  • Don't Starve
  • 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


Group


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


Oxygen Not Included

Found 1 result

  1. Hi, I have been working on RGD-33 grenade. I have used Napsack prefab as my template and it has no error screen so far but when I throw it it won't do any damage. I don't get all those explosive functions so if anyone here could help me I will be happier person. Prefab here: local assets= { Asset("ANIM", "anim/rgd3_nade.zip"), Asset("ANIM", "anim/swap_rgd3_nade.zip"), Asset("ATLAS", "images/inventoryimages/rgd3_nade.xml"), Asset("IMAGE", "images/inventoryimages/rgd3_nade.tex"), } local prefabs = { } local function OnEquip(inst, owner) owner.AnimState:OverrideSymbol("swap_object", "swap_rgd3_nade", "rgd3") owner.AnimState:Show("ARM_carry") owner.AnimState:Hide("ARM_normal") end local function OnUnequip(inst, owner) owner.AnimState:Hide("ARM_carry") owner.AnimState:Show("ARM_normal") end ----------------------------------------------------------------------------------- ----------------------------------------------------------------------------------- local function OnExplodeFn(inst) --nothing works SpawnPrefab("explode_small").Transform:SetPosition(x, y, z) end local function OnHit(inst, attacker, target) local x, y, z = inst.Transform:GetWorldPosition() inst:Remove() SpawnPrefab("explode_small").Transform:SetPosition(x, y, z) end local function OnThrown(inst) inst:AddTag("NOCLICK") inst.persists = false inst.AnimState:PlayAnimation("spin") inst.Physics:SetMass(1) inst.Physics:SetCapsule(0.2, 0.2) inst.Physics:SetFriction(0) inst.Physics:SetDamping(0) inst.Physics:SetCollisionGroup(COLLISION.CHARACTERS) inst.Physics:ClearCollisionMask() inst.Physics:CollidesWith(COLLISION.WORLD) inst.Physics:CollidesWith(COLLISION.OBSTACLES) inst.Physics:CollidesWith(COLLISION.ITEMS) end local function ReticuleTargetFn() local player = ThePlayer local ground = TheWorld.Map local pos = Vector3() --Attack range is 8, leave room for error --Min range was chosen to not hit yourself (2 is the hit range) for r = 6.5, 3.5, -.25 do pos.x, pos.y, pos.z = player.entity:LocalToWorldSpace(r, 0, 0) if ground:IsPassableAtPoint(pos:Get()) and not ground:IsGroundTargetBlocked(pos) then return pos end end return pos end ---------------------------------------------------- ---------------------------------------------------- ---------------------------------------------------- local function fn(Sim) local inst = CreateEntity() inst.entity:AddTransform() inst.entity:AddAnimState() inst.entity:AddNetwork() inst.entity:AddSoundEmitter() MakeInventoryPhysics(inst) inst:AddTag("projectile") inst:AddTag("explosive") inst.AnimState:SetBank("rgd3") inst.AnimState:SetBuild("rgd3_nade") inst.AnimState:PlayAnimation("idle") if not TheWorld.ismastersim then return inst end inst.entity:SetPristine() inst:AddComponent("locomotor") inst:AddComponent("reticule") inst.components.reticule.targetfn = ReticuleTargetFn inst.components.reticule.ease = true local advancedtargeting = TheNet:GetServerGameMode() == "lavaarena" if advancedtargeting then inst.components.reticule.reticuleprefab = "reticuleaoe" inst.components.reticule.pingprefab = "reticuleaoeping" inst.components.reticule.mouseenabled = true inst:AddTag("nopunch") end inst:AddComponent("inventoryitem") inst.components.inventoryitem.imagename = "rgd3_nade" inst.components.inventoryitem.atlasname = "images/inventoryimages/rgd3_nade.xml" inst:AddComponent("inspectable") inst:AddComponent("equippable") MakeHauntableLaunch(inst) inst.components.equippable:SetOnEquip( OnEquip ) inst.components.equippable:SetOnUnequip( OnUnequip ) inst:AddComponent("complexprojectile") inst.components.complexprojectile:SetHorizontalSpeed(15) inst.components.complexprojectile:SetGravity(-35) inst.components.complexprojectile:SetLaunchOffset(Vector3(.25, 1, 0)) inst.components.complexprojectile:SetOnLaunch(OnThrown) inst.components.complexprojectile:SetOnHit(OnHit) if not advancedtargeting then inst:AddComponent("weapon") inst.components.weapon:SetDamage(0) inst.components.weapon:SetRange(8, 10) end inst:AddComponent("explosive") inst.components.explosive:SetOnExplodeFn(OnExplodeFn) inst.components.explosive.explosivedamage = TUNING.GUNPOWDER_DAMAGE inst.components.explosive.explosiverange = 3 return inst end return Prefab("common/inventory/rgd3_nade", fn, assets, prefabs)
×
×
  • Create New...