feat: Add right hand/foot editor options, Flintstones Water Buffalo Lodge hat, hide controls in world editor, and easy main menu sound toggle
checkpoint / checkpoint (push) Successful in 6m19s

This commit is contained in:
2026-09-20 11:40:41 +00:00
parent 034a6901a9
commit 62fa0b0067
18 changed files with 601 additions and 20 deletions
+113
View File
@@ -96,8 +96,12 @@ const ATTACHMENTS := {
"pants_cargo_01": ["hips", Vector3(0, -0.04, 0.0), Color(0.30, 0.35, 0.45)],
"left_hand_glove_01": ["blob", Vector3(0, 0.0, 0.0), Color(0.15, 0.15, 0.18)],
"right_hand_glove_01": ["blob", Vector3(0, 0.0, 0.0), Color(0.15, 0.15, 0.18)],
"left_hand_wristband_01": ["band", Vector3(0, 0.02, 0.0), Color(0.95, 0.80, 0.15)],
"right_hand_wristband_01": ["band", Vector3(0, 0.02, 0.0), Color(0.95, 0.80, 0.15)],
"left_foot_boot_01": ["boot", Vector3(0, -0.02, -0.05), Color(0.12, 0.10, 0.09)],
"right_foot_boot_01": ["boot", Vector3(0, -0.02, -0.05), Color(0.12, 0.10, 0.09)],
"left_foot_sneaker_01": ["sneaker", Vector3(0, -0.02, -0.05), Color(0.85, 0.25, 0.25)],
"right_foot_sneaker_01": ["sneaker", Vector3(0, -0.02, -0.05), Color(0.85, 0.25, 0.25)],
"accessory_belt_01": ["belt", Vector3(0, 0.74, 0.0), Color(0.20, 0.18, 0.12)],
"accessory_necklace_01": ["necklace", Vector3(0, 1.34, -0.10), Color(0.85, 0.75, 0.20)],
}
@@ -114,6 +118,8 @@ func _initialize() -> void:
var spec: Array = ATTACHMENTS[id]
_gen_attachment(id, spec[0], spec[1], spec[2])
_gen_water_buffalo_hat()
print("\n%s" % ("DONE — all placeholder avatar GLBs written" if _fail == 0
else "FAILED (%d errors)" % _fail))
quit(_fail)
@@ -282,6 +288,10 @@ func _attachment_mesh(kind: String) -> Mesh:
var m := BoxMesh.new(); m.size = Vector3(0.30, 0.24, 0.34); return m
"boot":
var m := BoxMesh.new(); m.size = Vector3(0.34, 0.16, 0.42); return m
"sneaker":
var m := BoxMesh.new(); m.size = Vector3(0.32, 0.14, 0.40); return m
"band":
var m := TorusMesh.new(); m.inner_radius = 0.10; m.outer_radius = 0.16; return m
"belt":
var m := TorusMesh.new(); m.inner_radius = 0.22; m.outer_radius = 0.30; return m
"necklace":
@@ -290,6 +300,109 @@ func _attachment_mesh(kind: String) -> Mesh:
return BoxMesh.new()
func _gen_water_buffalo_hat() -> void:
var root := Node3D.new()
root.name = "AttachmentRoot"
# 1. Hat Cap (royal blue felt lodge hat, sitting on head crown)
var cap := MeshInstance3D.new()
cap.name = "HatCap"
var cap_mesh := CylinderMesh.new()
cap_mesh.top_radius = 0.28
cap_mesh.bottom_radius = 0.32
cap_mesh.height = 0.26
cap.mesh = cap_mesh
cap.position = Vector3(0.0, 0.12, 0.0)
var cap_mat := StandardMaterial3D.new()
cap_mat.albedo_color = Color(0.13, 0.20, 0.58) # Flintstones Water Buffalo blue
cap_mat.roughness = 0.95
cap.material_override = cap_mat
root.add_child(cap)
# 2. Fur Brim / Rim at bottom edge of cap
var brim := MeshInstance3D.new()
brim.name = "FurBrim"
var brim_mesh := TorusMesh.new()
brim_mesh.inner_radius = 0.28
brim_mesh.outer_radius = 0.36
brim.mesh = brim_mesh
brim.position = Vector3(0.0, 0.01, 0.0)
var brim_mat := StandardMaterial3D.new()
brim_mat.albedo_color = Color(0.24, 0.18, 0.13) # Fur trim
brim_mat.roughness = 1.0
brim.material_override = brim_mat
root.add_child(brim)
# 3. Lodge Gold Medallion on front (-Z is forward)
var medal := MeshInstance3D.new()
medal.name = "LodgeBadge"
var medal_mesh := BoxMesh.new()
medal_mesh.size = Vector3(0.12, 0.10, 0.04)
medal.mesh = medal_mesh
medal.position = Vector3(0.0, 0.12, -0.32)
var medal_mat := StandardMaterial3D.new()
medal_mat.albedo_color = Color(0.96, 0.82, 0.18) # Gold lodge crest
medal_mat.metallic = 0.7
medal_mat.roughness = 0.3
medal.material_override = medal_mat
root.add_child(medal)
# Horn material: ivory/bone
var horn_mat := StandardMaterial3D.new()
horn_mat.albedo_color = Color(0.92, 0.89, 0.82) # Bone/ivory
horn_mat.roughness = 0.5
var tip_mat := StandardMaterial3D.new()
tip_mat.albedo_color = Color(0.20, 0.17, 0.14) # Dark horn tip
tip_mat.roughness = 0.6
# 4. Sweeping Curved Water Buffalo Horns (curving outward and up)
for side in [-1.0, 1.0]:
var side_name := "Right" if side < 0.0 else "Left"
# Base segment (projecting horizontally outwards from side of hat)
var h_base := MeshInstance3D.new()
h_base.name = "Horn_%s_Base" % side_name
var base_mesh := CylinderMesh.new()
base_mesh.bottom_radius = 0.08
base_mesh.top_radius = 0.065
base_mesh.height = 0.20
h_base.mesh = base_mesh
h_base.position = Vector3(side * 0.36, 0.12, 0.02)
h_base.rotation_degrees = Vector3(10.0, side * -15.0, side * -70.0)
h_base.material_override = horn_mat
root.add_child(h_base)
# Mid segment (sweeping upward and outward)
var h_mid := MeshInstance3D.new()
h_mid.name = "Horn_%s_Mid" % side_name
var mid_mesh := CylinderMesh.new()
mid_mesh.bottom_radius = 0.065
mid_mesh.top_radius = 0.045
mid_mesh.height = 0.22
h_mid.mesh = mid_mesh
h_mid.position = Vector3(side * 0.52, 0.24, 0.0)
h_mid.rotation_degrees = Vector3(15.0, side * -10.0, side * -25.0)
h_mid.material_override = horn_mat
root.add_child(h_mid)
# Tip segment (curving upward and inward to sharp tip)
var h_tip := MeshInstance3D.new()
h_tip.name = "Horn_%s_Tip" % side_name
var tip_mesh := CylinderMesh.new()
tip_mesh.bottom_radius = 0.045
tip_mesh.top_radius = 0.005
tip_mesh.height = 0.18
h_tip.mesh = tip_mesh
h_tip.position = Vector3(side * 0.56, 0.40, -0.04)
h_tip.rotation_degrees = Vector3(20.0, 0.0, side * 20.0)
h_tip.material_override = tip_mat
root.add_child(h_tip)
_write_glb(root, "hair_waterbuffalo_01")
root.free()
# ---------------------------------------------------------------------------
# GLB export
# ---------------------------------------------------------------------------