-
Notifications
You must be signed in to change notification settings - Fork 14
/
demo_wfc_2d_hex_tilemap.tscn
83 lines (72 loc) · 10.4 KB
/
demo_wfc_2d_hex_tilemap.tscn
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
[gd_scene load_steps=9 format=3 uid="uid://bl124iptcoi52"]
[ext_resource type="TileSet" uid="uid://835n3cpedbjf" path="res://addons/wfc/examples/assets/Underearth/Underearth.tres" id="1_nlcwt"]
[ext_resource type="Script" path="res://addons/wfc/nodes/generator_2d.gd" id="2_jfkjw"]
[ext_resource type="Script" path="res://addons/wfc/problems/2d/rules_2d.gd" id="3_5c2jl"]
[ext_resource type="PackedScene" uid="uid://dt2nffs32s7o1" path="res://addons/wfc/examples/helpers/progress_indicator.tscn" id="3_lsnew"]
[ext_resource type="Script" path="res://addons/wfc/solver/solver_settings.gd" id="4_wh6fi"]
[sub_resource type="GDScript" id="GDScript_ud3rp"]
script/source = "extends Node2D
# Called when the node enters the scene tree for the first time.
func _ready():
$sample.hide()
$target.show()
$WFC2DGenerator.start()
"
[sub_resource type="Resource" id="Resource_l2nex"]
script = ExtResource("3_5c2jl")
complete_matrices = true
axes = Array[Vector2i]([Vector2i(0, 1), Vector2i(1, 0), Vector2i(1, -1)])
axis_matrices = Array[Resource("res://addons/wfc/utils/bitmatrix.gd")]([])
probabilities = []
probabilities_enabled = true
edge_condition_meta_name = "wfc_edge"
[sub_resource type="Resource" id="Resource_vyeun"]
script = ExtResource("4_wh6fi")
allow_backtracking = true
require_backtracking = false
backtracking_limit = -1
sparse_history_start = 10
sparse_history_interval = 10
force_ac3 = true
[node name="DemoWfc2dHexTilemap" type="Node2D"]
script = SubResource("GDScript_ud3rp")
[node name="sample" type="TileMap" parent="."]
tile_set = ExtResource("1_nlcwt")
format = 2
layer_0/name = "floor"
layer_0/tile_data = PackedInt32Array(-131072, 0, 0, -1, 0, 0, -196607, 1048576, 0, -196606, 131072, 0, 65534, 1114112, 0, 131070, 65536, 0, 196606, 65536, 0, -196605, 1376256, 0, -131069, 65536, 0, -65533, 1310720, 0, 2, 0, 0, 262142, 1179648, 0, 262143, 131072, 0, 196608, 131072, 0, 196609, 1245184, 0, 65537, 0, 0, 131074, 0, 0, -131071, 0, 1, 65535, 0, 1, -65536, 0, 1, -65535, 0, 1, -131070, 0, 1, -65534, 0, 1, 1, 0, 1, 65536, 0, 1, 131071, 0, 1, 0, 0, 1, 196607, 0, 1, 131073, 0, 1, 65538, 0, 1, 131075, 0, 1, 196610, 0, 1, 262145, 0, 1, 262144, 0, 1, 327679, 0, 1, 327678, 0, 1, 327677, 0, 1, 196605, 0, 1, 262141, 0, 1, 131069, 0, 1, -2, 0, 1, 65533, 0, 1, -65537, 0, 1, -196608, 0, 1, -262143, 0, 1, -262142, 0, 1, -262141, 0, 1, -262140, 0, 1, -196604, 0, 1, -131068, 0, 1, -65532, 0, 1, 3, 0, 1, 65539, 1048576, 0, 65540, 524288, 0, 5, 0, 0, -65530, 589824, 0, 131076, 65536, 0, -131066, 65536, 0, -65529, 131072, 0, -65531, 0, 1, 4, 0, 1, 6, 0, 1, 65541, 0, 1, -131065, 0, 1, 524296, 196608, 0, 458761, 196608, 0, 393226, 917504, 0, 327690, 262144, 0, 262154, 983040, 0, 262153, 327680, 0, 262152, 655360, 0, 327687, 196608, 0, 393222, 196608, 0, 458757, 720896, 0, 524293, 262144, 0, 589829, 262144, 0, 655365, 786432, 0, 655366, 327680, 0, 655367, 327680, 0, 655368, 851968, 0, 589833, 196608, 0, 524298, 655360, 0, 524299, 393216, 0, 393229, 458752, 0, 458764, 196608, 0, 327693, 262144, 0, 589835, 262144, 0, 393230, 327680, 0, 393225, 0, 1, 458760, 0, 1, 458759, 0, 1, 524295, 0, 1, 524294, 0, 1, 589830, 0, 1, 458758, 0, 1, 393223, 0, 1, 327688, 0, 1, 327689, 0, 1, 393224, 0, 1, 589832, 0, 1, 524297, 0, 1, 458762, 0, 1, 393227, 0, 1, 327691, 0, 1, 262155, 0, 1, 196619, 0, 1, 196618, 0, 1, 196617, 0, 1, 196616, 0, 1, 262151, 0, 1, 327686, 0, 1, 393221, 0, 1, 458756, 0, 1, 524292, 0, 1, 589828, 0, 1, 655364, 0, 1, 720900, 0, 1, 720901, 0, 1, 720902, 0, 1, 720903, 0, 1, 720904, 0, 1, 655369, 0, 1, 589834, 0, 1, 655370, 0, 1, 589836, 0, 1, 524300, 0, 1, 458765, 0, 1, 327694, 0, 1, 393228, 0, 1, 458763, 0, 1, 786429, 65536, 1, 720893, 65536, 1, 786428, 65536, 1, 851964, 65536, 1, 851965, 65536, 1, 786430, 65536, 1, 720894, 65536, 1, 655358, 65536, 1, 655357, 65536, 1, 720892, 65536, 1, 786427, 65536, 1, 851963, 65536, 1, 917499, 65536, 1, 917500, 65536, 1, 917501, 65536, 1, 851966, 65536, 1, 786431, 65536, 1, 720895, 65536, 1, 655359, 65536, 1, 589821, 0, 1, 655356, 0, 1, 720891, 0, 1, 786426, 0, 1, 851962, 0, 1, 917498, 0, 1, 983034, 0, 1, 983035, 0, 1, 983036, 0, 1, 983037, 0, 1, 917502, 0, 1, 851967, 0, 1, 720896, 0, 1, 655360, 0, 1, 589824, 0, 1, 524288, 0, 1, 589823, 0, 1, 589822, 0, 1, 917507, 65536, 1, 917506, 65536, 1, 851971, 65536, 1, 851972, 65536, 1, 917508, 65536, 1, 983043, 65536, 1, 983042, 65536, 1, 1048577, 65536, 1, 1114112, 65536, 1, 983044, 65536, 1, 1048580, 65536, 1, 1114116, 65536, 1, 1048581, 65536, 1, 1114117, 65536, 1, 1048582, 65536, 1, 983046, 65536, 1, 983045, 65536, 1, 1114118, 65536, 1, 983047, 65536, 1, 917510, 65536, 1, 1114115, 65536, 1, 1179652, 65536, 1, 1179648, 65536, 1, 1245184, 65536, 1, 1245185, 65536, 1, 1310721, 65536, 1, 1179646, 65536, 1, 1179647, 65536, 1, 1114111, 65536, 1, 1048575, 0, 1, 1114110, 0, 1, 1179645, 0, 1, 1245181, 0, 1, 1245182, 0, 1, 1245183, 0, 1, 1310719, 0, 1, 1376255, 0, 1, 1310720, 0, 1, 1376256, 0, 1, 1376257, 0, 1, 1310722, 0, 1, 1245186, 0, 1, 1179650, 0, 1, 1179649, 0, 1, 1114113, 0, 1, 1048578, 0, 1, 1048579, 0, 1, 1114114, 0, 1, 1179651, 0, 1, 1245187, 0, 1, 1245188, 0, 1, 1179653, 0, 1, 1179654, 0, 1, 1114119, 0, 1, 1048583, 0, 1, 983048, 0, 1, 917512, 0, 1, 917511, 0, 1, 851975, 0, 1, 851974, 0, 1, 917509, 0, 1, 851973, 0, 1, 786437, 0, 1, 786436, 0, 1, 786435, 0, 1, 851970, 0, 1, 917505, 0, 1, 983041, 0, 1, 1048576, 0, 1, 983040, 0, 1, 983056, 65536, 1, 1048591, 65536, 1, 1048590, 65536, 1, 1048589, 65536, 1, 983054, 65536, 1, 983053, 65536, 1, 983057, 65536, 1, 1048593, 65536, 1, 1048592, 65536, 1, 1114128, 65536, 1, 1179664, 65536, 1, 1114127, 65536, 1, 1114126, 65536, 1, 1179662, 65536, 1, 1179663, 65536, 1, 1245198, 65536, 1, 1245197, 65536, 1, 1179661, 65536, 1, 1114125, 65536, 1, 1179660, 65536, 1, 1245196, 65536, 1, 1310732, 65536, 1, 1310733, 65536, 1, 1310734, 65536, 1, 1245200, 65536, 1, 1179665, 65536, 1, 917517, 65536, 1, 917522, 0, 0, 1376268, 0, 0, 1114124, 1245184, 0, 1310731, 1245184, 0, 1179659, 131072, 0, 983055, 1245184, 0, 1114129, 1179648, 0, 1310735, 131072, 0, 1179666, 131072, 0, 851981, 65536, 0, 1048594, 131072, 0, 1245199, 0, 1, 1376269, 0, 1, 1376267, 0, 1, 1245195, 0, 1, 1048588, 0, 1, 983052, 0, 1, 917516, 0, 1, 851982, 0, 1, 917518, 0, 1, 917519, 0, 1, 917521, 0, 1, 917520, 0, 0, 983058, 0, 1, 1114130, 1245184, 0, 1245201, 0, 1, 1310736, 1376256, 0, 1376270, 0, 1)
layer_1/name = "^"
layer_1/tile_data = PackedInt32Array(655359, 65536, 2, 655358, 65536, 2, 655357, 65536, 2, 786431, 65536, 2, 720895, 65536, 2, 851972, 65536, 2, 917510, 65536, 2, 983047, 65536, 2, 983046, 65536, 2, 983044, 65536, 2, 917508, 65536, 2, 851971, 65536, 2, 1179647, 65536, 2, 1114111, 65536, 2, 1179648, 65536, 2, 1245184, 65536, 2, 1245185, 65536, 2, 1310721, 65536, 2, 1114118, 65536, 2, 983057, 458752, 2, 1048593, 65536, 2, 1179664, 65536, 2, 1179665, 65536, 2, 1310734, 65536, 2, 1048590, 65536, 2, 983054, 65536, 2, 983053, 65536, 2, 917517, 65536, 2, 983056, 65536, 2)
layer_2/name = "x\\"
layer_2/tile_data = PackedInt32Array(720895, 131072, 2, 655359, 131072, 2, 786431, 131072, 2, 851966, 131072, 2, 917501, 131072, 2, 851972, 131072, 2, 917508, 131072, 2, 917510, 131072, 2, 983047, 131072, 2, 1048582, 131072, 2, 1114118, 131072, 2, 1179652, 131072, 2, 1310721, 131072, 2, 1245185, 131072, 2, 1179648, 131072, 2, 1114112, 131072, 2, 1048577, 131072, 2, 1114111, 131072, 2, 1048593, 524288, 2, 1179665, 524288, 2, 1310734, 524288, 2, 983054, 524288, 2, 1245200, 131072, 2, 1245198, 131072, 2, 917517, 131072, 2, 983057, 131072, 2, 1114128, 131072, 2)
layer_3/name = "x/"
layer_3/tile_data = PackedInt32Array(917501, 196608, 2, 851966, 196608, 2, 786431, 196608, 2, 917500, 196608, 2, 917499, 196608, 2, 1310721, 196608, 2, 1245184, 196608, 2, 1179647, 196608, 2, 1179646, 196608, 2, 983042, 196608, 2, 983043, 196608, 2, 1114117, 196608, 2, 1114118, 196608, 2, 983047, 196608, 2, 1179652, 196608, 2, 1114115, 196608, 2, 1048577, 196608, 2, 1310732, 196608, 2, 1048593, 589824, 2, 1310734, 196608, 2, 1179663, 196608, 2, 1310733, 196608, 2, 1245200, 196608, 2, 1179665, 196608, 2)
layer_4/name = "v"
layer_4/tile_data = PackedInt32Array(917501, 262144, 2, 917499, 262144, 2, 851963, 262144, 2, 786427, 262144, 2, 917500, 262144, 2, 1114116, 262144, 2, 1179652, 262144, 2, 1114118, 262144, 2, 983044, 262144, 2, 917506, 262144, 2, 1114112, 262144, 2, 1179647, 262144, 2, 1179646, 262144, 2, 1179648, 262144, 2, 1245184, 262144, 2, 1245185, 262144, 2, 1310721, 262144, 2, 1114115, 262144, 2, 983043, 262144, 2, 1310733, 655360, 2, 1048589, 655360, 2, 1179664, 262144, 2, 1245200, 262144, 2, 1310732, 262144, 2, 1245196, 655360, 2, 1179660, 262144, 2, 983053, 262144, 2, 917517, 262144, 2, 1310734, 262144, 2)
layer_5/name = "\\x"
layer_5/tile_data = PackedInt32Array(917499, 327680, 2, 851963, 327680, 2, 786427, 327680, 2, 720892, 327680, 2, 655357, 327680, 2, 1310721, 327680, 2, 1245184, 327680, 2, 1179646, 327680, 2, 1114111, 327680, 2, 917506, 327680, 2, 851971, 327680, 2, 917510, 327680, 2, 1048580, 327680, 2, 1114115, 327680, 2, 1048577, 327680, 2, 983042, 327680, 2, 1179648, 327680, 2, 1179652, 327680, 2, 1179660, 720896, 2, 1245200, 327680, 2, 1245196, 327680, 2, 1114125, 327680, 2, 983053, 327680, 2, 917517, 327680, 2, 983056, 327680, 2, 1310732, 327680, 2, 1048589, 327680, 2)
layer_6/name = "/x"
layer_6/tile_data = PackedInt32Array(786427, 393216, 2, 720892, 393216, 2, 655357, 393216, 2, 655358, 393216, 2, 655359, 393216, 2, 1179646, 393216, 2, 1114111, 393216, 2, 917506, 393216, 2, 851971, 393216, 2, 917510, 393216, 2, 1245185, 393216, 2, 1114112, 393216, 2, 1048577, 393216, 2, 1114115, 393216, 2, 983045, 393216, 2, 851972, 393216, 2, 983047, 393216, 2, 917517, 786432, 2, 1179660, 393216, 2, 1048591, 393216, 2, 983056, 393216, 2, 983057, 393216, 2, 1179665, 393216, 2, 983054, 393216, 2)
[node name="target" type="TileMap" parent="."]
visible = false
position = Vector2(960, 540)
scale = Vector2(0.25, 0.25)
tile_set = ExtResource("1_nlcwt")
format = 2
layer_1/tile_data = PackedInt32Array()
layer_2/tile_data = PackedInt32Array()
layer_3/tile_data = PackedInt32Array()
layer_4/tile_data = PackedInt32Array()
layer_5/tile_data = PackedInt32Array()
layer_6/tile_data = PackedInt32Array()
[node name="WFC2DGenerator" type="Node" parent="."]
script = ExtResource("2_jfkjw")
target = NodePath("../target")
rect = Rect2i(-10, -10, 20, 20)
rules = SubResource("Resource_l2nex")
positive_sample = NodePath("../sample")
solver_settings = SubResource("Resource_vyeun")
render_intermediate_results = true
print_rules = true
[node name="progressIndicator" parent="." node_paths=PackedStringArray("generator") instance=ExtResource("3_lsnew")]
generator = NodePath("../WFC2DGenerator")