YN010-主角不怕火、无惧黑暗
代码来源于“易宁”大佬的分享,仅供学习,不要直接复制粘贴。 原帖链接:http://bbs.3dmgame.com/thread-3859071-1-1.html 1 2十.主角不怕火、无惧黑暗 3 4 用MT管理器打开游戏目录/assets/DLC0002/scripts/prefabs/player_common.lua文件,将下列内容: 5 6 inst:AddComponent("grue") 7 inst.components.grue:SetSounds("dontstarve/charlie/warn","dontstarve/charlie/attack") 8 9 替换为: 10 11 --inst:AddComponent("grue") 12 --inst.components.grue:SetSounds("dontstarve/charlie/warn","dontstarve/charlie/attack") 13 inst.components.health.fire_damage_scale = 0 14 15 即可让主角不怕火、无惧黑暗