feat: 50 игр на Lua + импорт Roblox для всех + поддержка Lua в плеере #39

Merged
min merged 215 commits from feat/lua-50-games-bundle into main 2026-06-09 21:59:25 +00:00
Showing only changes of commit 39673452cb - Show all commits

View File

@ -325,14 +325,19 @@ local function hideHint()
end
-- Каждый кадр проверяем расстояние до игрока
RunService.Heartbeat:Connect(function()
local _debugTick = 0
RunService.Heartbeat:Connect(function(dt)
if opened then return end
local px = __rbxl_player_x()
local py = __rbxl_player_y()
local pz = __rbxl_player_z()
local dx = part.Position.X - px
local dz = part.Position.Z - pz
local dist = math.sqrt(dx*dx + dz*dz)
_debugTick = _debugTick + (dt or 0.016)
if _debugTick > 1 then
_debugTick = 0
print("[g4] px=", px, "pz=", pz, "dist=", dist, "inRange=", inRange)
end
if dist <= 4 and not inRange then
inRange = true
showHint()