The Advanced Setting Module : PlayerKit v1.0

:rocket: PlayerKit v1.0

Generate, Load & Save Player Data with One Function

PlayerKit v1.0.rbxm (3.7 KB)

Hi everyone!!

I made PlayerKit, a lightweight module that automatically generates player data, loads it from DataStore, and saves it back when the player leaves.

Instead of writing dozens of lines inside Players.PlayerAdded, you only need one function.

Example

local PlayerKit = require(path.To.PlayerSettingGenerator)

Players.PlayerAdded:Connect(function(player)
	PlayerKit:SetUpCoreSetting(player)
end)

When the player leaves, simply save their data.

Players.PlayerRemoving:Connect(function(player)
	PlayerKit:CallUpSave(player)
end)

:sparkles: Features

  • :bar_chart: Automatic leaderstats generation
  • :floppy_disk: Automatic DataStore loading
  • :floppy_disk: Automatic DataStore saving
  • :file_folder: Permanent Inventory generation
  • :gear: Unlimited custom Configuration folders
  • :wrench: Easily expandable through config files
  • :puzzle_piece: Modular design

:open_file_folder: Included Modules

PlayerSettingGenerator
LeaderstatsConfig
PermanentInventoryConfig
OtherStatusConfig
DataStoreNames
DataSaveManager

:open_book: How to Use

:one: Leaderstats

Open LeaderstatsConfig.

return {
	Coin = {
		InstanceType = "IntValue",
		Start = 500,
		Name = "Coin"
	},

	Gem = {
		InstanceType = "IntValue",
		Start = 0,
		Name = "Gem"
	}
}

Adding a new leaderstat is as simple as adding another entry.

Level = {
	InstanceType = "IntValue",
	Start = 1,
	Name = "Level"
}

No other scripts need to be edited.


:two: Permanent Inventory

Open PermanentInventoryConfig.

return {
	Weapons = {
		"Sword",
		"Bow",
		"Hammer"
	}
}

PlayerKit automatically creates

PermanentInventoryFolder
└── Weapons
    ā”œā”€ā”€ Sword
    ā”œā”€ā”€ Bow
    └── Hammer

Each item is stored as a BoolValue.


:three: Custom Configurations

Need custom player settings?

Open OtherStatusConfig.

return {
	GemShop = {
		Name = "GemShop",

		AddToThis = {

			RebirthBoost = {
				InstanceType = "IntValue",
				Start = 0,
				Name = "RebirthBoost"
			}

		}
	}
}

This automatically creates

Player
└── GemShop
    └── RebirthBoost

You can create as many Configuration folders as you want.

Example:

return {

	GemShop = {
		Name = "GemShop",

		AddToThis = {

			RebirthBoost = {
				InstanceType = "IntValue",
				Start = 0
			}

		}
	},

	Settings = {
		Name = "Settings",

		AddToThis = {

			Music = {
				InstanceType = "BoolValue",
				Start = true
			},

			SFX = {
				InstanceType = "BoolValue",
				Start = true
			}

		}
	}

}

:four: DataStore Name

Open DataStoreNames.

return {
	CoreData = "CoreDataStore_V2"
}

Simply change the value to whatever DataStore name you want to use.


:five: Saving Data

Saving is just one line.

PlayerKit:CallUpSave(player)

PlayerKit automatically collects:

  • Leaderstats
  • Permanent Inventory
  • Custom Configurations

and sends everything to DataSaveManager.


:heart: Why I Made This

Every time I started a new project, I found myself rewriting the same player setup code over and over again.

With PlayerKit, I only need to edit configuration files whenever I add a new stat, inventory item, or custom setting.

This keeps my projects cleaner, easier to maintain, and much faster to set up.


:package: Planned Features

  • :counterclockwise_arrows_button: ProfileService support
  • :floppy_disk: AutoSave support
  • :bar_chart: More supported value types
  • :file_folder: Easier configuration system
  • :high_voltage: Performance improvements

:speech_balloon: Feedback

PlayerKit is still in development.

If you have any suggestions, ideas, or improvements, I’d love to hear them!

Thanks for reading! :rocket:

2 Likes

Cool stuff! I can see lots of people using this,

Thank You!

We will continue to roll out various updates, so we look forward to your continued support!

3 Likes

If there is anything you are dissatisfied with, I would greatly appreciate it if you could let me know so I can make improvements!!!

1 Like

You will run out of datastore storage very fast with this one
You should not be casually storing string keys
Instead you should store U8 opcodes inside buffer logic
Reinventing at most 400 lines of simple, lightweight, optimized code into framework slop that will make you powerless and make you surrender all understanding of logic into the framework
Never use middlewsare :raised_fist: :gear:

Thanks for the feedback!!! Ill definitely look into data optimization and buffers in the future. My current goal is to keep PlayerKit simple and beginner-friendly!