CAE Development Documentation

Ceazy Admin Essentials Development Documentation

Ceazy Admin Essentials is an admin system inspired by Basic Admin Essentials. Ceazy Admin Essentials is created by Ceazy Technologies, which you can find the roblox group here: Ceazy - Roblox

Other owners apart of this group are:
NotGlyphy
Dark

You can recieve the model once CAE’s development has been finished.

Although this code may look similar to BAE’s Code, I didn’t actually copy any of the code used from BAE’s Module or look at it for this development, I coded all this from scratch.

Plugin Command Development:

local Plugin = {
	CommandName = '',
	MultiArgSplit = {
		Type = 'Default',
		SplitKey = ',',
		-- If type is Default, it will return to the already set one.
		-- If set to custom, it will run off the SplitKey in this table.
	},
	SplitKey = {
		Type = 'Default',
		SplitKey = ' ',
		-- If type is Default, it will return to the already set one.
		-- If set to custom, it will run off the SplitKey in this table.
	},
	Prefix = {
		Type = 'Default',
		Prefix = '', -- Only used if Prefix type is set to Custom
	},
	Requirements = {
		{AdminLevel = 5, Func = function() if script == nil then return true end end, UserIds = nil, AccAge = nil},
		
	},
	Display = {
		DisplayInCommandList = true, -- Whether or not it can appear in the command list.
		-- If set to true, it'll display based off the Display Permissions.
		-- If set to false, this will never display in commands list,
		-- however this doesn't affect the command functionality.

		DisplayPermissions = {
			--{Type = 'Func', Func = function() return false end,2},
			{Type = 'Permitted',3}, -- If this table is not here, having permission to use the command
			-- doesn't mean this will display.
			--{Type = 'All'}, If this table is in DisplayPermissions, everyone will see the command in commands list.
			-- This doesn't change their permission to use it.
			--{Type = 'UserIDs', UserIDs = {},1},-- Any user ID in this table will be able to see the command.
			--{Type = 'AdminLevel', AdminLevels = {},1}, -- Anyone with any admin level that's in the AdminLevels table will be able to see this.
			--{Type = 'AccAge',AccAge = {BoolType = '>=',Age = 30}1,} -- Anybody with the account age or (higher/lower/higherorequal/lowerorequal/equal to the account age)
			-- will be able to see the command
		},
	},
}

function Plugin:FireEvent(Player,Message,Args,Funcs)
	
end

return Plugin

This is the structure of creating a custom command.

Command Name is the command you will have to type and the name that displays in command list.
MultiArgSplit is if you want to create multi args into one for example:

:kick User1,User2,User3

, is the MultiArgSplit (Which can be changed in Config, or you can make the Command use a custom one rather than the one set in Config)

For the numbers in the last argument for display permissions & command permissions. Heres what each one means:
1 - The table grants the permission UNLESS theres a required factor (meaning one of the permissions has 2 as the last argument)
2 - That factor is required.
3 - This gives the permission even if there are other requirements arent met.

How this works is: Everything that is required is checked, and if either all requirements are true, there are no requirements and the Player running the command met one of the factors in the permissions, or they met a factor that bypasses all requirements, then they have the permission (either display permission or command permission, depending on if its in DisplayPermissions table or Requirements table.

The rest in the Plugin table is pretty much self-explanatory, but if you have any questions feel free to comment on this post or you can message me through dev forum messages.

Now for the Plugin function, which is in here (At the bottom of the code)

Plugin:FireEvent(Player,Message,Args,Key,Funcs)
	
end

Player returns as the player who used the comand.
Message is the message of the exact thing they either typed in chat, or typed in the command bar.
Args is the list of arguments, so pretty much a table which contains every argument used which is divided by the splitkey.
Funcs is a table with the different function used for filtering arguments.

Here’s an example:

function Plugin:FireEvent(Player,Message,Args,Funcs)
	local TargetPlayer = Funcs.GetPlayer(Args[2])
	local SpecifiedTeam = Funcs.GetTeam(Args[3])
	local SpecifiedTool = Funcs.GetTool(Args[4])
end

When filtering players, it searches if the argument has multi-arguments, like any argument filtering check.
So for example, when the code filters through each argument, it repeats the same function on each multi arg if you have some seperated from multi arg split key but still in the same arg.

Just in case you’re wondering about where it finds the tool, it goes based off the configs ToolStorage, which defines where any command in relation to tools checks.

Those were for filtering arguments, there’s a lot more you can do with the Funcs table, and I’ll be listing all of them:

Funcs:CreateList(TargetPlayer,'Title',{'ListElement1'},specifyTable,true,true,15)

This creates a list with the specified title, and loops through the table and creates a new text label with the string.

specifyTable would be replaced with a table of strings that it refers to when the list is refreshed.

Third argument decides whether or not you want a refresh button to display. If auto-refresh is on it will still refresh but the button wont be displayed, meaning you cant refresh it and mist wait for auto-refresh.

Fourth argument is if you want auto-refresh enabled.

Fifth argument is the duration in seconds for auto-refresh.

Funcs:CreateConfirmationPrompt(TargetPlayer,'Would you like to confirm ...?', CancelFunc = function() end, ConfirmFunc = function() end)
Funcs:CreateServerConfirmationPrompt('Would you like to confirm ...?', CancelFunc = function() end, ConfirmFunc = function() end)
Funcs:CreateCountdown(5,function() print('Started countdown') end,function() print ('Countdown finished') end)
Funcs:CreatePM(TargetPlayer,'PM Title', 'PM Message', 'Message Title', 'Description')
Funcs:CreateNotice(TargetPlayer,'Notice Title', 'Notice Message')
Funcs:CreateHint(TargetPlayer, 'Title','Description')
Funcs:CreateServerHint('Title','Description')
Funcs:CreateServerMessage('Title', 'Message')
Funcs:CreateMessage(TargetPlayer,'Title', 'Message')

For ‘TargetPlayer’, those are for functions that you specify what player you want to see the UI.

CreateMessage is the same as CreateServerMessage except only the specified player sees it.

CreateServerHint creates a hint to all players.

The reasoning for the functions replicating all the Uis to the server is made for an easy way to affectnall players without having to loop through each player, and a faster way to get it to the users screen.

Looping through each player:

  • Players won’t recieve it at the same time

The function apart of CAE:

  • Puts the UI in StarterGui so each client connects it to the player GUI around the same time, unless they have slower connection.

More will be added to this post as the development continues
(What I mean by ‘development documentation’ is a documentation on how to do certain developer related stuff with CAE)

As more is added this will be updated so that there’s a better understanding on how to use CAE.

3 Likes