游民星空 > 攻略秘籍 > 攻略 > 正文

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

2015-01-21 11:28:46 来源:互联网 作者:易宁 我要投稿

第258页:强迫症标尺

展开

二五八.强迫症标尺(按键盘Insert键在地上画坐标,方便建造、种植,再按Insert键消失)

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

  TheInput:AddKeyUpHandler(KEY_INSERT, function()

  if not inst:HasTag("ruler") then

  inst:AddTag("ruler")

  local pt = inst:GetPosition()

  for y = 10, 0, -1 do

  for x = 0, 10 do

  local coordinate = SpawnPrefab("gridplacer")

  coordinate.AnimState:SetOrientation( ANIM_ORIENTATION.OnGround )

  coordinate.AnimState:SetLayer( LAYER_BACKGROUND )

  coordinate.AnimState:SetSortOrder( 1 )

  coordinate.Transform:SetRotation( 45 )

  coordinate.Transform:SetPosition(pt.x-14.1+x*2.82, 0, pt.z-14.1+y*2.82)

  local light = coordinate.entity:AddLight()

  light:SetIntensity(.6)

  light:SetRadius(.5)

  light:SetFalloff(.6)

  light:Enable(true)

  light:SetColour(180/255, 195/255, 225/255)

  coordinate:AddTag("NOCLICK")

  coordinate:AddTag("coordinate")

  end

  end

  else

  inst:RemoveTag("ruler")

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

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

  for k,v in pairs(ents) do

  if v:HasTag("coordinate") then

  v:Remove()

  end

  end

  end

  end )

  即可按键盘Insert键,以主角为中心在地上画出白色坐标,可作为建造或种植的参照线,也可测量你现有的建筑、植物是不是歪了,强迫症必备,还有夜光效果哦,再按一次Insert键坐标消失

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

责任编辑:Shy夏夏

上一页 251 252 253 254 255 256 257 258 259 260 261 下一页
友情提示:支持键盘左右键“← →”翻页

本文是否解决了您的问题

文章内容导航
游民星空APP
随手浏览游戏攻略
code
攻略合集
单机游戏下载
休闲娱乐
综合热点资讯
游民星空联运游戏