UV Mapping for Destructable Walls

This commit is contained in:
Relicjamin
2026-01-03 13:06:22 -05:00
committed by Collin Campbell
parent 933bd98a4f
commit 5a1c02aa15
70 changed files with 1762 additions and 1305 deletions

View File

@@ -0,0 +1,14 @@
extends Resource
class_name Face
var vectors: PackedVector3Array
var uvs: PackedVector2Array
var normal: Vector3
func _init(vectors: PackedVector3Array, uvs: PackedVector2Array, normal: Vector3):
assert(len(vectors) % 3 == 0, "not a face")
assert(len(uvs) == len(vectors), "missing uvs for vectors")
self.vectors = vectors.duplicate()
self.uvs = uvs.duplicate()
self.normal = normal