From 3db6a9b490ae3fb0673a2ec1508fab5cc861f56c Mon Sep 17 00:00:00 2001 From: MiranDMC Date: Fri, 29 Nov 2024 15:57:17 +0100 Subject: [PATCH] :memo: update commands --- sa/sa.json | 54 ++++++++++++++++++++++++++---------- sa/snippets/default/2707.txt | 1 + sa/snippets/math/2706.txt | 2 +- sa/version.txt | 2 +- 4 files changed, 42 insertions(+), 17 deletions(-) create mode 100644 sa/snippets/default/2707.txt diff --git a/sa/sa.json b/sa/sa.json index 9063f5a1a..cb634e5f6 100644 --- a/sa/sa.json +++ b/sa/sa.json @@ -1,7 +1,7 @@ { "meta": { - "last_update": 1732890937089, - "version": "0.797", + "last_update": 1732892219549, + "version": "0.798", "url": "https://library.sannybuilder.com/#/sa" }, "extensions": [ @@ -46665,6 +46665,30 @@ "attrs": { "is_condition": true } + }, + { + "input": [ + { + "name": "values", + "type": "arguments" + } + ], + "output": [ + { + "name": "result", + "type": "string", + "source": "var_any" + } + ], + "id": "2707", + "name": "PICK_RANDOM_TEXT", + "num_params": 2, + "class": "Math", + "attrs": { + "is_static": true + }, + "member": "RandomPick", + "short_desc": "Selects one random text from provided values" } ] }, @@ -63463,8 +63487,8 @@ "name": "PICK_RANDOM_INT", "num_params": 2, "class": "Math", - "member": "PickRandomInt", - "short_desc": "Selects one random number from provided values", + "member": "RandomPick", + "short_desc": "Selects one random integer from provided values", "attrs": { "is_static": true } @@ -63472,26 +63496,26 @@ { "input": [ { - "name": "", - "type": "float" - }, - { - "name": "", - "type": "float" + "name": "values", + "type": "arguments" } ], "output": [ { - "name": "", + "name": "result", "type": "float", "source": "var_any" } ], "id": "2706", - "name": "FLOAT_SUB", - "num_params": 3, - "operator": "-", - "short_desc": "Subtracts the float value from another float value and writes the result into the variable" + "name": "PICK_RANDOM_FLOAT", + "num_params": 2, + "attrs": { + "is_static": true + }, + "class": "Math", + "member": "RandomPick", + "short_desc": "Selects one random float from provided values" }, { "input": [ diff --git a/sa/snippets/default/2707.txt b/sa/snippets/default/2707.txt new file mode 100644 index 000000000..b036cefae --- /dev/null +++ b/sa/snippets/default/2707.txt @@ -0,0 +1 @@ +LongString greeting = pick_random_text {values} "Hello!" "Hi there!" "Welcome!" \ No newline at end of file diff --git a/sa/snippets/math/2706.txt b/sa/snippets/math/2706.txt index 42c954fb4..7e5fea081 100644 --- a/sa/snippets/math/2706.txt +++ b/sa/snippets/math/2706.txt @@ -1 +1 @@ -<%= output1 %> = <%= input1 %> - <%= input2 %> \ No newline at end of file +float heading = pick_random_float {values} 0.0 90.0 -90.0 180.0 -180.0 \ No newline at end of file diff --git a/sa/version.txt b/sa/version.txt index c83ba92e4..f862c28f9 100644 --- a/sa/version.txt +++ b/sa/version.txt @@ -1 +1 @@ -0.797 \ No newline at end of file +0.798 \ No newline at end of file