Jump to content

Recommended Posts

I've almost got this working. but something keeps breaking..  The hud Does disappear and reappear as I expect it to, but a few seconds after editing the hud the game crashes, claiming "attempt to index field 'HUD' (a nil value) LUA ERROR stack traceback:".  I found another post on the forums that has a different solution, but I can't seem to get that one working, it claims "variable 'GLOBAL' is not declared LUA ERROR stack traceback:".
Any suggestions?

--if inst.HUD ~= nil then  --Test code.
    --if inst.HUD.controls.crafttabs ~= nil then
        inst.HUD.controls.crafttabs:Hide()
    --end
--end

inst.HUD.controls.crafttabs:Show()

 

 

Edit:  I'm not sure what changed, but the code works today.

if inst.HUD ~= nil then  --Test code.
	if inst.HUD.controls.crafttabs ~= nil then
		inst.HUD.controls.crafttabs:Hide()
	end
end

if inst.HUD ~= nil then  --Test code.
	if inst.HUD.controls.crafttabs ~= nil then
		inst.HUD.controls.crafttabs:Show()
	end
end

 

Edited by FurryEskimo
  • GL Happy 1
Link to comment
https://forums.kleientertainment.com/forums/topic/126775-hiding-the-crafting-hud/
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...