From ef0440905d394c7c556d35414e9dda3202ea5149 Mon Sep 17 00:00:00 2001 From: cpunch Date: Sat, 16 Aug 2025 21:03:51 -0500 Subject: [PATCH] updated macro docs to provide example output --- content/docs/macros/MV_INDEX_TO_NUM.md | 10 ++++++++++ content/docs/macros/MV_LINE.md | 9 ++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/content/docs/macros/MV_INDEX_TO_NUM.md b/content/docs/macros/MV_INDEX_TO_NUM.md index 5e64679..0434dea 100644 --- a/content/docs/macros/MV_INDEX_TO_NUM.md +++ b/content/docs/macros/MV_INDEX_TO_NUM.md @@ -20,3 +20,13 @@ for i = 1, 10 do end return foo.total ``` + +Obfuscates to: + +```lua +local a={[19314]=0} +for b=1,10 do + a[19314]=a[19314]+b +end +return a[19314] +``` \ No newline at end of file diff --git a/content/docs/macros/MV_LINE.md b/content/docs/macros/MV_LINE.md index db420ed..d82f313 100644 --- a/content/docs/macros/MV_LINE.md +++ b/content/docs/macros/MV_LINE.md @@ -19,4 +19,11 @@ will be replaced with a number constant representing the current line. local a = MV_LINE print(a, MV_LINE) ``` -> prints `1 2` \ No newline at end of file + +Obfuscates to: + +```lua +print(1,2) +``` + +{{% alert context="info" text="**Note**: the 'a' local got folded yet retains the original line number" /%}}