This commit is contained in:
Cooldude2606
2019-07-23 17:46:49 +01:00
parent 604fb66f46
commit 9ecd0cca0d
150 changed files with 15734 additions and 1895 deletions

View File

@@ -1,13 +1,10 @@
--- This file contains some common command param parse functions
-- this file is less of a config and more of a requirement but you may wish to change how some behave
-- as such you need to be confident with lua but you edit this config file
-- use Commands.add_parse('name',function(input,player,reject) end) to add a parse
-- see ./expcore/commands.lua for more details
local Commands = require 'expcore.commands' --- @dep expcore.commands
local Game = require 'utils.game' --- @dep utils.game
--[[
>>>>Adds Parses:
--[[-- This file contains some common command param parse functions;
this file is less of a config and more of a requirement but you may wish to change how some behave;
as such you need to be confident with lua but you edit this config file;
use Commands.add_parse('name',function(input,player,reject) end) to add a parse;
see ./expcore/commands.lua for more details
@config Commands-Parse
@usage Adds Parses:
boolean
string-options - options: array
string-max-length - max_length: number
@@ -22,6 +19,11 @@ local Game = require 'utils.game' --- @dep utils.game
surface
]]
local Commands = require 'expcore.commands' --- @dep expcore.commands
local Game = require 'utils.game' --- @dep utils.game
Commands.add_parse('boolean',function(input,player,reject)
if not input then return end -- nil check
input = input:lower()