ChunkLoad_Data: type: data debug: false # Specify the worlds to disable flight in here. Disabled_Worlds: - Spawn - SpawnBuilds - Events ChunkLoad_Command: type: command debug: true name: chunkload description: Keeps a single chunk loaded usage: /chunkload [remove] tab completions: 1: remove permission: servername.user.chunkload script: - if == remove: - if : - narrate " <&7>» <&c>You do not have a loaded chunk" - stop - else: - define chunk - chunkload remove <[chunk]> - flag server LoadedChunks:<-:<[chunk]> - flag LoadedChunk:! - narrate " <&7>» <&6><[chunk].x>,<[chunk].z>,<[chunk].world.name> <&color[#87CEEB]>will no longer stay loaded." - stop - else: - define chunk - if ]>: - narrate " <&7>» <&c>You cannot use this command in this world!" - stop - if ].contains[<[chunk]>]>: - narrate " <&7>» <&c>This command has already been used on this chunk!" - stop - if : - flag LoadedChunk:<[chunk]> - flag server LoadedChunks:->:<[chunk]> - chunkload <[chunk]> - narrate " <&7>» <&6><[chunk].x>,<[chunk].z>,<[chunk].world.name> <&color[#87CEEB]>will now stay loaded while you are online" - stop - else: - chunkload remove - flag server LoadedChunks:<-: - flag LoadedChunk:<[chunk]> - flag server LoadedChunks:->:<[chunk]> - chunkload <[chunk]> - narrate " <&7>» <&6><[chunk].x>,<[chunk].z>,<[chunk].world.name> <&color[#87CEEB]>will now stay loaded while you are online." - stop ChunkLoad_Handler: type: world debug: false events: after player joins flagged:loadedchunk: - chunkload after player quits flagged:loadedchunk: - chunkload remove