Roblox-style blocky avatar + actually-visible build stamp
checkpoint / checkpoint (push) Successful in 1m52s
checkpoint / checkpoint (push) Successful in 1m52s
Avatar: rebuild the placeholder base body as a Roblox-classic (R6) figure -- six chunky solid box parts (head, torso, two arms, two legs) skinned one part per bone onto the same 24-bone canonical rig, arms hanging at the sides instead of a T-pose, plus a painted-on smile face. Classic yellow/blue/green "noob" palette, flat single-colour surfaces (the old capsule-segment chain read as a banded scarecrow). Attachments resized to match the new proportions; head/hair/glove primitives are now boxes too (dropped ~130KB spheres to ~3KB each). Build stamp: it never rendered because `set_anchors_and_offsets_preset()` plus `.position` on a zero-size Label collapses the rect to negative width. Switched to a bottom-anchored full-width strip with explicit offsets and text alignment, brighter colour + black outline. Shows on the main menu (bottom-right) and in-world HUD (bottom-left) as `build PC3 <commit>`. Verified: avatar smoke 14/14 from source and against the exported pack; game.tscn + main_menu.tscn boot headless with no script errors. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015jtxAiu5dAW4WxCNdGkrkJ
This commit is contained in:
+16
-4
@@ -46,13 +46,25 @@ static func _build_label() -> String:
|
||||
|
||||
func _show_build_stamp() -> void:
|
||||
var layer := CanvasLayer.new()
|
||||
layer.layer = 128
|
||||
add_child(layer)
|
||||
var lbl := Label.new()
|
||||
lbl.text = "build %s" % _build_label()
|
||||
lbl.add_theme_color_override("font_color", Color(1, 1, 1, 0.5))
|
||||
lbl.add_theme_font_size_override("font_size", 13)
|
||||
lbl.set_anchors_and_offsets_preset(Control.PRESET_BOTTOM_LEFT)
|
||||
lbl.position = Vector2(8, -22)
|
||||
lbl.add_theme_color_override("font_color", Color(1, 1, 0.45))
|
||||
lbl.add_theme_color_override("font_outline_color", Color(0, 0, 0, 0.85))
|
||||
lbl.add_theme_constant_override("outline_size", 4)
|
||||
lbl.add_theme_font_size_override("font_size", 14)
|
||||
# Anchor a full-width strip to the bottom of the screen and left-align the
|
||||
# text in it. (A bare preset + .position on a zero-size Label collapses the
|
||||
# rect to negative width and nothing draws -- which is why this never showed.)
|
||||
lbl.set_anchors_preset(Control.PRESET_BOTTOM_WIDE)
|
||||
lbl.horizontal_alignment = HORIZONTAL_ALIGNMENT_LEFT
|
||||
lbl.vertical_alignment = VERTICAL_ALIGNMENT_BOTTOM
|
||||
lbl.offset_left = 8
|
||||
lbl.offset_right = -8
|
||||
lbl.offset_top = -30
|
||||
lbl.offset_bottom = -6
|
||||
lbl.mouse_filter = Control.MOUSE_FILTER_IGNORE
|
||||
layer.add_child(lbl)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user