World Properties

World Properties is a mod that adds a 'worldproperties' file to allow resource pack prompting, packet related settings, PVP on/off and more.

Video Review

Adds the world.properties file to each world's save directly! This unique file contains many of the properties found in server.properties, including the ability to set a custom MOTD for a lan world, change the max player count, toggle PvP, set a LAN resource pack, and more fun features!

world.properties is located at: minecraft/saves/world_name/world.properties

Full list of world properties options:
Toggle flight

Toggle nether

Toggle console broadcast to online operators

Set server difficultly

Toggle command blocks

Toggle entity broadcast range

Toggle force gamemode

Set function permission level

Set gamemode

Set hardcore

Set max players allowed at once

Set max tick time

Set max world size

Set MOTD

Set packet compression threshold (saves resources)

Set online mode (whether usernames are validated or cracked accounts can join)

Set OP permission level

Set idle timeout

Toggle whether proxy connections are allowed

Toggle PVP

Set rate limit (max packets before kick)

Set a custom resource pack

Toggle animal spawns

Toggle monster spawns

Toggle NPC spawns

Set spawn protection size

Toggle chunk write sync

Additionally, if you run the game in such a way that you have console access (i.e. using the command line), your singleplayer worlds will now be capable of receiving command line input and commands! Cool!

Fabric API need not be installed.