12
This commit is contained in:
1 parent
5dfded2fe1
commit
134940f76d
5 files changed
+574
-93
No files matched your search
@@ -132,7 +132,8 @@ end
|
||||
|
||||
---------------------------------------------------------------- детали
|
||||
-- parent — куда положить папку World1Map (Workspace при сборке в Studio, FishingMap при запуске игры)
|
||||
function Builder.build(parent)
|
||||
-- makePortal — WorldBuilder.portalModel: ставит модель портала из шаблона (без него строится старое кольцо)
|
||||
function Builder.build(parent, makePortal)
|
||||
buildTerrain()
|
||||
|
||||
local rng = Random.new(7)
|
||||
@@ -541,20 +542,30 @@ function Builder.build(parent)
|
||||
portalModel.Name = "PortalToLobby"
|
||||
portalModel.Parent = map
|
||||
local center = baseCF * CFrame.new(0, 10, 0)
|
||||
P({ Size = V(17, 1, 9), CFrame = baseCF * CFrame.new(0, 0.5, 0), Material = Enum.Material.Slate, Color = Color3.fromRGB(95, 100, 115), Parent = portalModel })
|
||||
P({ Size = V(14, 1, 7), CFrame = baseCF * CFrame.new(0, 1.5, 0), Material = Enum.Material.Slate, Color = Color3.fromRGB(110, 115, 130), Parent = portalModel })
|
||||
local R, n = 7, 20
|
||||
for i = 0, n - 1 do
|
||||
local a = (i + 0.5) / n * math.pi * 2
|
||||
P({ Size = V(2 * math.pi * R / n + 0.4, 1.7, 1.7), CFrame = center * CFrame.Angles(0, 0, a) * CFrame.new(0, R, 0), Material = Enum.Material.Slate, Color = Color3.fromRGB(80, 85, 100), Parent = portalModel })
|
||||
if i % 2 == 0 then
|
||||
P({ Size = V(0.6, 0.6, 1.9), CFrame = center * CFrame.Angles(0, 0, a) * CFrame.new(0, R + 0.95, 0), Material = Enum.Material.Neon, Color = color, Parent = portalModel })
|
||||
local fancy = makePortal and makePortal(baseCF, color, "PortalModel_Lobby", portalModel)
|
||||
local disc
|
||||
if fancy then
|
||||
-- модель из шаблона; невидимый якорь держит подсказку, подпись и искры
|
||||
disc = P({
|
||||
Name = "Portal_Lobby", Size = V(1, 1, 1), CFrame = center * CFrame.Angles(0, math.rad(90), 0),
|
||||
Transparency = 1, CanCollide = false, CanQuery = false, CanTouch = false, Parent = portalModel,
|
||||
})
|
||||
else
|
||||
P({ Size = V(17, 1, 9), CFrame = baseCF * CFrame.new(0, 0.5, 0), Material = Enum.Material.Slate, Color = Color3.fromRGB(95, 100, 115), Parent = portalModel })
|
||||
P({ Size = V(14, 1, 7), CFrame = baseCF * CFrame.new(0, 1.5, 0), Material = Enum.Material.Slate, Color = Color3.fromRGB(110, 115, 130), Parent = portalModel })
|
||||
local R, n = 7, 20
|
||||
for i = 0, n - 1 do
|
||||
local a = (i + 0.5) / n * math.pi * 2
|
||||
P({ Size = V(2 * math.pi * R / n + 0.4, 1.7, 1.7), CFrame = center * CFrame.Angles(0, 0, a) * CFrame.new(0, R, 0), Material = Enum.Material.Slate, Color = Color3.fromRGB(80, 85, 100), Parent = portalModel })
|
||||
if i % 2 == 0 then
|
||||
P({ Size = V(0.6, 0.6, 1.9), CFrame = center * CFrame.Angles(0, 0, a) * CFrame.new(0, R + 0.95, 0), Material = Enum.Material.Neon, Color = color, Parent = portalModel })
|
||||
end
|
||||
end
|
||||
disc = P({
|
||||
Name = "Portal_Lobby", Shape = Enum.PartType.Cylinder, Size = V(0.3, 2 * R - 1, 2 * R - 1), CFrame = center * CFrame.Angles(0, math.rad(90), 0),
|
||||
Material = Enum.Material.Neon, Color = color, Transparency = 0.3, CanCollide = false, Parent = portalModel,
|
||||
})
|
||||
end
|
||||
local disc = P({
|
||||
Name = "Portal_Lobby", Shape = Enum.PartType.Cylinder, Size = V(0.3, 2 * R - 1, 2 * R - 1), CFrame = center * CFrame.Angles(0, math.rad(90), 0),
|
||||
Material = Enum.Material.Neon, Color = color, Transparency = 0.3, CanCollide = false, Parent = portalModel,
|
||||
})
|
||||
local pe = Instance.new("ParticleEmitter")
|
||||
pe.Color = ColorSequence.new(color, Color3.new(1, 1, 1))
|
||||
pe.LightEmission = 1
|
||||
@@ -567,7 +578,7 @@ function Builder.build(parent)
|
||||
pe.Parent = disc
|
||||
local bb = Instance.new("BillboardGui")
|
||||
bb.Size = UDim2.fromOffset(250, 64)
|
||||
bb.StudsOffset = V(0, 10, 0)
|
||||
bb.StudsOffset = V(0, fancy and 7 or 10, 0)
|
||||
bb.MaxDistance = 160
|
||||
bb.LightInfluence = 0
|
||||
bb.Parent = disc
|
||||
|
||||
Reference in new issue
Block a user