饥荒 全人物解锁及主角自动回血等实用修改教程

《饥荒》这款生存游戏,很多玩家都想觉得游戏有些难,就想修改一些内容,比如解锁全人物,主角自动回血,主角不会饿之类的,下面小编为大家奉上最全的修改教程,内容简单易懂,希望各位玩家喜欢。目录

饥荒 全人物解锁及主角自动回血等实用修改教程

一八四.家园防御系统(暗夜照明灯自动向靠近的敌人发射炮弹)

  用记事本打开游戏目录\data\DLC0001\scripts\prefabs\nightlight.lua文件,在inst:AddComponent("inspectable")的下一行插入以下内容:

  local function onattack(inst)

  local pos = Vector3(inst.Transform:GetWorldPosition())

  local ents = TheSim:FindEntities(pos.x,pos.y,pos.z, 30)

  for k,v in pairs(ents) do

  if v.components.health and v.components.combat and not v.components.health:IsDead() then

  if v.components.combat.target == GetPlayer() or GetPlayer().components.combat.target == v or v:HasTag("monster") then

  inst.components.weapon:LaunchProjectile(inst, v)

  v.components.health:DoDelta(-5000)

  inst.SoundEmitter:PlaySound("dontstarve/creatures/eyeballturret/shotexplo")

  SpawnPrefab("collapse_small").Transform:SetPosition(v.Transform:GetWorldPosition())

  SpawnPrefab("explode_small").Transform:SetPosition(v.Transform:GetWorldPosition())

  GetPlayer().components.playercontroller:ShakeCamera(inst, "FULL", 0.7, 0.02, .5, 40)

  inst.components.fueled:InitializeFuelLevel(1000)

  end

  end

  end

  end

  local function turnon(inst)

  inst.components.machine.ison = true

  inst.task = inst:DoPeriodicTask(.5, function() onattack(inst) end)

  inst.components.burnable:IsBurning()

  inst.components.fueled:InitializeFuelLevel(1000)

  end

  local function turnoff(inst)

  inst.components.machine.ison = false

  if inst.task then inst.task:Cancel() inst.task = nil end

  inst.components.burnable:Extinguish()

  inst.components.fueled:InitializeFuelLevel(0)

  end

  inst:AddComponent("machine")

  inst.components.machine.turnonfn = turnon

  inst.components.machine.turnofffn = turnoff

  inst:AddComponent("weapon")

  inst.components.weapon:SetDamage(0)

  inst.components.weapon:SetProjectile("eye_charge")

  即可对暗夜照明灯按鼠标右键开启家园防御系统,自动向靠近的敌人发射炮弹(不会攻击同伴),再按鼠标右键关闭。建在基地附近,无惧任何敌人。暗影照明灯在魔法选项(画着红骷髅)下,用8个黄金、2个噩梦燃料、1个红宝石建造

相关内容请关注:饥荒专区

作者:易宁     责任编辑:Shy夏夏

本文是否解决了您的问题

APP精彩推荐打开游民APP查看更多

  • 三上悠亚老师再发新图:超短牛仔裙大白腿看流口水
    三上悠亚老师再发新图:超短牛仔裙大白腿看流口水

  • 捞女游戏遭豆瓣下架!开分8.5现在搜不到了
    捞女游戏遭豆瓣下架!开分8.5现在搜不到了

  • 网传霍金和比基尼女子合影 家人回应:护理人员
    网传霍金和比基尼女子合影 家人回应:护理人员

攻略合集
人物图鉴

相关内容

在线玩推荐更多

游民星空

打开App阅读体验更佳,攻略、资讯实时更新

下载APP