--// INITIALIZATION & GLOBAL SERVICES
local Workspace = game:GetService("Workspace")
local Lighting = game:GetService("Lighting")
local TweenService = game:GetService("TweenService")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Players = game:GetService("Players")
local UserInputService = game:GetService("UserInputService")
local RunService = game:GetService("RunService")
local LocalPlayer = Players.LocalPlayer
local PlayerGui = LocalPlayer:WaitForChild("PlayerGui")
local Camera = Workspace.CurrentCamera
--// 1. NOTIFICATION CAPTIONS SYSTEM
local function DisplayNightmareCaptions(customCaptions)
local ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "NightmareCaptions"
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = PlayerGui
local TextLabel = Instance.new("TextLabel")
TextLabel.Size = UDim2.new(1, 0, 0.2, 0)
TextLabel.Position = UDim2.new(0, 0, 0.4, 0)
TextLabel.BackgroundTransparency = 1
TextLabel.Font = Enum.Font.SpecialElite
TextLabel.TextColor3 = Color3.fromRGB(180, 0, 0) -- Dark Crimson
TextLabel.TextSize = 32
TextLabel.TextStrokeTransparency = 0.2
TextLabel.TextStrokeColor3 = Color3.new(0, 0, 0)
TextLabel.Text = ""
TextLabel.Parent = ScreenGui
task.spawn(function()
local list = customCaptions or {
"Nightmare mode initiated",
"V2 coming soon",
"Credit to them who created these entities",
"Credit to scripter who create entity"
}
for _, text in ipairs(list) do
TextLabel.Text = text
TextLabel.TextTransparency = 1
TextLabel.TextStrokeTransparency = 1
TweenService:Create(TextLabel, TweenInfo.new(0.5), {TextTransparency = 0, TextStrokeTransparency = 0.2}):Play()
task.wait(2.5)
TweenService:Create(TextLabel, TweenInfo.new(0.5), {TextTransparency = 1, TextStrokeTransparency = 1}):Play()
task.wait(0.6)
end
ScreenGui:Destroy()
end)
end
--// 2. VISUALS: NEW FOG & AMBIENT CONFIGURATION
Lighting.Ambient = Color3.new(0, 0, 0)
Lighting.Brightness = 0.1
Lighting.FogEnd = 50
Lighting.FogStart = 35
Lighting.FogColor = Color3.new(0, 0, 0)
if Lighting:FindFirstChild("MainColorCorrection") then
Lighting.MainColorCorrection.TintColor = Color3.fromRGB(120, 50, 50)
Lighting.MainColorCorrection.Contrast = 0.5
Lighting.MainColorCorrection.Saturation = -0.3
end
--// 3. NIGHTMARE AMBIENT MUSIC (File Caching System)
local function getGitSoundId(Url, AssetName)
if not writefile or not isfile or not getcustomasset then
local fallbackSound = Instance.new("Sound")
fallbackSound.SoundId = Url
return fallbackSound
end
if not isfile(AssetName..".mp3") then
writefile(AssetName..".mp3", game:HttpGet(Url))
end
local Sound = Instance.new("Sound")
Sound.SoundId = getcustomasset(AssetName..".mp3", true)
return Sound
end
local CustomMusic = getGitSoundId("https://github.com/nervehammer1/throwawaystuff/raw/refs/heads/main/NightmareAmbient.mp3", "NightmareModeAmbient")
CustomMusic.Parent = Workspace
CustomMusic.Looped = true
CustomMusic.Volume = 2
CustomMusic:Play()
--// 4. FRAGMENTED MODE SPRINT SYSTEM (Enlarged Mobile Box UI Layout)
task.spawn(function()
local WALK_SPEED = 16
local SPRINT_SPEED = 26
local MAX_STAMINA = 100
local currentStamina = MAX_STAMINA
local STAMINA_DRAIN = 0.35
local STAMINA_REGEN = 0.2
local EXHAUSTION_COOLDOWN = 2.5
local isSprinting = false
local isOnCooldown = false
local character = LocalPlayer.Character or LocalPlayer.CharacterAdded:Wait()
local humanoid = character:WaitForChild("Humanoid")
LocalPlayer.CharacterAdded:Connect(function(newCharacter)
character = newCharacter
humanoid = character:WaitForChild("Humanoid")
end)
-- CUSTOM MOBILE-SIZED INTERFACE GENERATOR
local sprintGui = PlayerGui:FindFirstChild("SprintGui")
if not sprintGui then
sprintGui = Instance.new("ScreenGui")
sprintGui.Name = "SprintGui"
sprintGui.ResetOnSpawn = false
sprintGui.Parent = PlayerGui
-- ENLARGED SPRINT BUTTON: Positioned to the right of the stamina bar
local sprintButton = Instance.new("TextButton")
sprintButton.Name = "SprintButton"
sprintButton.Size = UDim2.new(0, 75, 0, 75)
sprintButton.Position = UDim2.new(0.5, 220, 0.84, 0)
sprintButton.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
sprintButton.BorderSizePixel = 3
sprintButton.BorderColor3 = Color3.fromRGB(0, 0, 0)
sprintButton.Text = ""
sprintButton.AutoButtonColor = false
sprintButton.Parent = sprintGui
-- STAMINA BACKING: Centered sharp 400px long cube layout with solid black border
local backing = Instance.new("Frame")
backing.Name = "StaminaBacking"
backing.Size = UDim2.new(0, 400, 0, 16)
backing.Position = UDim2.new(0.5, -200, 0.88, 0)
backing.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
backing.BorderSizePixel = 2
backing.BorderColor3 = Color3.fromRGB(0, 0, 0)
backing.Parent = sprintGui
-- STAMINA FILLER: Clean flat cube geometry
local bar = Instance.new("Frame")
bar.Name = "StaminaBar"
bar.Size = UDim2.new(1, 0, 1, 0)
bar.BackgroundColor3 = Color3.fromRGB(180, 0, 0)
bar.BorderSizePixel = 0
bar.Parent = backing
end
local sprintButton = sprintGui:WaitForChild("SprintButton")
local backing = sprintGui:WaitForChild("StaminaBacking")
local bar = backing:WaitForChild("StaminaBar")
local function tweenFOV(targetFOV)
local tweenInfo = TweenInfo.new(0.3, Enum.EasingStyle.Quad, Enum.EasingDirection.Out)
TweenService:Create(Camera, tweenInfo, {FieldOfView = targetFOV}):Play()
end
local function updateUI()
if not bar then return end
local staminaPercent = currentStamina / MAX_STAMINA
bar:TweenSize(
UDim2.new(staminaPercent, 0, 1, 0),
Enum.EasingDirection.Out,
Enum.EasingStyle.Quad,
0.05,
true
)
if isOnCooldown then
bar.BackgroundColor3 = Color3.fromRGB(180, 40, 40)
elseif staminaPercent < 0.25 then
bar.BackgroundColor3 = Color3.fromRGB(220, 110, 30)
else
bar.BackgroundColor3 = Color3.fromRGB(180, 0, 0)
end
end
-- Keyboard Connections
UserInputService.InputBegan:Connect(function(input, gameProcessed)
if gameProcessed then return end
if input.KeyCode == Enum.KeyCode.LeftShift and not isOnCooldown then
if humanoid and humanoid.MoveDirection.Magnitude > 0 then
isSprinting = true
tweenFOV(85)
end
end
end)
UserInputService.InputEnded:Connect(function(input)
if input.KeyCode == Enum.KeyCode.LeftShift then
isSprinting = false
tweenFOV(70)
end
end)
-- Mobile/Click Connections
sprintButton.MouseButton1Down:Connect(function()
if not isOnCooldown and humanoid and humanoid.MoveDirection.Magnitude > 0 then
isSprinting = true
tweenFOV(85)
end
end)
sprintButton.MouseButton1Up:Connect(function()
isSprinting = false
tweenFOV(70)
end)
-- Core bypass loop
RunService.RenderStepped:Connect(function()
if humanoid then
if isSprinting and humanoid.MoveDirection.Magnitude == 0 then
isSprinting = false
tweenFOV(70)
end
if isSprinting and not isOnCooldown then
humanoid.WalkSpeed = SPRINT_SPEED
currentStamina = math.clamp(currentStamina - STAMINA_DRAIN, 0, MAX_STAMINA)
if currentStamina <= 0 then
isSprinting = false
isOnCooldown = true
tweenFOV(70)
task.delay(EXHAUSTION_COOLDOWN, function()
isOnCooldown = false
end)
end
else
if not isSprinting then
humanoid.WalkSpeed = WALK_SPEED
end
currentStamina = math.clamp(currentStamina + STAMINA_REGEN, 0, MAX_STAMINA)
end
end
updateUI()
end)
end)
--// 5. SPAWN CUSTOM NIGHTMARE ITEMS
task.spawn(function()
pcall(function() loadstring(game:HttpGet("https://raw.githubusercontent.com/thelostw3r/Scripts/refs/heads/main/PurpleFlashlight.lua"))() end)
task.wait(0.5)
pcall(function() loadstring(game:HttpGet("https://raw.githubusercontent.com/Junbbinopro/Item/refs/heads/main/lantern"))() end)
end)
--// 6. ENTITY LOADER UTILITIES
pcall(function()
loadstring(game:HttpGet("https://raw.githubusercontent.com/RegularVynixu/Utilities/main/Doors/Entity%20Spawner/V2/Source.lua"))()
end)
local NightmareMode = {}
function NightmareMode.SpawnDepth()
print("[Nightmare Mode]: DEPTH is emerging from below...")
pcall(function() loadstring(game:HttpGet("https://raw.githubusercontent.com/eoyoustme/back/refs/heads/main/Depthter"))() end)
end
function NightmareMode.SpawnDread()
print("[Nightmare Mode]: Warning... DREAD is manifesting...")
pcall(function() loadstring(game:HttpGet("https://raw.githubusercontent.com/eoyoustme/back/refs/heads/main/Dread"))() end)
end
function NightmareMode.SpawnHungered()
print("[Nightmare Mode]: Unleashing HUNGERED...")
pcall(function() loadstring(game:HttpGet("https://raw.githubusercontent.com/eoyoustme/ohh/b4925f04895ca7d0ce90f9c72a08fb00325b9d6a/HUNGERED"))() end)
end
function NightmareMode.SpawnZunxdHim()
print("[Nightmare Mode]: Zunxd Him has targeted you...")
pcall(function() loadstring(game:HttpGet("https://raw.githubusercontent.com/idkman60093/Doors-Modes/refs/heads/main/Zunxd%20Him%20Entity"))() end)
end
function NightmareMode.SpawnZ88()
print("[Nightmare Mode]: Z-88 approaching...")
pcall(function() loadstring(game:HttpGet("https://pastebin.com/raw/s8kXdQti"))() end)
end
function NightmareMode.SpawnNightmareRebound(index)
if index > 5 then return end
print("[Nightmare Mode]: Nightmare Rebound chain triggered: Cycle " .. tostring(index))
pcall(function() loadstring(game:HttpGet("https://pastebin.com/raw/2Cm7veCG"))() end)
task.spawn(function()
local startRoom = GetLatestRoomValue()
while GetLatestRoomValue() == startRoom do
task.wait(0.5)
end
task.wait(1)
NightmareMode.SpawnNightmareRebound(index + 1)
end)
end
function NightmareMode.SpawnHorrorRebound()
print("[Nightmare Mode]: Distortion detected... HORROR REBOUND is arriving!")
pcall(function() loadstring(game:HttpGet("https://pastebin.com/raw/c0B2ykpE"))() end)
end
function GetLatestRoomValue()
local gameData = ReplicatedStorage:FindFirstChild("GameData")
if gameData then
local latestRoom = gameData:FindFirstChild("LatestRoom")
if latestRoom then
return latestRoom.Value
end
end
return 0
end
--// 7. NIGHTMARE ENGAGEMENT CONTROLLER (Time-Based Spawning Mechanics)
task.spawn(function()
local gameData = ReplicatedStorage:WaitForChild("GameData", 15)
if not gameData then
warn("[Nightmare Mode Warning]: GameData folder not found! Execute this inside a match, not the main lobby.")
return
end
local latestRoom = gameData:WaitForChild("LatestRoom", 15)
if not latestRoom then return end
-- Prompt title notifications immediately upon entry
local hasTriggeredIntro = false
-- Fixed listener: ensure it reads the integer value correctly
latestRoom.Changed:Connect(function(roomValue)
if roomValue >= 1 and not hasTriggeredIntro then
hasTriggeredIntro = true
DisplayNightmareCaptions()
end
end)
-- Fallback check for instant execution if already in Room 1+
if latestRoom.Value >= 1 and not hasTriggeredIntro then
hasTriggeredIntro = true
DisplayNightmareCaptions()
end
print("[Nightmare Mode]: Chrono-clocks initialized. Survival timeline running...")
-- 🌀 LOOPING ENTITY: Depth (Attempts to manifest every 60 seconds)
task.spawn(function()
task.wait(30)
while true do
NightmareMode.SpawnDepth()
task.wait(60)
end
end)
-- ⏳ ONE-TIME TIME BOMBS (Spawns once per match at these exact times)
-- Dread Spawning Configuration (120 seconds)
task.delay(120, function()
NightmareMode.SpawnDread()
end)
-- Hunger Counter Spawning Configuration (199 seconds)
task.delay(199, function()
NightmareMode.SpawnHungered()
end)
-- Zunxd Him Spawning Configuration (250 seconds)
task.delay(250, function()
NightmareMode.SpawnZunxdHim()
end)
-- Z-88 Spawning Configuration (299 seconds)
task.delay(299, function()
NightmareMode.SpawnZ88()
end)
-- Nightmare Rebound Chain Configuration (350 seconds)
task.delay(350, function()
NightmareMode.SpawnNightmareRebound(1)
end)
-- New Horror Rebound Spawning Configuration (400 seconds)
task.delay(400, function()
NightmareMode.SpawnHorrorRebound()
end)
end)
print("[Nightmare Mode]: System fully initiated. Horror Rebound integrated successfully.")