From a67c28ca94c319f0416d5e4f080bb27482500ce8 Mon Sep 17 00:00:00 2001 From: Lucas Schwiderski Date: Wed, 22 Feb 2023 09:41:28 +0100 Subject: [PATCH] chore: Initialize mod --- .luacheckrc | 44 +++++++++++++++++++++++++++++++++++++++ dtmt.cfg | 16 ++++++++++++++ packages/dml.package | 3 +++ scripts/mods/dml/init.lua | 1 + 4 files changed, 64 insertions(+) create mode 100644 .luacheckrc create mode 100644 dtmt.cfg create mode 100644 packages/dml.package create mode 100644 scripts/mods/dml/init.lua diff --git a/.luacheckrc b/.luacheckrc new file mode 100644 index 0000000..552b17e --- /dev/null +++ b/.luacheckrc @@ -0,0 +1,44 @@ +max_line_length = 120 + +include_files = { + "scripts/", +} + +ignore = { + "12.", -- ignore "Setting a read-only global variable/Setting a read-only field of a global variable." + "542", -- disable warnings for empty if branches. These are useful sometime and easy to notice otherwise. + "212/self", -- Disable unused self warnings. +} + +std = "+DT" + +stds["DT"] = { + read_globals = { + string = { fields = { "split" }}, + table = { fields = { + "merge", "table_to_array", "mirror_table", "tostring", "is_empty", "array_to_table", "reverse", "shuffle", + "merge_recursive", "unpack_map", "remove_unordered_items", "append", "mirror_array_inplace", "size", "dump", + "clear_array", "append_varargs", "find", "for_each", "crop", "mirror_array", "set", "create_copy", "clone", + "contains", "add_meta_logging", "table_as_sorted_string_arrays", "clone_instance", "max", "clear", "find_by_key", + }}, + math = { fields = { + "ease_exp", "lerp", "polar_to_cartesian", "smoothstep", "easeCubic", "round", "point_is_inside_2d_triangle", + "radians_to_degrees", "circular_to_square_coordinates", "uuid", "easeInCubic", "round_with_precision", + "clamp", "get_uniformly_random_point_inside_sector", "angle_lerp", "ease_out_exp", "rand_normal", + "bounce", "point_is_inside_2d_box", "catmullrom", "clamp_direction", "ease_in_exp", "random_seed", + "sign", "degrees_to_radians", "sirp", "ease_pulse", "cartesian_to_polar", "ease_out_quad", + "easeOutCubic", "radian_lerp", "auto_lerp", "rand_utf8_string", "point_is_inside_oobb", + }}, + Managers = { fields = { + "mod", "event", "chat" + }}, + Mods = { fields = { + lua = { fields = { "debug", "io", "ffi", "os" }}, + "original_require", + "require_store", + }}, + "Crashify","Keyboard","Mouse","Application","Color","Quarternion","Vector3","Vector2","RESOLUTION_LOOKUP", + "ModManager", "Utf8", "StateGame", "ResourcePackage", "class", "Gui", "fassert", "printf", "__print", "ffi", + }, +} + diff --git a/dtmt.cfg b/dtmt.cfg new file mode 100644 index 0000000..3831232 --- /dev/null +++ b/dtmt.cfg @@ -0,0 +1,16 @@ +id = "dml" +name = "Darktide Mod Loader" +description = "This is my new mod 'Darktide Mod Loader'!" +version = "0.1.0" + +resources = { + init = "scripts/mods/dml/init" +} + +packages = [ + "packages/dml" +] + +depends = [ + "dmf" +] diff --git a/packages/dml.package b/packages/dml.package new file mode 100644 index 0000000..1bd97ef --- /dev/null +++ b/packages/dml.package @@ -0,0 +1,3 @@ +lua = [ + "scripts/mods/dml/*" +] diff --git a/scripts/mods/dml/init.lua b/scripts/mods/dml/init.lua new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/scripts/mods/dml/init.lua @@ -0,0 +1 @@ +