Thanks Again MrPresident!
The example is outputting an error.
This error being : bad argument #1 to 'upper' (string expected, got nil)
Would you happen to know what might be able to fix this
Example command:
local CATEGORY_NAME = "TEST"
function ulx.test_command( calling_ply, target_player )
local ply = nil
if player.GetBySteamID( target_ply ) then ply = player.GetBySteamID( target_ply ) end
if ULib.getUser( target_ply ) then ply = ULib.getUser( target_ply ) end
if IsValid( ply ) then
target_ply:SendLua([[RunConsoleCommand("retry")]])
ulx.fancyLogAdmin( calling_ply, "#A has reconnected #T", target_ply )
else
ULib.tsayError( calling_ply, "ERROR.", true )
end
end
local test_command = ulx.command( CATEGORY_NAME, "ulx test", ulx.test_command, "!testcommand" )
test_command:addParam{ type=ULib.cmds.StringArg, hint="Player Name or SteamID", ULib.cmds.takeRestOfLine }
test_command:defaultAccess( ULib.ACCESS_ADMIN )
test_command:help( "Test Command" )