MMDebug
MMDebug is a tool that allows you to quickly visualize and configure flags used in scripts.
If you are looking for the home page, please click here.
Configuring Flags
Flags are variables that can be modified and tracked by using MMDebug.
This allows you to create dynamic data that you can modify while testing. For example, you can make debugging systems that can be turned on and off at will.
Flags respect the client-server boundary and behave the same as normal variables by default.
MMDebug:SetFlag(script, "Example", true)
while true do
print(MMDebug:GetFlag(script, "Example"))
task.wait(1)
end
Flags accept all value types, although you should keep in mind that some data types might not be visualized correctly in the UI.
Usage

Opening and closing the MMDebug UI is simple - just type !mmdebug in the chat or use the /mmdebug chat command!
This UI allows you to see and modify the different flags.
You can change between Client and Server, search for flags and see the total amount of flags in the respective boundary (client or server).
Setting a value to nil will remove the flag. MMDebug UI respects the original value type when providing a new value for a flag.
When changing the value of a client flag, you can use the prefix "force " to make the change apply to all clients on the server.
Access Conditions
MMDebug UI is usable when in Studio. Players with server logs access can use MMDebug UI regardless of being in Studio or not.
By default, MMDebug is loaded into ReplicatedStorage.
Variables
Flags: table used to store flagsDescriptions: table used to store flag descriptionsEvents: Table used to store flag change eventsOnServerFlagsReceiveQueue: internal table used to store server flag receive callbacks
Functions
OnServerFlagsReceive(Callback | function)
Adds a callback to the server flag receive queue.
MMDebug:OnServerFlagsReceive(function()
print("Server flags have been updated!")
end)
SetFlag(From | Instance, Name | string, Value | any, Client | bool)
Creates or replaces a flag with the specified value. If used on the server and the Client parameter is set to true, all clients will be forced to change the flag.
MMDebug:SetFlag(script, "Example", false)
MMDebug:SetFlag("Example Flag", 0)
SetDescription(From | Instance, Name | string, Description | string)
Sets a description for a flag.
MMDebug:SetDescription(script, "Example", "An example flag under this script.")
MMDebug:SetDescription("Example Flag", "An example flag under no script.")
RemoveFlag(From | Instance, Name | string, Client | bool)
Removes a flag.
MMDebug:RemoveFlag("Example Flag")
OnChange(From | Instance, Name | string, Callback | function)
Creates a callback for a flag that runs whenever its value gets changed. Returns a function that removes the event upon being called.
local Disconnect = MMDebug:OnChange(script, "Example", function(New)
if New then
print("Toggled!")
MMDebug:SetFlag(script, "Example", false)
end
end)
task.wait(5)
Disconnect()
GetFlag(From | Instance, Name | string)
Returns the value of the specified flag.
local Value = MMDebug:GetFlag(script, "Example")