Use generated textures for scroll ornaments
This commit is contained in:
@@ -3653,9 +3653,11 @@ func _check_ancient_ui_theme(failures: Array[String]) -> void:
|
||||
if not scene._format_defeat_result_text().contains("패배"):
|
||||
failures.append("defeat result should use Korean title")
|
||||
var scroll_rod := scene._make_scroll_rod(120, 4)
|
||||
if scroll_rod.get_child_count() != 5:
|
||||
failures.append("scroll rod ornament should use five visual strips")
|
||||
_check_scroll_rod(failures, scroll_rod, "generated scroll rod")
|
||||
scroll_rod.free()
|
||||
var tablet_binding := scene._make_tablet_binding(120, 16)
|
||||
_check_tablet_binding(failures, tablet_binding, "generated tablet binding")
|
||||
tablet_binding.free()
|
||||
var seal_ribbon := scene._make_seal_ribbon(120, 18)
|
||||
_check_seal_ribbon(failures, seal_ribbon, "generated seal ribbon")
|
||||
seal_ribbon.free()
|
||||
@@ -3668,6 +3670,36 @@ func _check_ancient_ui_theme(failures: Array[String]) -> void:
|
||||
scene.free()
|
||||
|
||||
|
||||
func _check_scroll_rod(failures: Array[String], scroll_rod: HBoxContainer, label: String) -> void:
|
||||
if scroll_rod == null:
|
||||
failures.append("%s missing" % label)
|
||||
return
|
||||
if scroll_rod.get_child_count() != 5:
|
||||
failures.append("%s should use five visual strips" % label)
|
||||
return
|
||||
for index in range(scroll_rod.get_child_count()):
|
||||
_check_panel_uses_generated_ornament_texture(failures, scroll_rod.get_child(index) as PanelContainer, "%s segment %d" % [label, index])
|
||||
|
||||
|
||||
func _check_tablet_binding(failures: Array[String], binding: HBoxContainer, label: String) -> void:
|
||||
if binding == null:
|
||||
failures.append("%s missing" % label)
|
||||
return
|
||||
if binding.get_child_count() != 7:
|
||||
failures.append("%s should use seven clasp/strip/knot segments" % label)
|
||||
return
|
||||
for index in range(binding.get_child_count()):
|
||||
if index == 3:
|
||||
var knot := binding.get_child(index) as HBoxContainer
|
||||
if knot == null or knot.get_child_count() != 2:
|
||||
failures.append("%s should include a two-seal center knot" % label)
|
||||
continue
|
||||
for knot_index in range(knot.get_child_count()):
|
||||
_check_panel_uses_generated_ornament_texture(failures, knot.get_child(knot_index) as PanelContainer, "%s knot seal %d" % [label, knot_index])
|
||||
continue
|
||||
_check_panel_uses_generated_ornament_texture(failures, binding.get_child(index) as PanelContainer, "%s segment %d" % [label, index])
|
||||
|
||||
|
||||
func _check_seal_ribbon(failures: Array[String], ribbon: HBoxContainer, label: String) -> void:
|
||||
if ribbon == null:
|
||||
failures.append("%s missing" % label)
|
||||
|
||||
Reference in New Issue
Block a user