Sly 25.10.: „weich“ soll ein Textur-Verlauf am Pinselrand sein, nicht fleckig; gerade Strichkanten wirkten weiter hart (1-m-Übergang). - Format (optional, alte Karten gültig): materials_b_r8_b64 (zweites Material je Punkt) + materials_w_r8_b64 (Anteil 0–255); ohne Mischung fallen die Felder weg. V15 prüft Länge/IDs/Paarigkeit. - TerrainField.apply_material_brush_mix: innen voll, außen Smoothstep-Anteil; nur verstärken, nie abschwächen; Gras drübermalen mischt zurück. - Shader: Top-2 aus 4 Nachbarpunkten × (a, b) mit Anteilen → nur noch 2 Albedo-Fetches; Warp bleibt. - Pinsel/Live-Vorschau, Spiegeln, Symmetrie-Analyse/-Anwenden, Resize, Anheben, Undo (terrain-Snapshot) tragen die Misch-Schicht mit. - Streu-Rand (vorheriger Commit) entfernt. - Tests: test_mal_fein 30/30 (Verlauf fällt weich, nie abschwächen, zurückmischen, Kodierung), Editor-Suite unverändert grün bis auf die bekannten Umgebungs-Tests; Kette Editor → Server → Client per run_map_download_e2e 15/15 mit gemischter Karte. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
24 lines
1.1 KiB
GDScript
24 lines
1.1 KiB
GDScript
extends SceneTree
|
|
## Probe (Karte 24.10.): alte Karte öffnen → feines Raster → 1-m-Sandpfad malen
|
|
## → speichern. Ausgabe-Pfad = erstes User-Arg. Für die Client-E2E-Kette.
|
|
func _initialize() -> void:
|
|
var out := OS.get_cmdline_user_args()[0]
|
|
var ld := SvmapIO.load_from_file(ProjectSettings.globalize_path("res://FirstFight.svmap"))
|
|
if not bool(ld["ok"]):
|
|
print("PROBE_FAIL load ", ld["errors"])
|
|
quit(1)
|
|
return
|
|
var doc: Dictionary = ld["data"]
|
|
var t: Dictionary = doc["terrain"]
|
|
SvmapIO.upgrade_material_layer(t)
|
|
var mres := SvmapIO.material_resolution(t)
|
|
var mats := SvmapIO.decode_materials(t)
|
|
var mix := SvmapIO.decode_mix(t)
|
|
for i in 40: # weicher Fels-Pfad (Misch-Schicht, Karte 25.10.)
|
|
TerrainField.apply_material_brush_mix(mats, mix[0], mix[1], mres, float(t["size_x_m"]),
|
|
float(t["size_z_m"]), -20.0 + float(i), 5.0, 3.0, 2, 0.8)
|
|
t["materials_r8_b64"] = SvmapIO.encode_materials(mats)
|
|
SvmapIO.encode_mix(t, mix[0], mix[1])
|
|
var sv := SvmapIO.save_to_file(out, doc)
|
|
print("PROBE ", "OK" if bool(sv["ok"]) else "FAIL %s" % str(sv["errors"]), " mres=", mres)
|
|
quit(0 if bool(sv["ok"]) else 1)
|