Commands/daylock
Minecraft Wiki article. Categories: Bedrock_Edition, Minecraft_Education, Unknown_Bedrock_version_history, Commands
This article is reproduced from Commands/daylock on the Minecraft Wiki. Mirrored from revision 3548265. It is licensed CC BY-NC-SA 3.0 by the Minecraft Wiki contributors — not under the Codex’s CC BY-SA 4.0, and it may not be used commercially. Edits belong upstream, not here.
/daylock{
"title": "<code>/daylock</code>",
"rows": [
{
"field": "<!-- Command --><code ><span>/alwaysday</span></code><!-- /Command -->",
"label": "Aliases"
},
{
"field": "1",
"label": "(link to Permission level article, displayed as Permission level<br>required)"
},
{
"field": "(link to Cheat article, displayed as Cheat) only<br>",
"label": "(link to Commands#Restrictions article, displayed as Restrictions)"
}
],
"invimages": [],
"images": []
}
Locks and unlocks eternal daytime.
Sets the game option "Always Day" to the argument value. If the argument is false, turns on the "Do Daylight Cycle" game option. If the argument is true or is omitted, turns off the "Do Daylight Cycle" game option and sets the time of day (time daytime value) to 5000 ticks, which is one in-game hour before noon.
Syntax
daylock [lock: Boolean]alwaysday [lock: Boolean]
Arguments
lock: Boolean: enum
- Specifies whether the eternal daytime is locked or not.
- Must be a [Boolean]Boolean (either
trueorfalse). If not specified, defaults totrue. Note that this argument has the opposite sense from thegamerule dodaylightcyclecommand's argument.
Result
| Command | Trigger | Bedrock Edition |
|---|---|---|
| Any | The argument is not specified correctly. | Unparseable |
| Otherwise | Successful |
History
Bedrock Edition
| Bedrock Edition | |||||||
|---|---|---|---|---|---|---|---|
| 1.2.0 | ? | Added /daylock. | |||||
Minecraft Education
| Minecraft Education | |||||||
|---|---|---|---|---|---|---|---|
| 1.0.21 | Added /daylock. | ||||||
External links
- "
/daylockCommand" – Microsoft Learn, October 11, 2023.
Navigation
Sources
- Commands/daylock — Minecraft Wiki, CC BY-NC-SA 3.0, revision 3548265.