1212
This commit is contained in:
1 parent
ec69c6c8d7
commit
ccd24dc5ec
10 files changed
+500
-340
No files matched your search
@@ -677,8 +677,9 @@ for i, w in ipairs(Config.Worlds) do
|
||||
local title = w.icon .. " " .. w.name .. (w.level > 1 and (" (ур. " .. w.level .. ")") or "")
|
||||
local a = math.rad(90 - (i - 1) * 90) -- 90° = сторона спавна (+Z)
|
||||
local pos = V(math.cos(a) * PORTAL_R, FLOOR, math.sin(a) * PORTAL_R)
|
||||
portal(CFrame.lookAt(pos, V(pos.X * 2, FLOOR, pos.Z * 2)), title, w.color, w.id, w.soon)
|
||||
local disc = portal(CFrame.lookAt(pos, V(pos.X * 2, FLOOR, pos.Z * 2)), title, w.color, w.id, w.soon)
|
||||
if i == 1 then
|
||||
disc:SetAttribute("GuideTarget", "Portal")
|
||||
marker("GuidePortal", CFrame.new(pos.X * 1.3, FLOOR, pos.Z * 1.3)) -- точка перед порталом для линии-подсказки
|
||||
end
|
||||
end
|
||||
@@ -770,6 +771,7 @@ do
|
||||
P({ Size = V(0.8, 9, 0.8), CFrame = cf * CFrame.new(x, 4.5, 0.3), Material = Enum.Material.Wood, Color = Color3.fromRGB(90, 60, 40) })
|
||||
end
|
||||
local board = P({ Size = V(14, 8, 0.5), CFrame = cf * CFrame.new(0, 6, 0), Material = Enum.Material.WoodPlanks, Color = Color3.fromRGB(70, 48, 32) })
|
||||
board:SetAttribute("GuideTarget", "Board") -- подсвечивается на шаге обучения
|
||||
surfaceText(board, Enum.NormalId.Front,
|
||||
"<font color=\"#FFD866\">КАК ИГРАТЬ</font>\n1. Портал «Мир 1» или кнопка 🌍 Миры\n2. Удочка — клавиша 1, у воды зажми ЛКМ и отпусти\n3. Клюёт → кликай в зелёную зону\n4. 🎒 Сумка — B, 📜 Задания — Q\n5. Собирай коллекцию — получай награды!",
|
||||
Color3.fromRGB(255, 245, 225), { TextXAlignment = Enum.TextXAlignment.Left })
|
||||
@@ -795,7 +797,7 @@ portal(CFrame.lookAt(W + V(-22, GROUND_Y, 96), arrive), "🏠 В лобби", Co
|
||||
-- точки для линии-подсказки: конец главного причала и место перед скупкой
|
||||
marker("GuideFishSpot", CFrame.new(W + V(0, GROUND_Y + 0.5, 42)))
|
||||
marker("GuideSell", CFrame.lookAt(W + V(26, GROUND_Y, 98), arrive) * CFrame.new(0, 0, -10))
|
||||
stall(CFrame.lookAt(W + V(26, GROUND_Y, 98), arrive), {
|
||||
local w1Counter = stall(CFrame.lookAt(W + V(26, GROUND_Y, 98), arrive), {
|
||||
title = "💰 СКУПКА",
|
||||
titleColor = Color3.fromRGB(150, 255, 160),
|
||||
wall = Color3.fromRGB(150, 115, 80),
|
||||
@@ -808,6 +810,7 @@ stall(CFrame.lookAt(W + V(26, GROUND_Y, 98), arrive), {
|
||||
npcName = "Скупщик Гриша",
|
||||
npcColors = { skin = Color3.fromRGB(200, 150, 110), shirt = Color3.fromRGB(70, 130, 80), pants = Color3.fromRGB(60, 50, 40), hat = Color3.fromRGB(200, 170, 110) },
|
||||
})
|
||||
w1Counter:SetAttribute("GuideTarget", "Sell") -- прилавок подсвечивается на шаге обучения
|
||||
|
||||
-- доска «Кто водится в озере»
|
||||
do
|
||||
@@ -874,7 +877,7 @@ end
|
||||
|
||||
-- причалы
|
||||
local function pier(center, size)
|
||||
P({ Size = size, Position = center, Material = Enum.Material.WoodPlanks, Color = Color3.fromRGB(150, 110, 70) })
|
||||
local deck = P({ Size = size, Position = center, Material = Enum.Material.WoodPlanks, Color = Color3.fromRGB(150, 110, 70) })
|
||||
local alongZ = size.Z > size.X
|
||||
local len = alongZ and size.Z or size.X
|
||||
local wid = alongZ and size.X or size.Z
|
||||
@@ -884,6 +887,7 @@ local function pier(center, size)
|
||||
vcyl(center + off + V(0, -6, 0), 13, 0.9, { Color = Color3.fromRGB(100, 70, 45), Material = Enum.Material.Wood })
|
||||
end
|
||||
end
|
||||
return deck
|
||||
end
|
||||
-- { центр от W, размер }
|
||||
local PIERS = {
|
||||
@@ -891,72 +895,13 @@ local PIERS = {
|
||||
{ V(-86, GROUND_Y + 0.2, 15), V(34, 0.6, 7) },
|
||||
{ V(86, GROUND_Y + 0.2, -10), V(34, 0.6, 7) },
|
||||
}
|
||||
for _, p in ipairs(PIERS) do
|
||||
pier(W + p[1], p[2])
|
||||
for i, p in ipairs(PIERS) do
|
||||
local deck = pier(W + p[1], p[2])
|
||||
if i == 1 then
|
||||
deck:SetAttribute("GuideTarget", "Pier") -- главный причал подсвечивается на шаге обучения
|
||||
end
|
||||
end
|
||||
|
||||
-- невидимое ограждение: в воду не зайти, рыбачить можно с берега и причалов
|
||||
do
|
||||
local function barrier(cf, size)
|
||||
P({ Name = "LakeBarrier", Size = size, CFrame = cf, Transparency = 1, CanQuery = false, CanTouch = false, CastShadow = false })
|
||||
end
|
||||
local SEG = 3 -- длина секции по берегу
|
||||
local H = 500 -- высота: не перепрыгнуть
|
||||
local MID = WATER_Y + H / 2
|
||||
local function onPier(x, z, pad)
|
||||
for _, p in ipairs(PIERS) do
|
||||
if math.abs(x - p[1].X) < p[2].X / 2 + pad and math.abs(z - p[1].Z) < p[2].Z / 2 + pad then
|
||||
return true
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
-- по внешнему краю озёр (участки внутри соседнего озера пропускаем)
|
||||
for _, l in ipairs(LAKES) do
|
||||
local r = l[3] + 2
|
||||
local n = math.ceil(2 * math.pi * r / SEG)
|
||||
local len = 2 * math.pi * r / n + 0.6
|
||||
for i = 0, n - 1 do
|
||||
local a = i / n * math.pi * 2
|
||||
local x, z = l[1] + math.cos(a) * r, l[2] + math.sin(a) * r
|
||||
local inner = false
|
||||
for _, o in ipairs(LAKES) do
|
||||
if o ~= l and (x - o[1]) ^ 2 + (z - o[2]) ^ 2 < (o[3] + 2) ^ 2 then
|
||||
inner = true
|
||||
break
|
||||
end
|
||||
end
|
||||
if not inner and not onPier(x, z, len / 2 + 0.2) then
|
||||
local pos = W + V(x, MID, z)
|
||||
barrier(CFrame.lookAt(pos, W + V(l[1], MID, l[2])), V(len, H, 1))
|
||||
end
|
||||
end
|
||||
end
|
||||
-- бортики причалов: по бокам и на конце, который над водой
|
||||
for _, p in ipairs(PIERS) do
|
||||
local c, s = p[1], p[2]
|
||||
local h, y = H, MID
|
||||
local alongZ = s.Z > s.X
|
||||
for _, side in ipairs({ -1, 1 }) do
|
||||
if alongZ then
|
||||
barrier(CFrame.new(W + V(c.X + side * (s.X / 2 + 0.5), y, c.Z)), V(1, h, s.Z))
|
||||
else
|
||||
barrier(CFrame.new(W + V(c.X, y, c.Z + side * (s.Z / 2 + 0.5))), V(s.X, h, 1))
|
||||
end
|
||||
end
|
||||
for _, side in ipairs({ -1, 1 }) do
|
||||
local ex = alongZ and c.X or c.X + side * s.X / 2
|
||||
local ez = alongZ and c.Z + side * s.Z / 2 or c.Z
|
||||
if inLake(ex, ez) then
|
||||
if alongZ then
|
||||
barrier(CFrame.new(W + V(ex, y, ez + side * 0.5)), V(s.X + 2, h, 1))
|
||||
else
|
||||
barrier(CFrame.new(W + V(ex + side * 0.5, y, ez)), V(1, h, s.Z + 2))
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
lamp(W + V(-3.5, GROUND_Y + 0.5, 40), Color3.fromRGB(255, 220, 160))
|
||||
lamp(W + V(-70, GROUND_Y + 0.5, 18), Color3.fromRGB(255, 220, 160))
|
||||
lamp(W + V(70, GROUND_Y + 0.5, -13), Color3.fromRGB(255, 220, 160))
|
||||
|
||||
Reference in new issue
Block a user