Lua functions

IsNight

Registered in this checkout as EQ2Emu_lua_IsNight; implementation found at WorldServer/Lua/LuaFunctions.cpp:11505.

Historical signature: IsNight(Zone)

Parameter and behavior details in the historical explanation are under review against the current implementation.

Function: IsNight(Zone)

Description: Checks if it is currently nighttime in the specified zone. This usually refers to the game’s day/night cycle.

Parameters:

  • Zone: Zone - The zone to check if the time is night.

Returns: Return's true if the current time is dusk/night. Otherwise return's false.

Checked example

Active call in a local runtime Lua script. Argument count matches current fixed C++ readers. This is a contextual call pattern, not a tested standalone script.

if not IsNight(zone) then

Evidence: server/SpawnScripts/ThunderingSteppes/BridgeDoors.lua:19; binding EQ2Emu_lua_IsNight.

Current registration: WorldServer/Lua/LuaInterface.cpp. Historical explanation: EQ2Emu Lua documentation.