Loading model...
by adamtyplays adam · 5/9/2026
Lua Script
| 1 | -- Generated with StudForge.org | AI-powered 3D models for Roblox |
| 2 | -- Model: ChocolateSmashRunMap |
| 3 | |
| 4 | local MS = game:GetService("MaterialService") |
| 5 | |
| 6 | local ok, roots = pcall(game.GetObjects, game, "rbxassetid://13386676607") |
| 7 | if not ok then return warn(roots) end |
| 8 | |
| 9 | local tmp = Instance.new("Folder") |
| 10 | for _, r in ipairs(roots) do r.Parent = tmp end |
| 11 | |
| 12 | for _, d in ipairs(tmp:GetDescendants()) do |
| 13 | if d:IsA("MaterialVariant") then |
| 14 | d.Parent = MS |
| 15 | end |
| 16 | end |
| 17 | tmp:Destroy() |
| 18 | |
| 19 | local model = Instance.new("Model") |
| 20 | model.Name = "ChocolateSmashRunMap" |
| 21 | model.Parent = workspace |
| 22 | |
| 23 | local variants = { |
| 24 | ["Bright red"] = "2022 Stud", |
| 25 | ["Bright yellow"] = "2022 Stud", |
| 26 | ["Dark taupe"] = "2022 Stud", |
| 27 | ["Gold"] = "2022 Stud", |
| 28 | ["Medium brown"] = "2022 Stud", |
| 29 | ["Moss"] = "2022 Small Stud", |
| 30 | ["Nougat"] = "2022 Small Stud", |
| 31 | ["Pine Cone"] = "2022 Small Stud", |
| 32 | ["Really black"] = "2022 Universal", |
| 33 | ["Sand green"] = "2022 Stud", |
| 34 | ["White"] = "2022 Stud", |
| 35 | } |
| 36 | do |
| 37 | local p = Instance.new("Part") |
| 38 | p.Name = "Z1_Path" |
| 39 | p.Size = Vector3.new(4, 1, 10) |
| 40 | p.CFrame = CFrame.new(0, 0.5, 15.12) |
| 41 | p.BrickColor = BrickColor.new("Medium brown") |
| 42 | p.Material = Enum.Material.Glacier |
| 43 | p.MaterialVariant = "2022 Stud" |
| 44 | p.Anchored = true |
| 45 | p.Parent = model |
| 46 | end |
| 47 | do |
| 48 | local p = Instance.new("Part") |
| 49 | p.Name = "Z1_SideL" |
| 50 | p.Size = Vector3.new(3, 1, 10) |
| 51 | p.CFrame = CFrame.new(-3.58, 0.5, 15) |
| 52 | p.BrickColor = BrickColor.new("Nougat") |
| 53 | p.Material = Enum.Material.Glacier |
| 54 | p.MaterialVariant = "2022 Small Stud" |
| 55 | p.Anchored = true |
| 56 | p.Parent = model |
| 57 | end |
| 58 | do |
| 59 | local p = Instance.new("Part") |
| 60 | p.Name = "Z1_SideR" |
| 61 | p.Size = Vector3.new(3, 1, 10) |
| 62 | p.CFrame = CFrame.new(3.58, 0.5, 15) |
| 63 | p.BrickColor = BrickColor.new("Nougat") |
| 64 | p.Material = Enum.Material.Glacier |
| 65 | p.MaterialVariant = "2022 Small Stud" |
| 66 | p.Anchored = true |
| 67 | p.Parent = model |
| 68 | end |
| 69 | do |
| 70 | local p = Instance.new("Part") |
| 71 | p.Name = "Z1_Wall_-1" |
| 72 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 73 | p.CFrame = CFrame.new(-1, 1.5, 15) |
| 74 | p.BrickColor = BrickColor.new("Medium brown") |
| 75 | p.Material = Enum.Material.Glacier |
| 76 | p.MaterialVariant = "2022 Stud" |
| 77 | p.Anchored = true |
| 78 | p.Parent = model |
| 79 | end |
| 80 | do |
| 81 | local p = Instance.new("Part") |
| 82 | p.Name = "Z1_Wall_0" |
| 83 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 84 | p.CFrame = CFrame.new(0, 1.5, 15) |
| 85 | p.BrickColor = BrickColor.new("Medium brown") |
| 86 | p.Material = Enum.Material.Glacier |
| 87 | p.MaterialVariant = "2022 Stud" |
| 88 | p.Anchored = true |
| 89 | p.Parent = model |
| 90 | end |
| 91 | do |
| 92 | local p = Instance.new("Part") |
| 93 | p.Name = "Z1_Wall_1" |
| 94 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 95 | p.CFrame = CFrame.new(1, 1.5, 15) |
| 96 | p.BrickColor = BrickColor.new("Medium brown") |
| 97 | p.Material = Enum.Material.Glacier |
| 98 | p.MaterialVariant = "2022 Stud" |
| 99 | p.Anchored = true |
| 100 | p.Parent = model |
| 101 | end |
| 102 | do |
| 103 | local p = Instance.new("Part") |
| 104 | p.Name = "Z1_BldgL" |
| 105 | p.Size = Vector3.new(2, 2, 2) |
| 106 | p.CFrame = CFrame.new(-3.5, 2.08, 15) |
| 107 | p.BrickColor = BrickColor.new("Medium brown") |
| 108 | p.Material = Enum.Material.Glacier |
| 109 | p.MaterialVariant = "2022 Stud" |
| 110 | p.Anchored = true |
| 111 | p.Parent = model |
| 112 | end |
| 113 | do |
| 114 | local p = Instance.new("Part") |
| 115 | p.Name = "Z1_BldgR" |
| 116 | p.Size = Vector3.new(2, 2, 2) |
| 117 | p.CFrame = CFrame.new(3.5, 2.08, 15) |
| 118 | p.BrickColor = BrickColor.new("Medium brown") |
| 119 | p.Material = Enum.Material.Glacier |
| 120 | p.MaterialVariant = "2022 Stud" |
| 121 | p.Anchored = true |
| 122 | p.Parent = model |
| 123 | end |
| 124 | do |
| 125 | local p = Instance.new("Part") |
| 126 | p.Shape = Enum.PartType.Ball |
| 127 | p.Name = "Z1_Drop1" |
| 128 | p.Size = Vector3.new(0.6, 0.6, 0.6) |
| 129 | p.CFrame = CFrame.new(-2.5, 1.3, 13) |
| 130 | p.BrickColor = BrickColor.new("Bright red") |
| 131 | p.Material = Enum.Material.Glacier |
| 132 | p.MaterialVariant = "2022 Stud" |
| 133 | p.Anchored = true |
| 134 | p.Parent = model |
| 135 | end |
| 136 | do |
| 137 | local p = Instance.new("Part") |
| 138 | p.Shape = Enum.PartType.Ball |
| 139 | p.Name = "Z1_Drop2" |
| 140 | p.Size = Vector3.new(0.6, 0.6, 0.6) |
| 141 | p.CFrame = CFrame.new(2.5, 1.3, 17) |
| 142 | p.BrickColor = BrickColor.new("White") |
| 143 | p.Material = Enum.Material.Glacier |
| 144 | p.MaterialVariant = "2022 Stud" |
| 145 | p.Anchored = true |
| 146 | p.Parent = model |
| 147 | end |
| 148 | do |
| 149 | local p = Instance.new("Part") |
| 150 | p.Shape = Enum.PartType.Cylinder |
| 151 | p.Name = "Z1_Coin" |
| 152 | p.Size = Vector3.new(0.2, 0.8, 0.8) |
| 153 | p.CFrame = CFrame.new(0, 2.5, 18) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)) |
| 154 | p.BrickColor = BrickColor.new("Bright yellow") |
| 155 | p.Material = Enum.Material.Glacier |
| 156 | p.MaterialVariant = "2022 Stud" |
| 157 | p.Anchored = true |
| 158 | p.Parent = model |
| 159 | end |
| 160 | do |
| 161 | local p = Instance.new("Part") |
| 162 | p.Name = "Z2_Path" |
| 163 | p.Size = Vector3.new(4, 1, 10) |
| 164 | p.CFrame = CFrame.new(0, 0.5, 5.08) |
| 165 | p.BrickColor = BrickColor.new("Dark taupe") |
| 166 | p.Material = Enum.Material.Glacier |
| 167 | p.MaterialVariant = "2022 Stud" |
| 168 | p.Anchored = true |
| 169 | p.Parent = model |
| 170 | end |
| 171 | do |
| 172 | local p = Instance.new("Part") |
| 173 | p.Name = "Z2_RiverL" |
| 174 | p.Size = Vector3.new(3, 0.6, 10) |
| 175 | p.CFrame = CFrame.new(-3.5, 0.22, 4.92) |
| 176 | p.BrickColor = BrickColor.new("Pine Cone") |
| 177 | p.Material = Enum.Material.Glacier |
| 178 | p.MaterialVariant = "2022 Small Stud" |
| 179 | p.Anchored = true |
| 180 | p.Parent = model |
| 181 | end |
| 182 | do |
| 183 | local p = Instance.new("Part") |
| 184 | p.Name = "Z2_RiverR" |
| 185 | p.Size = Vector3.new(3, 0.6, 10) |
| 186 | p.CFrame = CFrame.new(3.5, 0.22, 4.92) |
| 187 | p.BrickColor = BrickColor.new("Pine Cone") |
| 188 | p.Material = Enum.Material.Glacier |
| 189 | p.MaterialVariant = "2022 Small Stud" |
| 190 | p.Anchored = true |
| 191 | p.Parent = model |
| 192 | end |
| 193 | do |
| 194 | local p = Instance.new("Part") |
| 195 | p.Name = "Z2_Wall_-1_1.5" |
| 196 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 197 | p.CFrame = CFrame.new(-1, 1.5, 5) |
| 198 | p.BrickColor = BrickColor.new("Dark taupe") |
| 199 | p.Material = Enum.Material.Glacier |
| 200 | p.MaterialVariant = "2022 Stud" |
| 201 | p.Anchored = true |
| 202 | p.Parent = model |
| 203 | end |
| 204 | do |
| 205 | local p = Instance.new("Part") |
| 206 | p.Name = "Z2_Wall_-1_2.5" |
| 207 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 208 | p.CFrame = CFrame.new(-1, 2.5, 5) |
| 209 | p.BrickColor = BrickColor.new("Dark taupe") |
| 210 | p.Material = Enum.Material.Glacier |
| 211 | p.MaterialVariant = "2022 Stud" |
| 212 | p.Anchored = true |
| 213 | p.Parent = model |
| 214 | end |
| 215 | do |
| 216 | local p = Instance.new("Part") |
| 217 | p.Name = "Z2_Wall_0_1.5" |
| 218 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 219 | p.CFrame = CFrame.new(0, 1.5, 5) |
| 220 | p.BrickColor = BrickColor.new("Dark taupe") |
| 221 | p.Material = Enum.Material.Glacier |
| 222 | p.MaterialVariant = "2022 Stud" |
| 223 | p.Anchored = true |
| 224 | p.Parent = model |
| 225 | end |
| 226 | do |
| 227 | local p = Instance.new("Part") |
| 228 | p.Name = "Z2_Wall_0_2.5" |
| 229 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 230 | p.CFrame = CFrame.new(0, 2.5, 5) |
| 231 | p.BrickColor = BrickColor.new("Dark taupe") |
| 232 | p.Material = Enum.Material.Glacier |
| 233 | p.MaterialVariant = "2022 Stud" |
| 234 | p.Anchored = true |
| 235 | p.Parent = model |
| 236 | end |
| 237 | do |
| 238 | local p = Instance.new("Part") |
| 239 | p.Name = "Z2_Wall_1_1.5" |
| 240 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 241 | p.CFrame = CFrame.new(1, 1.5, 5) |
| 242 | p.BrickColor = BrickColor.new("Dark taupe") |
| 243 | p.Material = Enum.Material.Glacier |
| 244 | p.MaterialVariant = "2022 Stud" |
| 245 | p.Anchored = true |
| 246 | p.Parent = model |
| 247 | end |
| 248 | do |
| 249 | local p = Instance.new("Part") |
| 250 | p.Name = "Z2_Wall_1_2.5" |
| 251 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 252 | p.CFrame = CFrame.new(1, 2.5, 5) |
| 253 | p.BrickColor = BrickColor.new("Dark taupe") |
| 254 | p.Material = Enum.Material.Glacier |
| 255 | p.MaterialVariant = "2022 Stud" |
| 256 | p.Anchored = true |
| 257 | p.Parent = model |
| 258 | end |
| 259 | do |
| 260 | local p = Instance.new("Part") |
| 261 | p.Name = "Z2_BldgL1" |
| 262 | p.Size = Vector3.new(2, 4, 2) |
| 263 | p.CFrame = CFrame.new(-3.5, 3, 7) |
| 264 | p.BrickColor = BrickColor.new("Dark taupe") |
| 265 | p.Material = Enum.Material.Glacier |
| 266 | p.MaterialVariant = "2022 Stud" |
| 267 | p.Anchored = true |
| 268 | p.Parent = model |
| 269 | end |
| 270 | do |
| 271 | local p = Instance.new("Part") |
| 272 | p.Name = "Z2_BldgL2" |
| 273 | p.Size = Vector3.new(1.5, 1, 1.5) |
| 274 | p.CFrame = CFrame.new(-3.5, 5.58, 7) |
| 275 | p.BrickColor = BrickColor.new("Pine Cone") |
| 276 | p.Material = Enum.Material.Glacier |
| 277 | p.MaterialVariant = "2022 Small Stud" |
| 278 | p.Anchored = true |
| 279 | p.Parent = model |
| 280 | end |
| 281 | do |
| 282 | local p = Instance.new("Part") |
| 283 | p.Name = "Z2_BldgR1" |
| 284 | p.Size = Vector3.new(2, 4, 2) |
| 285 | p.CFrame = CFrame.new(3.5, 3, 3) |
| 286 | p.BrickColor = BrickColor.new("Dark taupe") |
| 287 | p.Material = Enum.Material.Glacier |
| 288 | p.MaterialVariant = "2022 Stud" |
| 289 | p.Anchored = true |
| 290 | p.Parent = model |
| 291 | end |
| 292 | do |
| 293 | local p = Instance.new("Part") |
| 294 | p.Name = "Z2_BldgR2" |
| 295 | p.Size = Vector3.new(1.5, 1, 1.5) |
| 296 | p.CFrame = CFrame.new(3.5, 5.58, 3) |
| 297 | p.BrickColor = BrickColor.new("Pine Cone") |
| 298 | p.Material = Enum.Material.Glacier |
| 299 | p.MaterialVariant = "2022 Small Stud" |
| 300 | p.Anchored = true |
| 301 | p.Parent = model |
| 302 | end |
| 303 | do |
| 304 | local p = Instance.new("Part") |
| 305 | p.Shape = Enum.PartType.Cylinder |
| 306 | p.Name = "Z2_Coin" |
| 307 | p.Size = Vector3.new(0.2, 0.8, 0.8) |
| 308 | p.CFrame = CFrame.new(0, 3.5, 8) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)) |
| 309 | p.BrickColor = BrickColor.new("Bright yellow") |
| 310 | p.Material = Enum.Material.Glacier |
| 311 | p.MaterialVariant = "2022 Stud" |
| 312 | p.Anchored = true |
| 313 | p.Parent = model |
| 314 | end |
| 315 | do |
| 316 | local p = Instance.new("Part") |
| 317 | p.Name = "Z3_Path" |
| 318 | p.Size = Vector3.new(4, 1, 10) |
| 319 | p.CFrame = CFrame.new(0, 0.5, -4.96) |
| 320 | p.BrickColor = BrickColor.new("Sand green") |
| 321 | p.Material = Enum.Material.Glacier |
| 322 | p.MaterialVariant = "2022 Stud" |
| 323 | p.Anchored = true |
| 324 | p.Parent = model |
| 325 | end |
| 326 | do |
| 327 | local p = Instance.new("Part") |
| 328 | p.Name = "Z3_SideL" |
| 329 | p.Size = Vector3.new(3, 1, 10) |
| 330 | p.CFrame = CFrame.new(-3.58, 0.5, -4.92) |
| 331 | p.BrickColor = BrickColor.new("Moss") |
| 332 | p.Material = Enum.Material.Glacier |
| 333 | p.MaterialVariant = "2022 Small Stud" |
| 334 | p.Anchored = true |
| 335 | p.Parent = model |
| 336 | end |
| 337 | do |
| 338 | local p = Instance.new("Part") |
| 339 | p.Name = "Z3_SideR" |
| 340 | p.Size = Vector3.new(3, 1, 10) |
| 341 | p.CFrame = CFrame.new(3.58, 0.5, -4.92) |
| 342 | p.BrickColor = BrickColor.new("Moss") |
| 343 | p.Material = Enum.Material.Glacier |
| 344 | p.MaterialVariant = "2022 Small Stud" |
| 345 | p.Anchored = true |
| 346 | p.Parent = model |
| 347 | end |
| 348 | do |
| 349 | local p = Instance.new("Part") |
| 350 | p.Name = "Z3_Wall_-1_1.5" |
| 351 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 352 | p.CFrame = CFrame.new(-1, 1.5, -5) |
| 353 | p.BrickColor = BrickColor.new("Sand green") |
| 354 | p.Material = Enum.Material.Glacier |
| 355 | p.MaterialVariant = "2022 Stud" |
| 356 | p.Anchored = true |
| 357 | p.Parent = model |
| 358 | end |
| 359 | do |
| 360 | local p = Instance.new("Part") |
| 361 | p.Name = "Z3_Wall_-1_2.5" |
| 362 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 363 | p.CFrame = CFrame.new(-1, 2.5, -5) |
| 364 | p.BrickColor = BrickColor.new("Sand green") |
| 365 | p.Material = Enum.Material.Glacier |
| 366 | p.MaterialVariant = "2022 Stud" |
| 367 | p.Anchored = true |
| 368 | p.Parent = model |
| 369 | end |
| 370 | do |
| 371 | local p = Instance.new("Part") |
| 372 | p.Name = "Z3_Wall_-1_3.5" |
| 373 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 374 | p.CFrame = CFrame.new(-1, 3.5, -5) |
| 375 | p.BrickColor = BrickColor.new("Sand green") |
| 376 | p.Material = Enum.Material.Glacier |
| 377 | p.MaterialVariant = "2022 Stud" |
| 378 | p.Anchored = true |
| 379 | p.Parent = model |
| 380 | end |
| 381 | do |
| 382 | local p = Instance.new("Part") |
| 383 | p.Name = "Z3_Wall_0_1.5" |
| 384 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 385 | p.CFrame = CFrame.new(0, 1.5, -5) |
| 386 | p.BrickColor = BrickColor.new("Sand green") |
| 387 | p.Material = Enum.Material.Glacier |
| 388 | p.MaterialVariant = "2022 Stud" |
| 389 | p.Anchored = true |
| 390 | p.Parent = model |
| 391 | end |
| 392 | do |
| 393 | local p = Instance.new("Part") |
| 394 | p.Name = "Z3_Wall_0_2.5" |
| 395 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 396 | p.CFrame = CFrame.new(0, 2.5, -5) |
| 397 | p.BrickColor = BrickColor.new("Sand green") |
| 398 | p.Material = Enum.Material.Glacier |
| 399 | p.MaterialVariant = "2022 Stud" |
| 400 | p.Anchored = true |
| 401 | p.Parent = model |
| 402 | end |
| 403 | do |
| 404 | local p = Instance.new("Part") |
| 405 | p.Name = "Z3_Wall_0_3.5" |
| 406 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 407 | p.CFrame = CFrame.new(0, 3.5, -5) |
| 408 | p.BrickColor = BrickColor.new("Sand green") |
| 409 | p.Material = Enum.Material.Glacier |
| 410 | p.MaterialVariant = "2022 Stud" |
| 411 | p.Anchored = true |
| 412 | p.Parent = model |
| 413 | end |
| 414 | do |
| 415 | local p = Instance.new("Part") |
| 416 | p.Name = "Z3_Wall_1_1.5" |
| 417 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 418 | p.CFrame = CFrame.new(1, 1.5, -5) |
| 419 | p.BrickColor = BrickColor.new("Sand green") |
| 420 | p.Material = Enum.Material.Glacier |
| 421 | p.MaterialVariant = "2022 Stud" |
| 422 | p.Anchored = true |
| 423 | p.Parent = model |
| 424 | end |
| 425 | do |
| 426 | local p = Instance.new("Part") |
| 427 | p.Name = "Z3_Wall_1_2.5" |
| 428 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 429 | p.CFrame = CFrame.new(1, 2.5, -5) |
| 430 | p.BrickColor = BrickColor.new("Sand green") |
| 431 | p.Material = Enum.Material.Glacier |
| 432 | p.MaterialVariant = "2022 Stud" |
| 433 | p.Anchored = true |
| 434 | p.Parent = model |
| 435 | end |
| 436 | do |
| 437 | local p = Instance.new("Part") |
| 438 | p.Name = "Z3_Wall_1_3.5" |
| 439 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 440 | p.CFrame = CFrame.new(1, 3.5, -5) |
| 441 | p.BrickColor = BrickColor.new("Sand green") |
| 442 | p.Material = Enum.Material.Glacier |
| 443 | p.MaterialVariant = "2022 Stud" |
| 444 | p.Anchored = true |
| 445 | p.Parent = model |
| 446 | end |
| 447 | do |
| 448 | local p = Instance.new("Part") |
| 449 | p.Name = "Z3_BldgL1" |
| 450 | p.Size = Vector3.new(2, 5, 2) |
| 451 | p.CFrame = CFrame.new(-3.5, 3.58, -5) |
| 452 | p.BrickColor = BrickColor.new("Moss") |
| 453 | p.Material = Enum.Material.Glacier |
| 454 | p.MaterialVariant = "2022 Small Stud" |
| 455 | p.Anchored = true |
| 456 | p.Parent = model |
| 457 | end |
| 458 | do |
| 459 | local p = Instance.new("Part") |
| 460 | p.Name = "Z3_BldgL2" |
| 461 | p.Size = Vector3.new(1.5, 1, 1.5) |
| 462 | p.CFrame = CFrame.new(-3.5, 6.66, -5) |
| 463 | p.BrickColor = BrickColor.new("Sand green") |
| 464 | p.Material = Enum.Material.Glacier |
| 465 | p.MaterialVariant = "2022 Stud" |
| 466 | p.Anchored = true |
| 467 | p.Parent = model |
| 468 | end |
| 469 | do |
| 470 | local p = Instance.new("Part") |
| 471 | p.Name = "Z3_BldgR1" |
| 472 | p.Size = Vector3.new(2, 5, 2) |
| 473 | p.CFrame = CFrame.new(3.5, 3.58, -5) |
| 474 | p.BrickColor = BrickColor.new("Moss") |
| 475 | p.Material = Enum.Material.Glacier |
| 476 | p.MaterialVariant = "2022 Small Stud" |
| 477 | p.Anchored = true |
| 478 | p.Parent = model |
| 479 | end |
| 480 | do |
| 481 | local p = Instance.new("Part") |
| 482 | p.Name = "Z3_BldgR2" |
| 483 | p.Size = Vector3.new(1.5, 1, 1.5) |
| 484 | p.CFrame = CFrame.new(3.5, 6.66, -5) |
| 485 | p.BrickColor = BrickColor.new("Sand green") |
| 486 | p.Material = Enum.Material.Glacier |
| 487 | p.MaterialVariant = "2022 Stud" |
| 488 | p.Anchored = true |
| 489 | p.Parent = model |
| 490 | end |
| 491 | do |
| 492 | local p = Instance.new("Part") |
| 493 | p.Shape = Enum.PartType.Ball |
| 494 | p.Name = "Z3_Pistachio1" |
| 495 | p.Size = Vector3.new(0.8, 0.5, 0.5) |
| 496 | p.CFrame = CFrame.new(-2.5, 1.3, -3) |
| 497 | p.BrickColor = BrickColor.new("Sand green") |
| 498 | p.Material = Enum.Material.Glacier |
| 499 | p.MaterialVariant = "2022 Stud" |
| 500 | p.Anchored = true |
| 501 | p.Parent = model |
| 502 | end |
| 503 | do |
| 504 | local p = Instance.new("Part") |
| 505 | p.Shape = Enum.PartType.Ball |
| 506 | p.Name = "Z3_Pistachio2" |
| 507 | p.Size = Vector3.new(0.8, 0.5, 0.5) |
| 508 | p.CFrame = CFrame.new(2.5, 1.3, -7) |
| 509 | p.BrickColor = BrickColor.new("Sand green") |
| 510 | p.Material = Enum.Material.Glacier |
| 511 | p.MaterialVariant = "2022 Stud" |
| 512 | p.Anchored = true |
| 513 | p.Parent = model |
| 514 | end |
| 515 | do |
| 516 | local p = Instance.new("Part") |
| 517 | p.Shape = Enum.PartType.Cylinder |
| 518 | p.Name = "Z3_Coin" |
| 519 | p.Size = Vector3.new(0.2, 0.8, 0.8) |
| 520 | p.CFrame = CFrame.new(0, 4.5, -2) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)) |
| 521 | p.BrickColor = BrickColor.new("Bright yellow") |
| 522 | p.Material = Enum.Material.Glacier |
| 523 | p.MaterialVariant = "2022 Stud" |
| 524 | p.Anchored = true |
| 525 | p.Parent = model |
| 526 | end |
| 527 | do |
| 528 | local p = Instance.new("Part") |
| 529 | p.Name = "Z4_Path" |
| 530 | p.Size = Vector3.new(4, 1, 10) |
| 531 | p.CFrame = CFrame.new(0, 0.5, -15) |
| 532 | p.BrickColor = BrickColor.new("Gold") |
| 533 | p.Material = Enum.Material.Glacier |
| 534 | p.MaterialVariant = "2022 Stud" |
| 535 | p.Anchored = true |
| 536 | p.Parent = model |
| 537 | end |
| 538 | do |
| 539 | local p = Instance.new("Part") |
| 540 | p.Name = "Z4_SideL" |
| 541 | p.Size = Vector3.new(3, 1, 10) |
| 542 | p.CFrame = CFrame.new(-3.58, 0.42, -15) |
| 543 | p.BrickColor = BrickColor.new("Bright yellow") |
| 544 | p.Material = Enum.Material.Glacier |
| 545 | p.MaterialVariant = "2022 Stud" |
| 546 | p.Anchored = true |
| 547 | p.Parent = model |
| 548 | end |
| 549 | do |
| 550 | local p = Instance.new("Part") |
| 551 | p.Name = "Z4_SideR" |
| 552 | p.Size = Vector3.new(3, 1, 10) |
| 553 | p.CFrame = CFrame.new(3.58, 0.42, -15) |
| 554 | p.BrickColor = BrickColor.new("Bright yellow") |
| 555 | p.Material = Enum.Material.Glacier |
| 556 | p.MaterialVariant = "2022 Stud" |
| 557 | p.Anchored = true |
| 558 | p.Parent = model |
| 559 | end |
| 560 | do |
| 561 | local p = Instance.new("Part") |
| 562 | p.Name = "Z4_Wall_-1_1.5" |
| 563 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 564 | p.CFrame = CFrame.new(-1, 1.5, -15) |
| 565 | p.BrickColor = BrickColor.new("Gold") |
| 566 | p.Material = Enum.Material.Glacier |
| 567 | p.MaterialVariant = "2022 Stud" |
| 568 | p.Anchored = true |
| 569 | p.Parent = model |
| 570 | end |
| 571 | do |
| 572 | local p = Instance.new("Part") |
| 573 | p.Name = "Z4_Wall_-1_2.5" |
| 574 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 575 | p.CFrame = CFrame.new(-1, 2.5, -15) |
| 576 | p.BrickColor = BrickColor.new("Gold") |
| 577 | p.Material = Enum.Material.Glacier |
| 578 | p.MaterialVariant = "2022 Stud" |
| 579 | p.Anchored = true |
| 580 | p.Parent = model |
| 581 | end |
| 582 | do |
| 583 | local p = Instance.new("Part") |
| 584 | p.Name = "Z4_Wall_-1_3.5" |
| 585 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 586 | p.CFrame = CFrame.new(-1, 3.5, -15) |
| 587 | p.BrickColor = BrickColor.new("Gold") |
| 588 | p.Material = Enum.Material.Glacier |
| 589 | p.MaterialVariant = "2022 Stud" |
| 590 | p.Anchored = true |
| 591 | p.Parent = model |
| 592 | end |
| 593 | do |
| 594 | local p = Instance.new("Part") |
| 595 | p.Name = "Z4_Wall_-1_4.5" |
| 596 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 597 | p.CFrame = CFrame.new(-1, 4.5, -15) |
| 598 | p.BrickColor = BrickColor.new("Gold") |
| 599 | p.Material = Enum.Material.Glacier |
| 600 | p.MaterialVariant = "2022 Stud" |
| 601 | p.Anchored = true |
| 602 | p.Parent = model |
| 603 | end |
| 604 | do |
| 605 | local p = Instance.new("Part") |
| 606 | p.Name = "Z4_Wall_0_1.5" |
| 607 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 608 | p.CFrame = CFrame.new(0, 1.5, -15) |
| 609 | p.BrickColor = BrickColor.new("Gold") |
| 610 | p.Material = Enum.Material.Glacier |
| 611 | p.MaterialVariant = "2022 Stud" |
| 612 | p.Anchored = true |
| 613 | p.Parent = model |
| 614 | end |
| 615 | do |
| 616 | local p = Instance.new("Part") |
| 617 | p.Name = "Z4_Wall_0_2.5" |
| 618 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 619 | p.CFrame = CFrame.new(0, 2.5, -15) |
| 620 | p.BrickColor = BrickColor.new("Gold") |
| 621 | p.Material = Enum.Material.Glacier |
| 622 | p.MaterialVariant = "2022 Stud" |
| 623 | p.Anchored = true |
| 624 | p.Parent = model |
| 625 | end |
| 626 | do |
| 627 | local p = Instance.new("Part") |
| 628 | p.Name = "Z4_Wall_0_3.5" |
| 629 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 630 | p.CFrame = CFrame.new(0, 3.5, -15) |
| 631 | p.BrickColor = BrickColor.new("Gold") |
| 632 | p.Material = Enum.Material.Glacier |
| 633 | p.MaterialVariant = "2022 Stud" |
| 634 | p.Anchored = true |
| 635 | p.Parent = model |
| 636 | end |
| 637 | do |
| 638 | local p = Instance.new("Part") |
| 639 | p.Name = "Z4_Wall_0_4.5" |
| 640 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 641 | p.CFrame = CFrame.new(0, 4.5, -15) |
| 642 | p.BrickColor = BrickColor.new("Gold") |
| 643 | p.Material = Enum.Material.Glacier |
| 644 | p.MaterialVariant = "2022 Stud" |
| 645 | p.Anchored = true |
| 646 | p.Parent = model |
| 647 | end |
| 648 | do |
| 649 | local p = Instance.new("Part") |
| 650 | p.Name = "Z4_Wall_1_1.5" |
| 651 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 652 | p.CFrame = CFrame.new(1, 1.5, -15) |
| 653 | p.BrickColor = BrickColor.new("Gold") |
| 654 | p.Material = Enum.Material.Glacier |
| 655 | p.MaterialVariant = "2022 Stud" |
| 656 | p.Anchored = true |
| 657 | p.Parent = model |
| 658 | end |
| 659 | do |
| 660 | local p = Instance.new("Part") |
| 661 | p.Name = "Z4_Wall_1_2.5" |
| 662 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 663 | p.CFrame = CFrame.new(1, 2.5, -15) |
| 664 | p.BrickColor = BrickColor.new("Gold") |
| 665 | p.Material = Enum.Material.Glacier |
| 666 | p.MaterialVariant = "2022 Stud" |
| 667 | p.Anchored = true |
| 668 | p.Parent = model |
| 669 | end |
| 670 | do |
| 671 | local p = Instance.new("Part") |
| 672 | p.Name = "Z4_Wall_1_3.5" |
| 673 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 674 | p.CFrame = CFrame.new(1, 3.5, -15) |
| 675 | p.BrickColor = BrickColor.new("Gold") |
| 676 | p.Material = Enum.Material.Glacier |
| 677 | p.MaterialVariant = "2022 Stud" |
| 678 | p.Anchored = true |
| 679 | p.Parent = model |
| 680 | end |
| 681 | do |
| 682 | local p = Instance.new("Part") |
| 683 | p.Name = "Z4_Wall_1_4.5" |
| 684 | p.Size = Vector3.new(0.95, 0.95, 0.95) |
| 685 | p.CFrame = CFrame.new(1, 4.5, -15) |
| 686 | p.BrickColor = BrickColor.new("Gold") |
| 687 | p.Material = Enum.Material.Glacier |
| 688 | p.MaterialVariant = "2022 Stud" |
| 689 | p.Anchored = true |
| 690 | p.Parent = model |
| 691 | end |
| 692 | do |
| 693 | local p = Instance.new("Part") |
| 694 | p.Name = "Z4_BldgL1" |
| 695 | p.Size = Vector3.new(2.5, 6, 2.5) |
| 696 | p.CFrame = CFrame.new(-3.5, 4, -15) |
| 697 | p.BrickColor = BrickColor.new("Bright yellow") |
| 698 | p.Material = Enum.Material.Glacier |
| 699 | p.MaterialVariant = "2022 Stud" |
| 700 | p.Anchored = true |
| 701 | p.Parent = model |
| 702 | end |
| 703 | do |
| 704 | local p = Instance.new("Part") |
| 705 | p.Name = "Z4_BldgL2" |
| 706 | p.Size = Vector3.new(2, 1, 2) |
| 707 | p.CFrame = CFrame.new(-3.5, 7.58, -15) |
| 708 | p.BrickColor = BrickColor.new("Gold") |
| 709 | p.Material = Enum.Material.Glacier |
| 710 | p.MaterialVariant = "2022 Stud" |
| 711 | p.Anchored = true |
| 712 | p.Parent = model |
| 713 | end |
| 714 | do |
| 715 | local p = Instance.new("Part") |
| 716 | p.Name = "Z4_BldgR1" |
| 717 | p.Size = Vector3.new(2.5, 6, 2.5) |
| 718 | p.CFrame = CFrame.new(3.5, 4, -15) |
| 719 | p.BrickColor = BrickColor.new("Bright yellow") |
| 720 | p.Material = Enum.Material.Glacier |
| 721 | p.MaterialVariant = "2022 Stud" |
| 722 | p.Anchored = true |
| 723 | p.Parent = model |
| 724 | end |
| 725 | do |
| 726 | local p = Instance.new("Part") |
| 727 | p.Name = "Z4_BldgR2" |
| 728 | p.Size = Vector3.new(2, 1, 2) |
| 729 | p.CFrame = CFrame.new(3.5, 7.58, -15) |
| 730 | p.BrickColor = BrickColor.new("Gold") |
| 731 | p.Material = Enum.Material.Glacier |
| 732 | p.MaterialVariant = "2022 Stud" |
| 733 | p.Anchored = true |
| 734 | p.Parent = model |
| 735 | end |
| 736 | do |
| 737 | local p = Instance.new("Part") |
| 738 | p.Name = "Z4_GoldBar1" |
| 739 | p.Size = Vector3.new(1.2, 0.4, 0.6) |
| 740 | p.CFrame = CFrame.new(-2.5, 1.24, -13) |
| 741 | p.BrickColor = BrickColor.new("Gold") |
| 742 | p.Material = Enum.Material.Glacier |
| 743 | p.MaterialVariant = "2022 Stud" |
| 744 | p.Anchored = true |
| 745 | p.Parent = model |
| 746 | end |
| 747 | do |
| 748 | local p = Instance.new("Part") |
| 749 | p.Name = "Z4_GoldBar2" |
| 750 | p.Size = Vector3.new(1.2, 0.4, 0.6) |
| 751 | p.CFrame = CFrame.new(2.5, 1.24, -17) * CFrame.Angles(math.rad(0), math.rad(45), math.rad(0)) |
| 752 | p.BrickColor = BrickColor.new("Gold") |
| 753 | p.Material = Enum.Material.Glacier |
| 754 | p.MaterialVariant = "2022 Stud" |
| 755 | p.Anchored = true |
| 756 | p.Parent = model |
| 757 | end |
| 758 | do |
| 759 | local p = Instance.new("Part") |
| 760 | p.Shape = Enum.PartType.Cylinder |
| 761 | p.Name = "Z4_Coin" |
| 762 | p.Size = Vector3.new(0.2, 0.8, 0.8) |
| 763 | p.CFrame = CFrame.new(0, 5.5, -12) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)) |
| 764 | p.BrickColor = BrickColor.new("Bright yellow") |
| 765 | p.Material = Enum.Material.Glacier |
| 766 | p.MaterialVariant = "2022 Stud" |
| 767 | p.Anchored = true |
| 768 | p.Parent = model |
| 769 | end |
| 770 | do |
| 771 | local p = Instance.new("Part") |
| 772 | p.Name = "Z5_Path" |
| 773 | p.Size = Vector3.new(4, 1, 10) |
| 774 | p.CFrame = CFrame.new(0, 0.46, -25.04) |
| 775 | p.BrickColor = BrickColor.new("Gold") |
| 776 | p.Material = Enum.Material.Glacier |
| 777 | p.MaterialVariant = "2022 Stud" |
| 778 | p.Anchored = true |
| 779 | p.Parent = model |
| 780 | end |
| 781 | do |
| 782 | local p = Instance.new("Part") |
| 783 | p.Name = "Z5_SideL" |
| 784 | p.Size = Vector3.new(3, 1, 10) |
| 785 | p.CFrame = CFrame.new(-3.58, 0.42, -25.08) |
| 786 | p.BrickColor = BrickColor.new("Bright yellow") |
| 787 | p.Material = Enum.Material.Glacier |
| 788 | p.MaterialVariant = "2022 Stud" |
| 789 | p.Anchored = true |
| 790 | p.Parent = model |
| 791 | end |
| 792 | do |
| 793 | local p = Instance.new("Part") |
| 794 | p.Name = "Z5_SideR" |
| 795 | p.Size = Vector3.new(3, 1, 10) |
| 796 | p.CFrame = CFrame.new(3.58, 0.42, -25.08) |
| 797 | p.BrickColor = BrickColor.new("Bright yellow") |
| 798 | p.Material = Enum.Material.Glacier |
| 799 | p.MaterialVariant = "2022 Stud" |
| 800 | p.Anchored = true |
| 801 | p.Parent = model |
| 802 | end |
| 803 | do |
| 804 | local p = Instance.new("Part") |
| 805 | p.Name = "Z5_TempleBase" |
| 806 | p.Size = Vector3.new(8, 4, 4) |
| 807 | p.CFrame = CFrame.new(0, 3, -28) |
| 808 | p.BrickColor = BrickColor.new("Bright yellow") |
| 809 | p.Material = Enum.Material.Glacier |
| 810 | p.MaterialVariant = "2022 Stud" |
| 811 | p.Anchored = true |
| 812 | p.Parent = model |
| 813 | end |
| 814 | do |
| 815 | local p = Instance.new("Part") |
| 816 | p.Name = "Z5_TempleMid" |
| 817 | p.Size = Vector3.new(6, 2, 3) |
| 818 | p.CFrame = CFrame.new(0, 6.04, -28) |
| 819 | p.BrickColor = BrickColor.new("Gold") |
| 820 | p.Material = Enum.Material.Glacier |
| 821 | p.MaterialVariant = "2022 Stud" |
| 822 | p.Anchored = true |
| 823 | p.Parent = model |
| 824 | end |
| 825 | do |
| 826 | local p = Instance.new("Part") |
| 827 | p.Name = "Z5_TowerL" |
| 828 | p.Size = Vector3.new(2, 6, 2) |
| 829 | p.CFrame = CFrame.new(-3.5, 4.08, -28) |
| 830 | p.BrickColor = BrickColor.new("Gold") |
| 831 | p.Material = Enum.Material.Glacier |
| 832 | p.MaterialVariant = "2022 Stud" |
| 833 | p.Anchored = true |
| 834 | p.Parent = model |
| 835 | end |
| 836 | do |
| 837 | local p = Instance.new("Part") |
| 838 | p.Name = "Z5_TowerR" |
| 839 | p.Size = Vector3.new(2, 6, 2) |
| 840 | p.CFrame = CFrame.new(3.5, 4.08, -28) |
| 841 | p.BrickColor = BrickColor.new("Gold") |
| 842 | p.Material = Enum.Material.Glacier |
| 843 | p.MaterialVariant = "2022 Stud" |
| 844 | p.Anchored = true |
| 845 | p.Parent = model |
| 846 | end |
| 847 | do |
| 848 | local p = Instance.new("Part") |
| 849 | p.Name = "Z5_GateBase" |
| 850 | p.Size = Vector3.new(3, 3, 0.5) |
| 851 | p.CFrame = CFrame.new(0, 2.54, -26.1) |
| 852 | p.BrickColor = BrickColor.new("Really black") |
| 853 | p.Material = Enum.Material.Glacier |
| 854 | p.MaterialVariant = "2022 Universal" |
| 855 | p.Anchored = true |
| 856 | p.Parent = model |
| 857 | end |
| 858 | do |
| 859 | local p = Instance.new("Part") |
| 860 | p.Name = "Z5_GateTrimL" |
| 861 | p.Size = Vector3.new(0.3, 3, 0.6) |
| 862 | p.CFrame = CFrame.new(-1.73, 2.58, -25.92) |
| 863 | p.BrickColor = BrickColor.new("Bright yellow") |
| 864 | p.Material = Enum.Material.Glacier |
| 865 | p.MaterialVariant = "2022 Stud" |
| 866 | p.Anchored = true |
| 867 | p.Parent = model |
| 868 | end |
| 869 | do |
| 870 | local p = Instance.new("Part") |
| 871 | p.Name = "Z5_GateTrimR" |
| 872 | p.Size = Vector3.new(0.3, 3, 0.6) |
| 873 | p.CFrame = CFrame.new(1.73, 2.58, -25.92) |
| 874 | p.BrickColor = BrickColor.new("Bright yellow") |
| 875 | p.Material = Enum.Material.Glacier |
| 876 | p.MaterialVariant = "2022 Stud" |
| 877 | p.Anchored = true |
| 878 | p.Parent = model |
| 879 | end |
| 880 | do |
| 881 | local p = Instance.new("Part") |
| 882 | p.Name = "Z5_Glow1" |
| 883 | p.Size = Vector3.new(0.5, 1, 0.1) |
| 884 | p.CFrame = CFrame.new(-1.5, 4, -26.1) |
| 885 | p.BrickColor = BrickColor.new("Bright yellow") |
| 886 | p.Material = Enum.Material.Neon |
| 887 | p.Anchored = true |
| 888 | p.Parent = model |
| 889 | end |
| 890 | do |
| 891 | local p = Instance.new("Part") |
| 892 | p.Name = "Z5_Glow2" |
| 893 | p.Size = Vector3.new(0.5, 1, 0.1) |
| 894 | p.CFrame = CFrame.new(1.5, 4, -26.1) |
| 895 | p.BrickColor = BrickColor.new("Bright yellow") |
| 896 | p.Material = Enum.Material.Neon |
| 897 | p.Anchored = true |
| 898 | p.Parent = model |
| 899 | end |
| 900 | do |
| 901 | local rightV = Vector3.new(1,0,0).Unit |
| 902 | local upV = (Vector3.new(0,1,0) - Vector3.new(0,1,0):Dot(rightV)*rightV).Unit |
| 903 | local normalV = upV:Cross(rightV) |
| 904 | local pos = Vector3.new(0, 4.08, -26.1) |
| 905 | local cyl = Instance.new("Part") |
| 906 | cyl.Shape = Enum.PartType.Cylinder |
| 907 | cyl.Size = Vector3.new(0.5, 3, 3) |
| 908 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 909 | cyl.BrickColor = BrickColor.new("Really black") |
| 910 | cyl.Material = Enum.Material.Glacier |
| 911 | cyl.MaterialVariant = "2022 Universal" |
| 912 | cyl.Anchored = true; cyl.Parent = workspace |
| 913 | local cuts = {} |
| 914 | local angBoxes = {} |
| 915 | do |
| 916 | local edgeDir = 1*rightV + 0*upV |
| 917 | local edgePerp = 0*rightV + 1*upV |
| 918 | local cut = Instance.new("Part") |
| 919 | cut.Size = Vector3.new(6, 0.7, 6) |
| 920 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 3 * edgePerp, edgeDir, normalV) |
| 921 | cut.BrickColor = BrickColor.new("Really black") |
| 922 | cut.Material = Enum.Material.Glacier |
| 923 | cut.MaterialVariant = "2022 Universal" |
| 924 | cut.Anchored = true; cut.Parent = workspace |
| 925 | table.insert(angBoxes, cut) |
| 926 | end |
| 927 | do |
| 928 | local edgeDir = -1*rightV + 0*upV |
| 929 | local edgePerp = 0*rightV + -1*upV |
| 930 | local cut = Instance.new("Part") |
| 931 | cut.Size = Vector3.new(6, 0.7, 6) |
| 932 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 3 * edgePerp, edgeDir, normalV) |
| 933 | cut.BrickColor = BrickColor.new("Really black") |
| 934 | cut.Material = Enum.Material.Glacier |
| 935 | cut.MaterialVariant = "2022 Universal" |
| 936 | cut.Anchored = true; cut.Parent = workspace |
| 937 | table.insert(angBoxes, cut) |
| 938 | end |
| 939 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 940 | if #cuts > 0 then |
| 941 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 942 | for _, c in ipairs(cuts) do c:Destroy() end |
| 943 | if ok and result then |
| 944 | cyl:Destroy() |
| 945 | result.Name = "Z5_GateArch"; result.Anchored = true; result.Parent = model |
| 946 | else |
| 947 | cyl.Name = "Z5_GateArch"; cyl.Parent = model |
| 948 | end |
| 949 | else |
| 950 | cyl.Name = "Z5_GateArch"; cyl.Parent = model |
| 951 | end |
| 952 | end |
| 953 | do |
| 954 | local rightV = Vector3.new(1,0,0).Unit |
| 955 | local upV = (Vector3.new(0,1,0) - Vector3.new(0,1,0):Dot(rightV)*rightV).Unit |
| 956 | local normalV = upV:Cross(rightV) |
| 957 | local pos = Vector3.new(0, 4, -26) |
| 958 | local cyl = Instance.new("Part") |
| 959 | cyl.Shape = Enum.PartType.Cylinder |
| 960 | cyl.Size = Vector3.new(0.6, 3.6, 3.6) |
| 961 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 962 | cyl.BrickColor = BrickColor.new("Bright yellow") |
| 963 | cyl.Material = Enum.Material.Glacier |
| 964 | cyl.MaterialVariant = "2022 Stud" |
| 965 | cyl.Anchored = true; cyl.Parent = workspace |
| 966 | local cuts = {} |
| 967 | local hole = Instance.new("Part") |
| 968 | hole.Shape = Enum.PartType.Cylinder |
| 969 | hole.Size = Vector3.new(0.8, 3, 3) |
| 970 | hole.CFrame = cyl.CFrame |
| 971 | hole.BrickColor = BrickColor.new("Bright yellow") |
| 972 | hole.Material = Enum.Material.Glacier |
| 973 | hole.MaterialVariant = "2022 Stud" |
| 974 | hole.Anchored = true; hole.Parent = workspace |
| 975 | table.insert(cuts, hole) |
| 976 | local angBoxes = {} |
| 977 | do |
| 978 | local edgeDir = 1*rightV + 0*upV |
| 979 | local edgePerp = 0*rightV + 1*upV |
| 980 | local cut = Instance.new("Part") |
| 981 | cut.Size = Vector3.new(7.2, 0.8, 7.2) |
| 982 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 3.6 * edgePerp, edgeDir, normalV) |
| 983 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 984 | cut.Material = Enum.Material.Glacier |
| 985 | cut.MaterialVariant = "2022 Stud" |
| 986 | cut.Anchored = true; cut.Parent = workspace |
| 987 | table.insert(angBoxes, cut) |
| 988 | end |
| 989 | do |
| 990 | local edgeDir = -1*rightV + 0*upV |
| 991 | local edgePerp = 0*rightV + -1*upV |
| 992 | local cut = Instance.new("Part") |
| 993 | cut.Size = Vector3.new(7.2, 0.8, 7.2) |
| 994 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 3.6 * edgePerp, edgeDir, normalV) |
| 995 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 996 | cut.Material = Enum.Material.Glacier |
| 997 | cut.MaterialVariant = "2022 Stud" |
| 998 | cut.Anchored = true; cut.Parent = workspace |
| 999 | table.insert(angBoxes, cut) |
| 1000 | end |
| 1001 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 1002 | if #cuts > 0 then |
| 1003 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 1004 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1005 | if ok and result then |
| 1006 | cyl:Destroy() |
| 1007 | result.Name = "Z5_GateTrim"; result.Anchored = true; result.Parent = model |
| 1008 | else |
| 1009 | cyl.Name = "Z5_GateTrim"; cyl.Parent = model |
| 1010 | end |
| 1011 | else |
| 1012 | cyl.Name = "Z5_GateTrim"; cyl.Parent = model |
| 1013 | end |
| 1014 | end |
| 1015 | do |
| 1016 | local upV = Vector3.new(0,1,0).Unit |
| 1017 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1018 | local forwardV = rightV:Cross(upV) |
| 1019 | local pos = Vector3.new(-3.5, 6.16, 7) |
| 1020 | local ball = Instance.new("Part") |
| 1021 | ball.Shape = Enum.PartType.Ball |
| 1022 | ball.Size = Vector3.new(1.5, 1.5, 1.5) |
| 1023 | ball.CFrame = CFrame.new(pos) |
| 1024 | ball.BrickColor = BrickColor.new("Dark taupe") |
| 1025 | ball.Material = Enum.Material.Glacier |
| 1026 | ball.MaterialVariant = "2022 Stud" |
| 1027 | ball.Anchored = true; ball.Parent = workspace |
| 1028 | local cuts = {} |
| 1029 | do |
| 1030 | local h = 0 |
| 1031 | local cut = Instance.new("Part") |
| 1032 | cut.Size = Vector3.new(3, 3, 3) |
| 1033 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-1.5), rightV, upV) |
| 1034 | cut.BrickColor = BrickColor.new("Dark taupe") |
| 1035 | cut.Material = Enum.Material.Glacier |
| 1036 | cut.MaterialVariant = "2022 Stud" |
| 1037 | cut.Anchored = true; cut.Parent = workspace |
| 1038 | table.insert(cuts, cut) |
| 1039 | end |
| 1040 | if #cuts > 0 then |
| 1041 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1042 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1043 | if ok and result then |
| 1044 | ball:Destroy() |
| 1045 | result.Name = "Z2_DomeL"; result.Anchored = true; result.Parent = model |
| 1046 | else |
| 1047 | ball.Name = "Z2_DomeL"; ball.Parent = model |
| 1048 | end |
| 1049 | else |
| 1050 | ball.Name = "Z2_DomeL"; ball.Parent = model |
| 1051 | end |
| 1052 | end |
| 1053 | do |
| 1054 | local upV = Vector3.new(0,1,0).Unit |
| 1055 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1056 | local forwardV = rightV:Cross(upV) |
| 1057 | local pos = Vector3.new(3.5, 6.16, 3) |
| 1058 | local ball = Instance.new("Part") |
| 1059 | ball.Shape = Enum.PartType.Ball |
| 1060 | ball.Size = Vector3.new(1.5, 1.5, 1.5) |
| 1061 | ball.CFrame = CFrame.new(pos) |
| 1062 | ball.BrickColor = BrickColor.new("Dark taupe") |
| 1063 | ball.Material = Enum.Material.Glacier |
| 1064 | ball.MaterialVariant = "2022 Stud" |
| 1065 | ball.Anchored = true; ball.Parent = workspace |
| 1066 | local cuts = {} |
| 1067 | do |
| 1068 | local h = 0 |
| 1069 | local cut = Instance.new("Part") |
| 1070 | cut.Size = Vector3.new(3, 3, 3) |
| 1071 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-1.5), rightV, upV) |
| 1072 | cut.BrickColor = BrickColor.new("Dark taupe") |
| 1073 | cut.Material = Enum.Material.Glacier |
| 1074 | cut.MaterialVariant = "2022 Stud" |
| 1075 | cut.Anchored = true; cut.Parent = workspace |
| 1076 | table.insert(cuts, cut) |
| 1077 | end |
| 1078 | if #cuts > 0 then |
| 1079 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1080 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1081 | if ok and result then |
| 1082 | ball:Destroy() |
| 1083 | result.Name = "Z2_DomeR"; result.Anchored = true; result.Parent = model |
| 1084 | else |
| 1085 | ball.Name = "Z2_DomeR"; ball.Parent = model |
| 1086 | end |
| 1087 | else |
| 1088 | ball.Name = "Z2_DomeR"; ball.Parent = model |
| 1089 | end |
| 1090 | end |
| 1091 | do |
| 1092 | local upV = Vector3.new(0,1,0).Unit |
| 1093 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1094 | local forwardV = rightV:Cross(upV) |
| 1095 | local pos = Vector3.new(-3.5, 7.24, -5) |
| 1096 | local ball = Instance.new("Part") |
| 1097 | ball.Shape = Enum.PartType.Ball |
| 1098 | ball.Size = Vector3.new(1.5, 1.5, 1.5) |
| 1099 | ball.CFrame = CFrame.new(pos) |
| 1100 | ball.BrickColor = BrickColor.new("Moss") |
| 1101 | ball.Material = Enum.Material.Glacier |
| 1102 | ball.MaterialVariant = "2022 Small Stud" |
| 1103 | ball.Anchored = true; ball.Parent = workspace |
| 1104 | local cuts = {} |
| 1105 | do |
| 1106 | local h = 0 |
| 1107 | local cut = Instance.new("Part") |
| 1108 | cut.Size = Vector3.new(3, 3, 3) |
| 1109 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-1.5), rightV, upV) |
| 1110 | cut.BrickColor = BrickColor.new("Moss") |
| 1111 | cut.Material = Enum.Material.Glacier |
| 1112 | cut.MaterialVariant = "2022 Small Stud" |
| 1113 | cut.Anchored = true; cut.Parent = workspace |
| 1114 | table.insert(cuts, cut) |
| 1115 | end |
| 1116 | if #cuts > 0 then |
| 1117 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1118 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1119 | if ok and result then |
| 1120 | ball:Destroy() |
| 1121 | result.Name = "Z3_DomeL"; result.Anchored = true; result.Parent = model |
| 1122 | else |
| 1123 | ball.Name = "Z3_DomeL"; ball.Parent = model |
| 1124 | end |
| 1125 | else |
| 1126 | ball.Name = "Z3_DomeL"; ball.Parent = model |
| 1127 | end |
| 1128 | end |
| 1129 | do |
| 1130 | local upV = Vector3.new(0,1,0).Unit |
| 1131 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1132 | local forwardV = rightV:Cross(upV) |
| 1133 | local pos = Vector3.new(3.5, 7.24, -5) |
| 1134 | local ball = Instance.new("Part") |
| 1135 | ball.Shape = Enum.PartType.Ball |
| 1136 | ball.Size = Vector3.new(1.5, 1.5, 1.5) |
| 1137 | ball.CFrame = CFrame.new(pos) |
| 1138 | ball.BrickColor = BrickColor.new("Moss") |
| 1139 | ball.Material = Enum.Material.Glacier |
| 1140 | ball.MaterialVariant = "2022 Small Stud" |
| 1141 | ball.Anchored = true; ball.Parent = workspace |
| 1142 | local cuts = {} |
| 1143 | do |
| 1144 | local h = 0 |
| 1145 | local cut = Instance.new("Part") |
| 1146 | cut.Size = Vector3.new(3, 3, 3) |
| 1147 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-1.5), rightV, upV) |
| 1148 | cut.BrickColor = BrickColor.new("Moss") |
| 1149 | cut.Material = Enum.Material.Glacier |
| 1150 | cut.MaterialVariant = "2022 Small Stud" |
| 1151 | cut.Anchored = true; cut.Parent = workspace |
| 1152 | table.insert(cuts, cut) |
| 1153 | end |
| 1154 | if #cuts > 0 then |
| 1155 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1156 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1157 | if ok and result then |
| 1158 | ball:Destroy() |
| 1159 | result.Name = "Z3_DomeR"; result.Anchored = true; result.Parent = model |
| 1160 | else |
| 1161 | ball.Name = "Z3_DomeR"; ball.Parent = model |
| 1162 | end |
| 1163 | else |
| 1164 | ball.Name = "Z3_DomeR"; ball.Parent = model |
| 1165 | end |
| 1166 | end |
| 1167 | do |
| 1168 | local upV = Vector3.new(0,1,0).Unit |
| 1169 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1170 | local forwardV = rightV:Cross(upV) |
| 1171 | local pos = Vector3.new(-3.5, 8.16, -15) |
| 1172 | local ball = Instance.new("Part") |
| 1173 | ball.Shape = Enum.PartType.Ball |
| 1174 | ball.Size = Vector3.new(2, 2, 2) |
| 1175 | ball.CFrame = CFrame.new(pos) |
| 1176 | ball.BrickColor = BrickColor.new("Bright yellow") |
| 1177 | ball.Material = Enum.Material.Glacier |
| 1178 | ball.MaterialVariant = "2022 Stud" |
| 1179 | ball.Anchored = true; ball.Parent = workspace |
| 1180 | local cuts = {} |
| 1181 | do |
| 1182 | local h = 0 |
| 1183 | local cut = Instance.new("Part") |
| 1184 | cut.Size = Vector3.new(4, 4, 4) |
| 1185 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-2), rightV, upV) |
| 1186 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 1187 | cut.Material = Enum.Material.Glacier |
| 1188 | cut.MaterialVariant = "2022 Stud" |
| 1189 | cut.Anchored = true; cut.Parent = workspace |
| 1190 | table.insert(cuts, cut) |
| 1191 | end |
| 1192 | if #cuts > 0 then |
| 1193 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1194 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1195 | if ok and result then |
| 1196 | ball:Destroy() |
| 1197 | result.Name = "Z4_DomeL"; result.Anchored = true; result.Parent = model |
| 1198 | else |
| 1199 | ball.Name = "Z4_DomeL"; ball.Parent = model |
| 1200 | end |
| 1201 | else |
| 1202 | ball.Name = "Z4_DomeL"; ball.Parent = model |
| 1203 | end |
| 1204 | end |
| 1205 | do |
| 1206 | local upV = Vector3.new(0,1,0).Unit |
| 1207 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1208 | local forwardV = rightV:Cross(upV) |
| 1209 | local pos = Vector3.new(3.5, 8.16, -15) |
| 1210 | local ball = Instance.new("Part") |
| 1211 | ball.Shape = Enum.PartType.Ball |
| 1212 | ball.Size = Vector3.new(2, 2, 2) |
| 1213 | ball.CFrame = CFrame.new(pos) |
| 1214 | ball.BrickColor = BrickColor.new("Bright yellow") |
| 1215 | ball.Material = Enum.Material.Glacier |
| 1216 | ball.MaterialVariant = "2022 Stud" |
| 1217 | ball.Anchored = true; ball.Parent = workspace |
| 1218 | local cuts = {} |
| 1219 | do |
| 1220 | local h = 0 |
| 1221 | local cut = Instance.new("Part") |
| 1222 | cut.Size = Vector3.new(4, 4, 4) |
| 1223 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-2), rightV, upV) |
| 1224 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 1225 | cut.Material = Enum.Material.Glacier |
| 1226 | cut.MaterialVariant = "2022 Stud" |
| 1227 | cut.Anchored = true; cut.Parent = workspace |
| 1228 | table.insert(cuts, cut) |
| 1229 | end |
| 1230 | if #cuts > 0 then |
| 1231 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1232 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1233 | if ok and result then |
| 1234 | ball:Destroy() |
| 1235 | result.Name = "Z4_DomeR"; result.Anchored = true; result.Parent = model |
| 1236 | else |
| 1237 | ball.Name = "Z4_DomeR"; ball.Parent = model |
| 1238 | end |
| 1239 | else |
| 1240 | ball.Name = "Z4_DomeR"; ball.Parent = model |
| 1241 | end |
| 1242 | end |
| 1243 | do |
| 1244 | local upV = Vector3.new(0,1,0).Unit |
| 1245 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1246 | local forwardV = rightV:Cross(upV) |
| 1247 | local pos = Vector3.new(0, 7.08, -28) |
| 1248 | local ball = Instance.new("Part") |
| 1249 | ball.Shape = Enum.PartType.Ball |
| 1250 | ball.Size = Vector3.new(5, 5, 5) |
| 1251 | ball.CFrame = CFrame.new(pos) |
| 1252 | ball.BrickColor = BrickColor.new("Bright yellow") |
| 1253 | ball.Material = Enum.Material.Glacier |
| 1254 | ball.MaterialVariant = "2022 Stud" |
| 1255 | ball.Anchored = true; ball.Parent = workspace |
| 1256 | local cuts = {} |
| 1257 | do |
| 1258 | local h = 0 |
| 1259 | local cut = Instance.new("Part") |
| 1260 | cut.Size = Vector3.new(10, 10, 10) |
| 1261 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-5), rightV, upV) |
| 1262 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 1263 | cut.Material = Enum.Material.Glacier |
| 1264 | cut.MaterialVariant = "2022 Stud" |
| 1265 | cut.Anchored = true; cut.Parent = workspace |
| 1266 | table.insert(cuts, cut) |
| 1267 | end |
| 1268 | if #cuts > 0 then |
| 1269 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1270 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1271 | if ok and result then |
| 1272 | ball:Destroy() |
| 1273 | result.Name = "Z5_TempleDome"; result.Anchored = true; result.Parent = model |
| 1274 | else |
| 1275 | ball.Name = "Z5_TempleDome"; ball.Parent = model |
| 1276 | end |
| 1277 | else |
| 1278 | ball.Name = "Z5_TempleDome"; ball.Parent = model |
| 1279 | end |
| 1280 | end |
| 1281 | do |
| 1282 | local upV = Vector3.new(0,1,0).Unit |
| 1283 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1284 | local forwardV = rightV:Cross(upV) |
| 1285 | local pos = Vector3.new(-3.5, 7.16, -28) |
| 1286 | local ball = Instance.new("Part") |
| 1287 | ball.Shape = Enum.PartType.Ball |
| 1288 | ball.Size = Vector3.new(2, 2, 2) |
| 1289 | ball.CFrame = CFrame.new(pos) |
| 1290 | ball.BrickColor = BrickColor.new("Bright yellow") |
| 1291 | ball.Material = Enum.Material.Glacier |
| 1292 | ball.MaterialVariant = "2022 Stud" |
| 1293 | ball.Anchored = true; ball.Parent = workspace |
| 1294 | local cuts = {} |
| 1295 | do |
| 1296 | local h = 0 |
| 1297 | local cut = Instance.new("Part") |
| 1298 | cut.Size = Vector3.new(4, 4, 4) |
| 1299 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-2), rightV, upV) |
| 1300 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 1301 | cut.Material = Enum.Material.Glacier |
| 1302 | cut.MaterialVariant = "2022 Stud" |
| 1303 | cut.Anchored = true; cut.Parent = workspace |
| 1304 | table.insert(cuts, cut) |
| 1305 | end |
| 1306 | if #cuts > 0 then |
| 1307 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1308 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1309 | if ok and result then |
| 1310 | ball:Destroy() |
| 1311 | result.Name = "Z5_TowerDomeL"; result.Anchored = true; result.Parent = model |
| 1312 | else |
| 1313 | ball.Name = "Z5_TowerDomeL"; ball.Parent = model |
| 1314 | end |
| 1315 | else |
| 1316 | ball.Name = "Z5_TowerDomeL"; ball.Parent = model |
| 1317 | end |
| 1318 | end |
| 1319 | do |
| 1320 | local upV = Vector3.new(0,1,0).Unit |
| 1321 | local rightV = (Vector3.new(1,0,0) - Vector3.new(1,0,0):Dot(upV)*upV).Unit |
| 1322 | local forwardV = rightV:Cross(upV) |
| 1323 | local pos = Vector3.new(3.5, 7.16, -28) |
| 1324 | local ball = Instance.new("Part") |
| 1325 | ball.Shape = Enum.PartType.Ball |
| 1326 | ball.Size = Vector3.new(2, 2, 2) |
| 1327 | ball.CFrame = CFrame.new(pos) |
| 1328 | ball.BrickColor = BrickColor.new("Bright yellow") |
| 1329 | ball.Material = Enum.Material.Glacier |
| 1330 | ball.MaterialVariant = "2022 Stud" |
| 1331 | ball.Anchored = true; ball.Parent = workspace |
| 1332 | local cuts = {} |
| 1333 | do |
| 1334 | local h = 0 |
| 1335 | local cut = Instance.new("Part") |
| 1336 | cut.Size = Vector3.new(4, 4, 4) |
| 1337 | cut.CFrame = CFrame.fromMatrix(pos + upV*(-2), rightV, upV) |
| 1338 | cut.BrickColor = BrickColor.new("Bright yellow") |
| 1339 | cut.Material = Enum.Material.Glacier |
| 1340 | cut.MaterialVariant = "2022 Stud" |
| 1341 | cut.Anchored = true; cut.Parent = workspace |
| 1342 | table.insert(cuts, cut) |
| 1343 | end |
| 1344 | if #cuts > 0 then |
| 1345 | local ok, result = pcall(function() return ball:SubtractAsync(cuts) end) |
| 1346 | for _, c in ipairs(cuts) do c:Destroy() end |
| 1347 | if ok and result then |
| 1348 | ball:Destroy() |
| 1349 | result.Name = "Z5_TowerDomeR"; result.Anchored = true; result.Parent = model |
| 1350 | else |
| 1351 | ball.Name = "Z5_TowerDomeR"; ball.Parent = model |
| 1352 | end |
| 1353 | else |
| 1354 | ball.Name = "Z5_TowerDomeR"; ball.Parent = model |
| 1355 | end |
| 1356 | end |
| 1357 | model.PrimaryPart = model:FindFirstChild("Z1_Path") |
| 1358 | print("ChocolateSmashRunMap built: " .. #model:GetChildren() .. " parts") |
Loading comments...