Skip to content

Repository files navigation

scaffolding

📄 about

scaffolding is a template project structure for roblox studio, written in luau and based on my setup for a previous roblox project.

it should feature pretty much every essential component you need to kickstart a game on roblox, and works with any other framework for luau.

this repository only includes the .luau source files, with no UI or front-end code. this is because that way it's easier to just white-label this template or embed only the bits you need.

my personal recommendation for using scaffolding with UI is integrating with fusion. it is the library I used on most of my games' UI, and has worked pretty well for me despite being in development.

as per usual, none of my work here was made with AI.

🌠 highlights

refer to the table of contents for further guidance on how to use scaffolding.

  • 📂 managed data store
    • loading and saving with retry logic
    • data syncing between server and client for shared values
    • schema with support for data format migrations
    • modular managers so you don't have to mess with raw data
  • 🌐 networking
    • server and client validation with @rbxts/t (or anything else really)
    • asynchronous handlers for RemoteFunctions
    • permission guards for server endpoints
  • ⌨️ commands panel
    • data-driven command specifications
    • modular parameters system with type providers
    • automatic type inference for neat server-side code
    • support for running commands across servers with MessagingService
    • and on offline players too, for stuff like moderation commands
  • 🛡️ permission management
    • assign permissions based on external sources (like group ranks, gamepasses, etc.)
    • allow or deny permissions on a key-by-key basis
    • simple string key system, similar to minecraft permission plugins
  • 📦 persistent inventory
    • this can store items with any arbitrary data, not just tools
    • useful for things like gifted passes, player cosmetics, or really anything else
  • ⚙️ customizable settings
    • currently only supports strings, numbers and arbitrary values from a list
    • it's extendable though, you can add new option types easily
  • ⏱️ playtime tracking
    • it also stores the players' first session, last session and session count
  • 💵 currencies
    • supports more than just a single "coins" value if you need more types of currency
    • also has validation to prevent crazy invalid numbers in the data manager
  • 🔎 in-code documentation
    • most non-internal modules have comments explaining most methods for roblox studio
    • some also include usage examples, so it's easier to understand some of them

✏️ notes

  • you can use roblox studio's script sync feature to import this repository onto your DataModel.
  • some modules use type functions for fancy type inference (which I'm very proud of ^-^), so you may need to enable the new luau type solver in studio or LSP extensions.

About

A boilerplate project for kickstarting new Roblox Studio games with essential features most games have.

Resources

Stars

1 star

Watchers

0 watching

Forks

Contributors

Languages