commit 83ecdc1173811c7d61f0e14508c959a3e9df806a Author: Fesiug Date: Sun Sep 3 09:31:16 2023 -0400 Initial commit diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..dfe0770 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Auto detect text files and perform LF normalization +* text=auto diff --git a/README.md b/README.md new file mode 100644 index 0000000..baae44e --- /dev/null +++ b/README.md @@ -0,0 +1,2 @@ +# benny + Your Name Is Benny diff --git a/gamemodes/benny/benny.txt b/gamemodes/benny/benny.txt new file mode 100644 index 0000000..f68805d --- /dev/null +++ b/gamemodes/benny/benny.txt @@ -0,0 +1,11 @@ +"benny" +{ + "base" "base" + "title" "Your Name Is Benny" + "maps" "^benny_" + "category" "other" + "menusystem" "1" + "settings" + { + } +} \ No newline at end of file diff --git a/gamemodes/benny/gamemode/cl_init.lua b/gamemodes/benny/gamemode/cl_init.lua new file mode 100644 index 0000000..e9b3797 --- /dev/null +++ b/gamemodes/benny/gamemode/cl_init.lua @@ -0,0 +1,4 @@ + +-- Thing + +include( "shared.lua" ) \ No newline at end of file diff --git a/gamemodes/benny/gamemode/init.lua b/gamemodes/benny/gamemode/init.lua new file mode 100644 index 0000000..c3a2ec9 --- /dev/null +++ b/gamemodes/benny/gamemode/init.lua @@ -0,0 +1,7 @@ + +-- Thing + +AddCSLuaFile( "cl_init.lua" ) +AddCSLuaFile( "shared.lua" ) + +include( "shared.lua" ) \ No newline at end of file diff --git a/gamemodes/benny/gamemode/shared.lua b/gamemodes/benny/gamemode/shared.lua new file mode 100644 index 0000000..dc053a1 --- /dev/null +++ b/gamemodes/benny/gamemode/shared.lua @@ -0,0 +1,37 @@ + +-- Thing + +GM.Name = "Your Name Is Benny" +GM.Author = "Fesiug, Oranche" +GM.Email = "N/A" +GM.Website = "N/A" + +-- Load modules +local path = GM.FolderName .. "/gamemode/modules/" +local modules, folders = file.Find(path .. "*", "LUA") + +for _, folder in SortedPairs(folders, false) do + if folder == "." or folder == ".." then continue end + + -- Shared modules + for _, f in SortedPairs(file.Find(path .. folder .. "/sh_*.lua", "LUA"), false) do + AddCSLuaFile(path .. folder .. "/" .. f) + include(path .. folder .. "/" .. f) + end + + -- Server modules + if SERVER then + for _, f in SortedPairs(file.Find(path .. folder .. "/sv_*.lua", "LUA"), false) do + include(path .. folder .. "/" .. f) + end + end + + -- Client modules + for _, f in SortedPairs(file.Find(path .. folder .. "/cl_*.lua", "LUA"), false) do + AddCSLuaFile(path .. folder .. "/" .. f) + + if CLIENT then + include(path .. folder .. "/" .. f) + end + end +end \ No newline at end of file