Loading model...
by Matheus · 6/2/2026
Lua Script
| 1 | -- Generated with StudForge.org | AI-powered 3D models for Roblox |
| 2 | -- Model: Chameleon |
| 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 = "Chameleon" |
| 21 | model.Parent = workspace |
| 22 | |
| 23 | local variants = { |
| 24 | ["Bright green"] = "2022 Stud", |
| 25 | ["Dark green"] = "2022 Stud", |
| 26 | ["Institutional white"] = "2022 Stud", |
| 27 | ["Really black"] = "2022 Universal", |
| 28 | } |
| 29 | do |
| 30 | local p = Instance.new("Part") |
| 31 | p.Name = "Body" |
| 32 | p.Size = Vector3.new(4, 4, 5) |
| 33 | p.CFrame = CFrame.new(0, 5, 0.04) |
| 34 | p.BrickColor = BrickColor.new("Bright green") |
| 35 | p.Material = Enum.Material.Glacier |
| 36 | p.MaterialVariant = "2022 Stud" |
| 37 | p.Anchored = true |
| 38 | p.Parent = model |
| 39 | end |
| 40 | do |
| 41 | local p = Instance.new("Part") |
| 42 | p.Name = "Spot1" |
| 43 | p.Size = Vector3.new(0.1, 1, 1.5) |
| 44 | p.CFrame = CFrame.new(2.09, 5.5, 0) |
| 45 | p.BrickColor = BrickColor.new("Dark green") |
| 46 | p.Material = Enum.Material.Glacier |
| 47 | p.MaterialVariant = "2022 Stud" |
| 48 | p.Anchored = true |
| 49 | p.Parent = model |
| 50 | end |
| 51 | do |
| 52 | local p = Instance.new("Part") |
| 53 | p.Name = "Spot2" |
| 54 | p.Size = Vector3.new(0.1, 0.8, 1) |
| 55 | p.CFrame = CFrame.new(2.09, 4.5, 1.5) |
| 56 | p.BrickColor = BrickColor.new("Dark green") |
| 57 | p.Material = Enum.Material.Glacier |
| 58 | p.MaterialVariant = "2022 Stud" |
| 59 | p.Anchored = true |
| 60 | p.Parent = model |
| 61 | end |
| 62 | do |
| 63 | local p = Instance.new("Part") |
| 64 | p.Name = "Spot3" |
| 65 | p.Size = Vector3.new(0.1, 1, 1.5) |
| 66 | p.CFrame = CFrame.new(-2.09, 5.5, 0) |
| 67 | p.BrickColor = BrickColor.new("Dark green") |
| 68 | p.Material = Enum.Material.Glacier |
| 69 | p.MaterialVariant = "2022 Stud" |
| 70 | p.Anchored = true |
| 71 | p.Parent = model |
| 72 | end |
| 73 | do |
| 74 | local p = Instance.new("Part") |
| 75 | p.Name = "Spot4" |
| 76 | p.Size = Vector3.new(0.1, 0.8, 1) |
| 77 | p.CFrame = CFrame.new(-2.09, 4.5, 1.5) |
| 78 | p.BrickColor = BrickColor.new("Dark green") |
| 79 | p.Material = Enum.Material.Glacier |
| 80 | p.MaterialVariant = "2022 Stud" |
| 81 | p.Anchored = true |
| 82 | p.Parent = model |
| 83 | end |
| 84 | do |
| 85 | local p = Instance.new("Part") |
| 86 | p.Name = "Head" |
| 87 | p.Size = Vector3.new(4.5, 4.5, 4) |
| 88 | p.CFrame = CFrame.new(0, 5.5, -4.5) |
| 89 | p.BrickColor = BrickColor.new("Bright green") |
| 90 | p.Material = Enum.Material.Glacier |
| 91 | p.MaterialVariant = "2022 Stud" |
| 92 | p.Anchored = true |
| 93 | p.Parent = model |
| 94 | end |
| 95 | do |
| 96 | local p = Instance.new("WedgePart") |
| 97 | p.Name = "Crest" |
| 98 | p.Size = Vector3.new(0.6, 2, 2) |
| 99 | p.CFrame = CFrame.new(0, 8.79, -4) * CFrame.Angles(math.rad(0), math.rad(180), math.rad(0)) |
| 100 | p.BrickColor = BrickColor.new("Bright green") |
| 101 | p.Material = Enum.Material.Glacier |
| 102 | p.MaterialVariant = "2022 Stud" |
| 103 | p.Anchored = true |
| 104 | p.Parent = model |
| 105 | end |
| 106 | do |
| 107 | local p = Instance.new("Part") |
| 108 | p.Name = "Snout" |
| 109 | p.Size = Vector3.new(3.5, 2, 2.5) |
| 110 | p.CFrame = CFrame.new(0, 5, -7.79) |
| 111 | p.BrickColor = BrickColor.new("Bright green") |
| 112 | p.Material = Enum.Material.Glacier |
| 113 | p.MaterialVariant = "2022 Stud" |
| 114 | p.Anchored = true |
| 115 | p.Parent = model |
| 116 | end |
| 117 | do |
| 118 | local p = Instance.new("Part") |
| 119 | p.Name = "Jaw" |
| 120 | p.Size = Vector3.new(3.3, 0.5, 2.3) |
| 121 | p.CFrame = CFrame.new(0, 3.71, -7.55) |
| 122 | p.BrickColor = BrickColor.new("Bright green") |
| 123 | p.Material = Enum.Material.Glacier |
| 124 | p.MaterialVariant = "2022 Stud" |
| 125 | p.Anchored = true |
| 126 | p.Parent = model |
| 127 | end |
| 128 | do |
| 129 | local p = Instance.new("Part") |
| 130 | p.Name = "NostrilL" |
| 131 | p.Size = Vector3.new(0.4, 0.4, 0.1) |
| 132 | p.CFrame = CFrame.new(0.95, 5, -9.13) |
| 133 | p.BrickColor = BrickColor.new("Dark green") |
| 134 | p.Material = Enum.Material.Glacier |
| 135 | p.MaterialVariant = "2022 Stud" |
| 136 | p.Anchored = true |
| 137 | p.Parent = model |
| 138 | end |
| 139 | do |
| 140 | local p = Instance.new("Part") |
| 141 | p.Name = "NostrilR" |
| 142 | p.Size = Vector3.new(0.4, 0.4, 0.1) |
| 143 | p.CFrame = CFrame.new(-0.95, 5, -9.13) |
| 144 | p.BrickColor = BrickColor.new("Dark green") |
| 145 | p.Material = Enum.Material.Glacier |
| 146 | p.MaterialVariant = "2022 Stud" |
| 147 | p.Anchored = true |
| 148 | p.Parent = model |
| 149 | end |
| 150 | do |
| 151 | local p = Instance.new("Part") |
| 152 | p.Name = "EyeWhiteL" |
| 153 | p.Size = Vector3.new(0.2, 1.5, 1.5) |
| 154 | p.CFrame = CFrame.new(2.43, 6, -5.5) |
| 155 | p.BrickColor = BrickColor.new("Institutional white") |
| 156 | p.Material = Enum.Material.Glacier |
| 157 | p.MaterialVariant = "2022 Stud" |
| 158 | p.Anchored = true |
| 159 | p.Parent = model |
| 160 | end |
| 161 | do |
| 162 | local p = Instance.new("Part") |
| 163 | p.Name = "EyePupilL" |
| 164 | p.Size = Vector3.new(0.1, 0.6, 0.6) |
| 165 | p.CFrame = CFrame.new(2.45, 6, -5.5) |
| 166 | p.BrickColor = BrickColor.new("Really black") |
| 167 | p.Material = Enum.Material.Glacier |
| 168 | p.MaterialVariant = "2022 Universal" |
| 169 | p.Anchored = true |
| 170 | p.Parent = model |
| 171 | end |
| 172 | do |
| 173 | local p = Instance.new("Part") |
| 174 | p.Name = "EyeWhiteR" |
| 175 | p.Size = Vector3.new(0.2, 1.5, 1.5) |
| 176 | p.CFrame = CFrame.new(-2.43, 6, -5.5) |
| 177 | p.BrickColor = BrickColor.new("Institutional white") |
| 178 | p.Material = Enum.Material.Glacier |
| 179 | p.MaterialVariant = "2022 Stud" |
| 180 | p.Anchored = true |
| 181 | p.Parent = model |
| 182 | end |
| 183 | do |
| 184 | local p = Instance.new("Part") |
| 185 | p.Name = "EyePupilR" |
| 186 | p.Size = Vector3.new(0.1, 0.6, 0.6) |
| 187 | p.CFrame = CFrame.new(-2.45, 6, -5.5) |
| 188 | p.BrickColor = BrickColor.new("Really black") |
| 189 | p.Material = Enum.Material.Glacier |
| 190 | p.MaterialVariant = "2022 Universal" |
| 191 | p.Anchored = true |
| 192 | p.Parent = model |
| 193 | end |
| 194 | do |
| 195 | local p = Instance.new("Part") |
| 196 | p.Name = "LegFL" |
| 197 | p.Size = Vector3.new(1.2, 3.5, 1.2) |
| 198 | p.CFrame = CFrame.new(2.2, 1.75, -1.5) * CFrame.Angles(math.rad(10), math.rad(0), math.rad(0)) |
| 199 | p.BrickColor = BrickColor.new("Bright green") |
| 200 | p.Material = Enum.Material.Glacier |
| 201 | p.MaterialVariant = "2022 Stud" |
| 202 | p.Anchored = true |
| 203 | p.Parent = model |
| 204 | end |
| 205 | do |
| 206 | local p = Instance.new("Part") |
| 207 | p.Name = "FootFL" |
| 208 | p.Size = Vector3.new(1.6, 0.8, 2) |
| 209 | p.CFrame = CFrame.new(2.2, 0.4, -2) |
| 210 | p.BrickColor = BrickColor.new("Bright green") |
| 211 | p.Material = Enum.Material.Glacier |
| 212 | p.MaterialVariant = "2022 Stud" |
| 213 | p.Anchored = true |
| 214 | p.Parent = model |
| 215 | end |
| 216 | do |
| 217 | local p = Instance.new("Part") |
| 218 | p.Name = "ToeFL1" |
| 219 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 220 | p.CFrame = CFrame.new(1.9, 0.4, -3.13) |
| 221 | p.BrickColor = BrickColor.new("Dark green") |
| 222 | p.Material = Enum.Material.Glacier |
| 223 | p.MaterialVariant = "2022 Stud" |
| 224 | p.Anchored = true |
| 225 | p.Parent = model |
| 226 | end |
| 227 | do |
| 228 | local p = Instance.new("Part") |
| 229 | p.Name = "ToeFL2" |
| 230 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 231 | p.CFrame = CFrame.new(2.5, 0.4, -3.13) |
| 232 | p.BrickColor = BrickColor.new("Dark green") |
| 233 | p.Material = Enum.Material.Glacier |
| 234 | p.MaterialVariant = "2022 Stud" |
| 235 | p.Anchored = true |
| 236 | p.Parent = model |
| 237 | end |
| 238 | do |
| 239 | local p = Instance.new("Part") |
| 240 | p.Name = "LegFR" |
| 241 | p.Size = Vector3.new(1.2, 3.5, 1.2) |
| 242 | p.CFrame = CFrame.new(-2.2, 1.75, -1.5) * CFrame.Angles(math.rad(10), math.rad(0), math.rad(0)) |
| 243 | p.BrickColor = BrickColor.new("Bright green") |
| 244 | p.Material = Enum.Material.Glacier |
| 245 | p.MaterialVariant = "2022 Stud" |
| 246 | p.Anchored = true |
| 247 | p.Parent = model |
| 248 | end |
| 249 | do |
| 250 | local p = Instance.new("Part") |
| 251 | p.Name = "FootFR" |
| 252 | p.Size = Vector3.new(1.6, 0.8, 2) |
| 253 | p.CFrame = CFrame.new(-2.2, 0.4, -2) |
| 254 | p.BrickColor = BrickColor.new("Bright green") |
| 255 | p.Material = Enum.Material.Glacier |
| 256 | p.MaterialVariant = "2022 Stud" |
| 257 | p.Anchored = true |
| 258 | p.Parent = model |
| 259 | end |
| 260 | do |
| 261 | local p = Instance.new("Part") |
| 262 | p.Name = "ToeFR1" |
| 263 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 264 | p.CFrame = CFrame.new(-2.5, 0.4, -3.13) |
| 265 | p.BrickColor = BrickColor.new("Dark green") |
| 266 | p.Material = Enum.Material.Glacier |
| 267 | p.MaterialVariant = "2022 Stud" |
| 268 | p.Anchored = true |
| 269 | p.Parent = model |
| 270 | end |
| 271 | do |
| 272 | local p = Instance.new("Part") |
| 273 | p.Name = "ToeFR2" |
| 274 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 275 | p.CFrame = CFrame.new(-1.9, 0.4, -3.13) |
| 276 | p.BrickColor = BrickColor.new("Dark green") |
| 277 | p.Material = Enum.Material.Glacier |
| 278 | p.MaterialVariant = "2022 Stud" |
| 279 | p.Anchored = true |
| 280 | p.Parent = model |
| 281 | end |
| 282 | do |
| 283 | local p = Instance.new("Part") |
| 284 | p.Name = "LegBL" |
| 285 | p.Size = Vector3.new(1.2, 3.5, 1.2) |
| 286 | p.CFrame = CFrame.new(2.2, 1.75, 1.5) * CFrame.Angles(math.rad(-10), math.rad(0), math.rad(0)) |
| 287 | p.BrickColor = BrickColor.new("Bright green") |
| 288 | p.Material = Enum.Material.Glacier |
| 289 | p.MaterialVariant = "2022 Stud" |
| 290 | p.Anchored = true |
| 291 | p.Parent = model |
| 292 | end |
| 293 | do |
| 294 | local p = Instance.new("Part") |
| 295 | p.Name = "FootBL" |
| 296 | p.Size = Vector3.new(1.6, 0.8, 2) |
| 297 | p.CFrame = CFrame.new(2.2, 0.4, 1) |
| 298 | p.BrickColor = BrickColor.new("Bright green") |
| 299 | p.Material = Enum.Material.Glacier |
| 300 | p.MaterialVariant = "2022 Stud" |
| 301 | p.Anchored = true |
| 302 | p.Parent = model |
| 303 | end |
| 304 | do |
| 305 | local p = Instance.new("Part") |
| 306 | p.Name = "ToeBL1" |
| 307 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 308 | p.CFrame = CFrame.new(1.9, 0.4, -0.13) |
| 309 | p.BrickColor = BrickColor.new("Dark green") |
| 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 = "ToeBL2" |
| 318 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 319 | p.CFrame = CFrame.new(2.5, 0.4, -0.13) |
| 320 | p.BrickColor = BrickColor.new("Dark 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 = "LegBR" |
| 329 | p.Size = Vector3.new(1.2, 3.5, 1.2) |
| 330 | p.CFrame = CFrame.new(-2.2, 1.75, 1.5) * CFrame.Angles(math.rad(-10), math.rad(0), math.rad(0)) |
| 331 | p.BrickColor = BrickColor.new("Bright green") |
| 332 | p.Material = Enum.Material.Glacier |
| 333 | p.MaterialVariant = "2022 Stud" |
| 334 | p.Anchored = true |
| 335 | p.Parent = model |
| 336 | end |
| 337 | do |
| 338 | local p = Instance.new("Part") |
| 339 | p.Name = "FootBR" |
| 340 | p.Size = Vector3.new(1.6, 0.8, 2) |
| 341 | p.CFrame = CFrame.new(-2.2, 0.4, 1) |
| 342 | p.BrickColor = BrickColor.new("Bright green") |
| 343 | p.Material = Enum.Material.Glacier |
| 344 | p.MaterialVariant = "2022 Stud" |
| 345 | p.Anchored = true |
| 346 | p.Parent = model |
| 347 | end |
| 348 | do |
| 349 | local p = Instance.new("Part") |
| 350 | p.Name = "ToeBR1" |
| 351 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 352 | p.CFrame = CFrame.new(-2.5, 0.4, -0.13) |
| 353 | p.BrickColor = BrickColor.new("Dark 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 = "ToeBR2" |
| 362 | p.Size = Vector3.new(0.2, 0.8, 0.1) |
| 363 | p.CFrame = CFrame.new(-1.9, 0.4, -0.13) |
| 364 | p.BrickColor = BrickColor.new("Dark 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.Shape = Enum.PartType.Cylinder |
| 373 | p.Name = "TailCenter" |
| 374 | p.Size = Vector3.new(1.5, 1, 1) |
| 375 | p.CFrame = CFrame.new(0, 5, 4) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(90)) |
| 376 | p.BrickColor = BrickColor.new("Bright green") |
| 377 | p.Material = Enum.Material.Glacier |
| 378 | p.MaterialVariant = "2022 Stud" |
| 379 | p.Anchored = true |
| 380 | p.Parent = model |
| 381 | end |
| 382 | do |
| 383 | local rightV = Vector3.new(0,0,1).Unit |
| 384 | local upV = (Vector3.new(0,1,0) - Vector3.new(0,1,0):Dot(rightV)*rightV).Unit |
| 385 | local normalV = upV:Cross(rightV) |
| 386 | local pos = Vector3.new(0, 5, 4) |
| 387 | local cyl = Instance.new("Part") |
| 388 | cyl.Shape = Enum.PartType.Cylinder |
| 389 | cyl.Size = Vector3.new(1.5, 5, 5) |
| 390 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 391 | cyl.BrickColor = BrickColor.new("Bright green") |
| 392 | cyl.Material = Enum.Material.Glacier |
| 393 | cyl.MaterialVariant = "2022 Stud" |
| 394 | cyl.Anchored = true; cyl.Parent = workspace |
| 395 | local cuts = {} |
| 396 | local hole = Instance.new("Part") |
| 397 | hole.Shape = Enum.PartType.Cylinder |
| 398 | hole.Size = Vector3.new(1.7, 3, 3) |
| 399 | hole.CFrame = cyl.CFrame |
| 400 | hole.BrickColor = BrickColor.new("Bright green") |
| 401 | hole.Material = Enum.Material.Glacier |
| 402 | hole.MaterialVariant = "2022 Stud" |
| 403 | hole.Anchored = true; hole.Parent = workspace |
| 404 | table.insert(cuts, hole) |
| 405 | local angBoxes = {} |
| 406 | do |
| 407 | local edgeDir = 1*rightV + 0*upV |
| 408 | local edgePerp = 0*rightV + 1*upV |
| 409 | local cut = Instance.new("Part") |
| 410 | cut.Size = Vector3.new(10, 1.7, 10) |
| 411 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 5 * edgePerp, edgeDir, normalV) |
| 412 | cut.BrickColor = BrickColor.new("Bright green") |
| 413 | cut.Material = Enum.Material.Glacier |
| 414 | cut.MaterialVariant = "2022 Stud" |
| 415 | cut.Anchored = true; cut.Parent = workspace |
| 416 | table.insert(angBoxes, cut) |
| 417 | end |
| 418 | do |
| 419 | local edgeDir = -1*rightV + 0*upV |
| 420 | local edgePerp = 0*rightV + -1*upV |
| 421 | local cut = Instance.new("Part") |
| 422 | cut.Size = Vector3.new(10, 1.7, 10) |
| 423 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 5 * edgePerp, edgeDir, normalV) |
| 424 | cut.BrickColor = BrickColor.new("Bright green") |
| 425 | cut.Material = Enum.Material.Glacier |
| 426 | cut.MaterialVariant = "2022 Stud" |
| 427 | cut.Anchored = true; cut.Parent = workspace |
| 428 | table.insert(angBoxes, cut) |
| 429 | end |
| 430 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 431 | if #cuts > 0 then |
| 432 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 433 | for _, c in ipairs(cuts) do c:Destroy() end |
| 434 | if ok and result then |
| 435 | cyl:Destroy() |
| 436 | result.Name = "Tail1"; result.Anchored = true; result.Parent = model |
| 437 | else |
| 438 | cyl.Name = "Tail1"; cyl.Parent = model |
| 439 | end |
| 440 | else |
| 441 | cyl.Name = "Tail1"; cyl.Parent = model |
| 442 | end |
| 443 | end |
| 444 | do |
| 445 | local rightV = Vector3.new(0,0,-1).Unit |
| 446 | local upV = (Vector3.new(0,-1,0) - Vector3.new(0,-1,0):Dot(rightV)*rightV).Unit |
| 447 | local normalV = upV:Cross(rightV) |
| 448 | local pos = Vector3.new(0, 5, 4) |
| 449 | local cyl = Instance.new("Part") |
| 450 | cyl.Shape = Enum.PartType.Cylinder |
| 451 | cyl.Size = Vector3.new(1.5, 3, 3) |
| 452 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 453 | cyl.BrickColor = BrickColor.new("Bright green") |
| 454 | cyl.Material = Enum.Material.Glacier |
| 455 | cyl.MaterialVariant = "2022 Stud" |
| 456 | cyl.Anchored = true; cyl.Parent = workspace |
| 457 | local cuts = {} |
| 458 | local hole = Instance.new("Part") |
| 459 | hole.Shape = Enum.PartType.Cylinder |
| 460 | hole.Size = Vector3.new(1.7, 1, 1) |
| 461 | hole.CFrame = cyl.CFrame |
| 462 | hole.BrickColor = BrickColor.new("Bright green") |
| 463 | hole.Material = Enum.Material.Glacier |
| 464 | hole.MaterialVariant = "2022 Stud" |
| 465 | hole.Anchored = true; hole.Parent = workspace |
| 466 | table.insert(cuts, hole) |
| 467 | local angBoxes = {} |
| 468 | do |
| 469 | local edgeDir = 1*rightV + 0*upV |
| 470 | local edgePerp = 0*rightV + 1*upV |
| 471 | local cut = Instance.new("Part") |
| 472 | cut.Size = Vector3.new(6, 1.7, 6) |
| 473 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 3 * edgePerp, edgeDir, normalV) |
| 474 | cut.BrickColor = BrickColor.new("Bright green") |
| 475 | cut.Material = Enum.Material.Glacier |
| 476 | cut.MaterialVariant = "2022 Stud" |
| 477 | cut.Anchored = true; cut.Parent = workspace |
| 478 | table.insert(angBoxes, cut) |
| 479 | end |
| 480 | do |
| 481 | local edgeDir = -1*rightV + 0*upV |
| 482 | local edgePerp = 0*rightV + -1*upV |
| 483 | local cut = Instance.new("Part") |
| 484 | cut.Size = Vector3.new(6, 1.7, 6) |
| 485 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 3 * edgePerp, edgeDir, normalV) |
| 486 | cut.BrickColor = BrickColor.new("Bright green") |
| 487 | cut.Material = Enum.Material.Glacier |
| 488 | cut.MaterialVariant = "2022 Stud" |
| 489 | cut.Anchored = true; cut.Parent = workspace |
| 490 | table.insert(angBoxes, cut) |
| 491 | end |
| 492 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 493 | if #cuts > 0 then |
| 494 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 495 | for _, c in ipairs(cuts) do c:Destroy() end |
| 496 | if ok and result then |
| 497 | cyl:Destroy() |
| 498 | result.Name = "Tail2"; result.Anchored = true; result.Parent = model |
| 499 | else |
| 500 | cyl.Name = "Tail2"; cyl.Parent = model |
| 501 | end |
| 502 | else |
| 503 | cyl.Name = "Tail2"; cyl.Parent = model |
| 504 | end |
| 505 | end |
| 506 | model.PrimaryPart = model:FindFirstChild("Body") |
| 507 | print("Chameleon built: " .. #model:GetChildren() .. " parts") |
Loading comments...