initial shit

This commit is contained in:
2026-06-04 16:53:41 -05:00
parent f019615187
commit d3779cff20
828 changed files with 512567 additions and 0 deletions

View File

@@ -0,0 +1,31 @@
extends Node3D
## define all of the game variables, ill replace this with a settings file later
## ignore duplicate keys, idrc atp
## this game is jus a mess of spaghetti anyhow
var selectedBlockID : String = "base:testMachine"
var selectedSlot = 0
var currentHeldItemID : String = "base:air"
var canPlaceBlock : bool = false
var username = "Xtimhedi"
var loadedLanguage = "en-US"
var isInputLocked = false
signal hideChatbox
func getIfIDExists(ID:String) -> bool:
var segments = ID.split(":")
return ResourceLoader.exists("res://WorldObjects/{namespace}/{id}.tscn".format({"namespace": segments[0], "id": segments[1]}))
func _process(delta: float) -> void:
if currentHeldItemID != "base:air" and getIfIDExists(currentHeldItemID):
canPlaceBlock = true
selectedBlockID = currentHeldItemID
else:
canPlaceBlock = false
selectedBlockID = "base:air"