Loading model...
by Mert · 3/26/2026
Lua Script
| 1 | -- Generated with StudForge.org | AI-powered 3D models for Roblox |
| 2 | -- Model: OceanWave |
| 3 | |
| 4 | -- Generated with StudForge.org | AI-powered 3D models for Roblox |
| 5 | -- Model: OceanWave |
| 6 | |
| 7 | local MS = game:GetService("MaterialService") |
| 8 | |
| 9 | local ok, roots = pcall(game.GetObjects, game, "rbxassetid://13386676607") |
| 10 | if not ok then return warn(roots) end |
| 11 | |
| 12 | local tmp = Instance.new("Folder") |
| 13 | for _, r in ipairs(roots) do r.Parent = tmp end |
| 14 | |
| 15 | for _, d in ipairs(tmp:GetDescendants()) do |
| 16 | if d:IsA("MaterialVariant") then |
| 17 | d.Parent = MS |
| 18 | end |
| 19 | end |
| 20 | tmp:Destroy() |
| 21 | |
| 22 | local model = Instance.new("Model") |
| 23 | model.Name = "OceanWave" |
| 24 | model.Parent = workspace |
| 25 | |
| 26 | local variants = { |
| 27 | ["Earth blue"] = "2022 Stud", |
| 28 | ["Electric blue"] = "2022 Stud", |
| 29 | ["Institutional white"] = "2022 Stud", |
| 30 | ["Storm blue"] = "2022 Stud", |
| 31 | } |
| 32 | do |
| 33 | local p = Instance.new("Part") |
| 34 | p.Name = "LowerBody_Dark" |
| 35 | p.Size = Vector3.new(6, 3, 2) |
| 36 | p.CFrame = CFrame.new(5.04, 1.5, 0) |
| 37 | p.BrickColor = BrickColor.new("Earth blue") |
| 38 | p.Material = Enum.Material.Glacier |
| 39 | p.MaterialVariant = "2022 Stud" |
| 40 | p.Anchored = true |
| 41 | p.Parent = model |
| 42 | end |
| 43 | do |
| 44 | local p = Instance.new("Part") |
| 45 | p.Name = "LowerBody_Dark2" |
| 46 | p.Size = Vector3.new(4, 2, 2) |
| 47 | p.CFrame = CFrame.new(9, 0.96, -0.04) |
| 48 | p.BrickColor = BrickColor.new("Earth blue") |
| 49 | p.Material = Enum.Material.Glacier |
| 50 | p.MaterialVariant = "2022 Stud" |
| 51 | p.Anchored = true |
| 52 | p.Parent = model |
| 53 | end |
| 54 | do |
| 55 | local p = Instance.new("Part") |
| 56 | p.Name = "LeftTail_Dark" |
| 57 | p.Size = Vector3.new(4, 3, 2) |
| 58 | p.CFrame = CFrame.new(-3, 1.5, 0.08) |
| 59 | p.BrickColor = BrickColor.new("Earth blue") |
| 60 | p.Material = Enum.Material.Glacier |
| 61 | p.MaterialVariant = "2022 Stud" |
| 62 | p.Anchored = true |
| 63 | p.Parent = model |
| 64 | end |
| 65 | do |
| 66 | local p = Instance.new("Part") |
| 67 | p.Name = "LeftTail_Dark2" |
| 68 | p.Size = Vector3.new(3, 2, 2) |
| 69 | p.CFrame = CFrame.new(-6, 0.96, 0.12) |
| 70 | p.BrickColor = BrickColor.new("Earth blue") |
| 71 | p.Material = Enum.Material.Glacier |
| 72 | p.MaterialVariant = "2022 Stud" |
| 73 | p.Anchored = true |
| 74 | p.Parent = model |
| 75 | end |
| 76 | do |
| 77 | local p = Instance.new("Part") |
| 78 | p.Name = "LowerBody_Mid" |
| 79 | p.Size = Vector3.new(5, 2, 2.2) |
| 80 | p.CFrame = CFrame.new(5, 2.04, 0.14) |
| 81 | p.BrickColor = BrickColor.new("Storm blue") |
| 82 | p.Material = Enum.Material.Glacier |
| 83 | p.MaterialVariant = "2022 Stud" |
| 84 | p.Anchored = true |
| 85 | p.Parent = model |
| 86 | end |
| 87 | do |
| 88 | local p = Instance.new("Part") |
| 89 | p.Name = "LowerBody_Mid2" |
| 90 | p.Size = Vector3.new(3, 1, 2.2) |
| 91 | p.CFrame = CFrame.new(8.46, 1.5, 0.18) |
| 92 | p.BrickColor = BrickColor.new("Storm blue") |
| 93 | p.Material = Enum.Material.Glacier |
| 94 | p.MaterialVariant = "2022 Stud" |
| 95 | p.Anchored = true |
| 96 | p.Parent = model |
| 97 | end |
| 98 | do |
| 99 | local p = Instance.new("Part") |
| 100 | p.Name = "LeftTail_Mid" |
| 101 | p.Size = Vector3.new(3, 2, 2.2) |
| 102 | p.CFrame = CFrame.new(-2.46, 2.04, 0.26) |
| 103 | p.BrickColor = BrickColor.new("Storm blue") |
| 104 | p.Material = Enum.Material.Glacier |
| 105 | p.MaterialVariant = "2022 Stud" |
| 106 | p.Anchored = true |
| 107 | p.Parent = model |
| 108 | end |
| 109 | do |
| 110 | local p = Instance.new("Part") |
| 111 | p.Name = "LowerCrest_Light1" |
| 112 | p.Size = Vector3.new(2, 1, 2.4) |
| 113 | p.CFrame = CFrame.new(5.5, 3.5, 0.28) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(20)) |
| 114 | p.BrickColor = BrickColor.new("Electric blue") |
| 115 | p.Material = Enum.Material.Glacier |
| 116 | p.MaterialVariant = "2022 Stud" |
| 117 | p.Anchored = true |
| 118 | p.Parent = model |
| 119 | end |
| 120 | do |
| 121 | local p = Instance.new("Part") |
| 122 | p.Name = "LowerCrest_Light2" |
| 123 | p.Size = Vector3.new(2, 1, 2.4) |
| 124 | p.CFrame = CFrame.new(7.5, 2.5, 0.32) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-15)) |
| 125 | p.BrickColor = BrickColor.new("Electric blue") |
| 126 | p.Material = Enum.Material.Glacier |
| 127 | p.MaterialVariant = "2022 Stud" |
| 128 | p.Anchored = true |
| 129 | p.Parent = model |
| 130 | end |
| 131 | do |
| 132 | local p = Instance.new("Part") |
| 133 | p.Name = "Foam_Main" |
| 134 | p.Size = Vector3.new(6, 2.5, 2.6) |
| 135 | p.CFrame = CFrame.new(2, 11, 0.38) |
| 136 | p.BrickColor = BrickColor.new("Institutional white") |
| 137 | p.Material = Enum.Material.Glacier |
| 138 | p.MaterialVariant = "2022 Stud" |
| 139 | p.Anchored = true |
| 140 | p.Parent = model |
| 141 | end |
| 142 | do |
| 143 | local p = Instance.new("Part") |
| 144 | p.Name = "Foam_Left" |
| 145 | p.Size = Vector3.new(3, 2, 2.6) |
| 146 | p.CFrame = CFrame.new(-1, 10, 0.46) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(30)) |
| 147 | p.BrickColor = BrickColor.new("Institutional white") |
| 148 | p.Material = Enum.Material.Glacier |
| 149 | p.MaterialVariant = "2022 Stud" |
| 150 | p.Anchored = true |
| 151 | p.Parent = model |
| 152 | end |
| 153 | do |
| 154 | local p = Instance.new("Part") |
| 155 | p.Name = "Foam_Right" |
| 156 | p.Size = Vector3.new(3, 2.5, 2.6) |
| 157 | p.CFrame = CFrame.new(5, 9.5, 0.46) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-20)) |
| 158 | p.BrickColor = BrickColor.new("Institutional white") |
| 159 | p.Material = Enum.Material.Glacier |
| 160 | p.MaterialVariant = "2022 Stud" |
| 161 | p.Anchored = true |
| 162 | p.Parent = model |
| 163 | end |
| 164 | do |
| 165 | local p = Instance.new("Part") |
| 166 | p.Name = "Foam_CurlTip" |
| 167 | p.Size = Vector3.new(2, 2, 2.6) |
| 168 | p.CFrame = CFrame.new(5.5, 7.5, 0.26) |
| 169 | p.BrickColor = BrickColor.new("Institutional white") |
| 170 | p.Material = Enum.Material.Glacier |
| 171 | p.MaterialVariant = "2022 Stud" |
| 172 | p.Anchored = true |
| 173 | p.Parent = model |
| 174 | end |
| 175 | do |
| 176 | local p = Instance.new("Part") |
| 177 | p.Shape = Enum.PartType.Ball |
| 178 | p.Name = "Foam_Ball1" |
| 179 | p.Size = Vector3.new(2, 2, 2) |
| 180 | p.CFrame = CFrame.new(0, 12, 0.3) |
| 181 | p.BrickColor = BrickColor.new("Institutional white") |
| 182 | p.Material = Enum.Material.Glacier |
| 183 | p.MaterialVariant = "2022 Stud" |
| 184 | p.Anchored = true |
| 185 | p.Parent = model |
| 186 | end |
| 187 | do |
| 188 | local p = Instance.new("Part") |
| 189 | p.Shape = Enum.PartType.Ball |
| 190 | p.Name = "Foam_Ball2" |
| 191 | p.Size = Vector3.new(2.5, 2.5, 2.5) |
| 192 | p.CFrame = CFrame.new(2.5, 12.2, 0.3) |
| 193 | p.BrickColor = BrickColor.new("Institutional white") |
| 194 | p.Material = Enum.Material.Glacier |
| 195 | p.MaterialVariant = "2022 Stud" |
| 196 | p.Anchored = true |
| 197 | p.Parent = model |
| 198 | end |
| 199 | do |
| 200 | local p = Instance.new("Part") |
| 201 | p.Shape = Enum.PartType.Ball |
| 202 | p.Name = "Foam_Ball3" |
| 203 | p.Size = Vector3.new(2.2, 2.2, 2.2) |
| 204 | p.CFrame = CFrame.new(4.5, 11.5, 0.3) |
| 205 | p.BrickColor = BrickColor.new("Institutional white") |
| 206 | p.Material = Enum.Material.Glacier |
| 207 | p.MaterialVariant = "2022 Stud" |
| 208 | p.Anchored = true |
| 209 | p.Parent = model |
| 210 | end |
| 211 | do |
| 212 | local p = Instance.new("Part") |
| 213 | p.Shape = Enum.PartType.Ball |
| 214 | p.Name = "Foam_Ball4" |
| 215 | p.Size = Vector3.new(1.8, 1.8, 1.8) |
| 216 | p.CFrame = CFrame.new(6, 10, 0.3) |
| 217 | p.BrickColor = BrickColor.new("Institutional white") |
| 218 | p.Material = Enum.Material.Glacier |
| 219 | p.MaterialVariant = "2022 Stud" |
| 220 | p.Anchored = true |
| 221 | p.Parent = model |
| 222 | end |
| 223 | do |
| 224 | local p = Instance.new("Part") |
| 225 | p.Shape = Enum.PartType.Ball |
| 226 | p.Name = "Foam_Ball5" |
| 227 | p.Size = Vector3.new(1.5, 1.5, 1.5) |
| 228 | p.CFrame = CFrame.new(6.5, 8.5, 0.3) |
| 229 | p.BrickColor = BrickColor.new("Institutional white") |
| 230 | p.Material = Enum.Material.Glacier |
| 231 | p.MaterialVariant = "2022 Stud" |
| 232 | p.Anchored = true |
| 233 | p.Parent = model |
| 234 | end |
| 235 | do |
| 236 | local p = Instance.new("Part") |
| 237 | p.Shape = Enum.PartType.Ball |
| 238 | p.Name = "Foam_Ball6" |
| 239 | p.Size = Vector3.new(1.2, 1.2, 1.2) |
| 240 | p.CFrame = CFrame.new(5.5, 6.5, 0.3) |
| 241 | p.BrickColor = BrickColor.new("Institutional white") |
| 242 | p.Material = Enum.Material.Glacier |
| 243 | p.MaterialVariant = "2022 Stud" |
| 244 | p.Anchored = true |
| 245 | p.Parent = model |
| 246 | end |
| 247 | do |
| 248 | local p = Instance.new("Part") |
| 249 | p.Shape = Enum.PartType.Ball |
| 250 | p.Name = "Foam_Ball7" |
| 251 | p.Size = Vector3.new(1.5, 1.5, 1.5) |
| 252 | p.CFrame = CFrame.new(-2, 9, 0.3) |
| 253 | p.BrickColor = BrickColor.new("Institutional white") |
| 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.Shape = Enum.PartType.Ball |
| 262 | p.Name = "Droplet1" |
| 263 | p.Size = Vector3.new(0.8, 0.8, 0.8) |
| 264 | p.CFrame = CFrame.new(7.5, 10.5, 0.3) |
| 265 | p.BrickColor = BrickColor.new("Institutional white") |
| 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.Shape = Enum.PartType.Ball |
| 274 | p.Name = "Droplet2" |
| 275 | p.Size = Vector3.new(0.6, 0.6, 0.6) |
| 276 | p.CFrame = CFrame.new(8.2, 9, 0.3) |
| 277 | p.BrickColor = BrickColor.new("Institutional white") |
| 278 | p.Material = Enum.Material.Glacier |
| 279 | p.MaterialVariant = "2022 Stud" |
| 280 | p.Anchored = true |
| 281 | p.Parent = model |
| 282 | end |
| 283 | do |
| 284 | local p = Instance.new("Part") |
| 285 | p.Shape = Enum.PartType.Ball |
| 286 | p.Name = "Droplet3" |
| 287 | p.Size = Vector3.new(0.7, 0.7, 0.7) |
| 288 | p.CFrame = CFrame.new(8, 7.5, 0.3) |
| 289 | p.BrickColor = BrickColor.new("Institutional white") |
| 290 | p.Material = Enum.Material.Glacier |
| 291 | p.MaterialVariant = "2022 Stud" |
| 292 | p.Anchored = true |
| 293 | p.Parent = model |
| 294 | end |
| 295 | do |
| 296 | local p = Instance.new("Part") |
| 297 | p.Shape = Enum.PartType.Ball |
| 298 | p.Name = "Droplet4" |
| 299 | p.Size = Vector3.new(0.5, 0.5, 0.5) |
| 300 | p.CFrame = CFrame.new(7, 6.5, 0.3) |
| 301 | p.BrickColor = BrickColor.new("Institutional white") |
| 302 | p.Material = Enum.Material.Glacier |
| 303 | p.MaterialVariant = "2022 Stud" |
| 304 | p.Anchored = true |
| 305 | p.Parent = model |
| 306 | end |
| 307 | do |
| 308 | local p = Instance.new("Part") |
| 309 | p.Name = "LowerFoam1" |
| 310 | p.Size = Vector3.new(2, 1, 2.6) |
| 311 | p.CFrame = CFrame.new(5, 4.5, 0.26) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(15)) |
| 312 | p.BrickColor = BrickColor.new("Institutional white") |
| 313 | p.Material = Enum.Material.Glacier |
| 314 | p.MaterialVariant = "2022 Stud" |
| 315 | p.Anchored = true |
| 316 | p.Parent = model |
| 317 | end |
| 318 | do |
| 319 | local p = Instance.new("Part") |
| 320 | p.Name = "LowerFoam2" |
| 321 | p.Size = Vector3.new(2.5, 1, 2.6) |
| 322 | p.CFrame = CFrame.new(3, 3.5, 0.38) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-10)) |
| 323 | p.BrickColor = BrickColor.new("Institutional white") |
| 324 | p.Material = Enum.Material.Glacier |
| 325 | p.MaterialVariant = "2022 Stud" |
| 326 | p.Anchored = true |
| 327 | p.Parent = model |
| 328 | end |
| 329 | do |
| 330 | local p = Instance.new("Part") |
| 331 | p.Name = "LowerFoam3" |
| 332 | p.Size = Vector3.new(3, 1, 2.6) |
| 333 | p.CFrame = CFrame.new(0, 3, 0.5) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(5)) |
| 334 | p.BrickColor = BrickColor.new("Institutional white") |
| 335 | p.Material = Enum.Material.Glacier |
| 336 | p.MaterialVariant = "2022 Stud" |
| 337 | p.Anchored = true |
| 338 | p.Parent = model |
| 339 | end |
| 340 | do |
| 341 | local rightV = Vector3.new(1,0,0).Unit |
| 342 | local upV = (Vector3.new(0,1,0) - Vector3.new(0,1,0):Dot(rightV)*rightV).Unit |
| 343 | local normalV = upV:Cross(rightV) |
| 344 | local pos = Vector3.new(2, 6, 0) |
| 345 | local cyl = Instance.new("Part") |
| 346 | cyl.Shape = Enum.PartType.Cylinder |
| 347 | cyl.Size = Vector3.new(2, 12, 12) |
| 348 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 349 | cyl.BrickColor = BrickColor.new("Earth blue") |
| 350 | cyl.Material = Enum.Material.Glacier |
| 351 | cyl.MaterialVariant = "2022 Stud" |
| 352 | cyl.Anchored = true; cyl.Parent = workspace |
| 353 | local cuts = {} |
| 354 | local hole = Instance.new("Part") |
| 355 | hole.Shape = Enum.PartType.Cylinder |
| 356 | hole.Size = Vector3.new(2.2, 6, 6) |
| 357 | hole.CFrame = cyl.CFrame |
| 358 | hole.BrickColor = BrickColor.new("Earth blue") |
| 359 | hole.Material = Enum.Material.Glacier |
| 360 | hole.MaterialVariant = "2022 Stud" |
| 361 | hole.Anchored = true; hole.Parent = workspace |
| 362 | table.insert(cuts, hole) |
| 363 | local angBoxes = {} |
| 364 | do |
| 365 | local edgeDir = 0*rightV + 1*upV |
| 366 | local edgePerp = -1*rightV + 0*upV |
| 367 | local cut = Instance.new("Part") |
| 368 | cut.Size = Vector3.new(24, 2.2, 24) |
| 369 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 12 * edgePerp, edgeDir, normalV) |
| 370 | cut.BrickColor = BrickColor.new("Earth blue") |
| 371 | cut.Material = Enum.Material.Glacier |
| 372 | cut.MaterialVariant = "2022 Stud" |
| 373 | cut.Anchored = true; cut.Parent = workspace |
| 374 | table.insert(angBoxes, cut) |
| 375 | end |
| 376 | do |
| 377 | local edgeDir = 0*rightV + -1*upV |
| 378 | local edgePerp = 1*rightV + 0*upV |
| 379 | local cut = Instance.new("Part") |
| 380 | cut.Size = Vector3.new(24, 2.2, 24) |
| 381 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 12 * edgePerp, edgeDir, normalV) |
| 382 | cut.BrickColor = BrickColor.new("Earth blue") |
| 383 | cut.Material = Enum.Material.Glacier |
| 384 | cut.MaterialVariant = "2022 Stud" |
| 385 | cut.Anchored = true; cut.Parent = workspace |
| 386 | table.insert(angBoxes, cut) |
| 387 | end |
| 388 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 389 | if #cuts > 0 then |
| 390 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 391 | for _, c in ipairs(cuts) do c:Destroy() end |
| 392 | if ok and result then |
| 393 | cyl:Destroy() |
| 394 | result.Name = "MainCurl_Dark"; result.Anchored = true; result.Parent = model |
| 395 | else |
| 396 | cyl.Name = "MainCurl_Dark"; cyl.Parent = model |
| 397 | end |
| 398 | else |
| 399 | cyl.Name = "MainCurl_Dark"; cyl.Parent = model |
| 400 | end |
| 401 | end |
| 402 | do |
| 403 | local rightV = Vector3.new(1,0,0).Unit |
| 404 | local upV = (Vector3.new(0,1,0) - Vector3.new(0,1,0):Dot(rightV)*rightV).Unit |
| 405 | local normalV = upV:Cross(rightV) |
| 406 | local pos = Vector3.new(2.04, 6, 0.14) |
| 407 | local cyl = Instance.new("Part") |
| 408 | cyl.Shape = Enum.PartType.Cylinder |
| 409 | cyl.Size = Vector3.new(2.2, 11, 11) |
| 410 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 411 | cyl.BrickColor = BrickColor.new("Storm blue") |
| 412 | cyl.Material = Enum.Material.Glacier |
| 413 | cyl.MaterialVariant = "2022 Stud" |
| 414 | cyl.Anchored = true; cyl.Parent = workspace |
| 415 | local cuts = {} |
| 416 | local hole = Instance.new("Part") |
| 417 | hole.Shape = Enum.PartType.Cylinder |
| 418 | hole.Size = Vector3.new(2.4, 7, 7) |
| 419 | hole.CFrame = cyl.CFrame |
| 420 | hole.BrickColor = BrickColor.new("Storm blue") |
| 421 | hole.Material = Enum.Material.Glacier |
| 422 | hole.MaterialVariant = "2022 Stud" |
| 423 | hole.Anchored = true; hole.Parent = workspace |
| 424 | table.insert(cuts, hole) |
| 425 | local angBoxes = {} |
| 426 | do |
| 427 | local edgeDir = 0*rightV + 1*upV |
| 428 | local edgePerp = -1*rightV + 0*upV |
| 429 | local cut = Instance.new("Part") |
| 430 | cut.Size = Vector3.new(22, 2.4, 22) |
| 431 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 11 * edgePerp, edgeDir, normalV) |
| 432 | cut.BrickColor = BrickColor.new("Storm blue") |
| 433 | cut.Material = Enum.Material.Glacier |
| 434 | cut.MaterialVariant = "2022 Stud" |
| 435 | cut.Anchored = true; cut.Parent = workspace |
| 436 | table.insert(angBoxes, cut) |
| 437 | end |
| 438 | do |
| 439 | local edgeDir = -0.173648*rightV + -0.984808*upV |
| 440 | local edgePerp = 0.984808*rightV + -0.173648*upV |
| 441 | local cut = Instance.new("Part") |
| 442 | cut.Size = Vector3.new(22, 2.4, 22) |
| 443 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 11 * edgePerp, edgeDir, normalV) |
| 444 | cut.BrickColor = BrickColor.new("Storm blue") |
| 445 | cut.Material = Enum.Material.Glacier |
| 446 | cut.MaterialVariant = "2022 Stud" |
| 447 | cut.Anchored = true; cut.Parent = workspace |
| 448 | table.insert(angBoxes, cut) |
| 449 | end |
| 450 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 451 | if #cuts > 0 then |
| 452 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 453 | for _, c in ipairs(cuts) do c:Destroy() end |
| 454 | if ok and result then |
| 455 | cyl:Destroy() |
| 456 | result.Name = "MainCurl_Mid"; result.Anchored = true; result.Parent = model |
| 457 | else |
| 458 | cyl.Name = "MainCurl_Mid"; cyl.Parent = model |
| 459 | end |
| 460 | else |
| 461 | cyl.Name = "MainCurl_Mid"; cyl.Parent = model |
| 462 | end |
| 463 | end |
| 464 | do |
| 465 | local rightV = Vector3.new(1,0,0).Unit |
| 466 | local upV = (Vector3.new(0,1,0) - Vector3.new(0,1,0):Dot(rightV)*rightV).Unit |
| 467 | local normalV = upV:Cross(rightV) |
| 468 | local pos = Vector3.new(2, 6, 0.32) |
| 469 | local cyl = Instance.new("Part") |
| 470 | cyl.Shape = Enum.PartType.Cylinder |
| 471 | cyl.Size = Vector3.new(2.4, 9, 9) |
| 472 | cyl.CFrame = CFrame.fromMatrix(pos, normalV, rightV) |
| 473 | cyl.BrickColor = BrickColor.new("Electric blue") |
| 474 | cyl.Material = Enum.Material.Glacier |
| 475 | cyl.MaterialVariant = "2022 Stud" |
| 476 | cyl.Anchored = true; cyl.Parent = workspace |
| 477 | local cuts = {} |
| 478 | local hole = Instance.new("Part") |
| 479 | hole.Shape = Enum.PartType.Cylinder |
| 480 | hole.Size = Vector3.new(2.6, 8, 8) |
| 481 | hole.CFrame = cyl.CFrame |
| 482 | hole.BrickColor = BrickColor.new("Electric blue") |
| 483 | hole.Material = Enum.Material.Glacier |
| 484 | hole.MaterialVariant = "2022 Stud" |
| 485 | hole.Anchored = true; hole.Parent = workspace |
| 486 | table.insert(cuts, hole) |
| 487 | local angBoxes = {} |
| 488 | do |
| 489 | local edgeDir = -0.173648*rightV + 0.984808*upV |
| 490 | local edgePerp = -0.984808*rightV + -0.173648*upV |
| 491 | local cut = Instance.new("Part") |
| 492 | cut.Size = Vector3.new(18, 2.6, 18) |
| 493 | cut.CFrame = CFrame.fromMatrix(pos + -1 * 9 * edgePerp, edgeDir, normalV) |
| 494 | cut.BrickColor = BrickColor.new("Electric blue") |
| 495 | cut.Material = Enum.Material.Glacier |
| 496 | cut.MaterialVariant = "2022 Stud" |
| 497 | cut.Anchored = true; cut.Parent = workspace |
| 498 | table.insert(angBoxes, cut) |
| 499 | end |
| 500 | do |
| 501 | local edgeDir = -0.34202*rightV + -0.939693*upV |
| 502 | local edgePerp = 0.939693*rightV + -0.34202*upV |
| 503 | local cut = Instance.new("Part") |
| 504 | cut.Size = Vector3.new(18, 2.6, 18) |
| 505 | cut.CFrame = CFrame.fromMatrix(pos + 1 * 9 * edgePerp, edgeDir, normalV) |
| 506 | cut.BrickColor = BrickColor.new("Electric blue") |
| 507 | cut.Material = Enum.Material.Glacier |
| 508 | cut.MaterialVariant = "2022 Stud" |
| 509 | cut.Anchored = true; cut.Parent = workspace |
| 510 | table.insert(angBoxes, cut) |
| 511 | end |
| 512 | for _, b in ipairs(angBoxes) do table.insert(cuts, b) end |
| 513 | if #cuts > 0 then |
| 514 | local ok, result = pcall(function() return cyl:SubtractAsync(cuts) end) |
| 515 | for _, c in ipairs(cuts) do c:Destroy() end |
| 516 | if ok and result then |
| 517 | cyl:Destroy() |
| 518 | result.Name = "MainCurl_Light"; result.Anchored = true; result.Parent = model |
| 519 | else |
| 520 | cyl.Name = "MainCurl_Light"; cyl.Parent = model |
| 521 | end |
| 522 | else |
| 523 | cyl.Name = "MainCurl_Light"; cyl.Parent = model |
| 524 | end |
| 525 | end |
| 526 | model.PrimaryPart = model:FindFirstChild("LowerBody_Dark") |
| 527 | print("OceanWave built: " .. #model:GetChildren() .. " parts") |
Loading comments...