From bb28f5658f722e219a05ef45349546c257501ea9 Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Mon, 28 Dec 2020 18:58:40 +0100 Subject: [PATCH] Adding .bam/utils.lua --- .bam/utils.lua | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .bam/utils.lua diff --git a/.bam/utils.lua b/.bam/utils.lua new file mode 100644 index 0000000..ff4957f --- /dev/null +++ b/.bam/utils.lua @@ -0,0 +1,10 @@ + +-- Returns True if 'table' contains the value 'val'. False otherwise. +function contains(table, val) + for i=1, #table do + if table[i] == val then + return true + end + end + return false +end