From fddeb72e9d7d6358f7c7300892e2412b65aa6c51 Mon Sep 17 00:00:00 2001 From: NovaRain Date: Tue, 22 Dec 2020 17:01:46 +0800 Subject: [PATCH] Added new opcodes sfall_func7 and sfall_func8 --- CHANGELOG.md | 3 +++ Opcode.h | 3 +++ OpcodeAttributes.cpp | 3 +++ main.cpp | 2 +- 4 files changed, 10 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 746827c..cec0fc6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ int2ssl ===== +#### 8.4.6 +- Added support for additional universal opcodes `sfall_func7` and `sfall_func8` + #### 8.4.5 - Added new logical operators `AndAlso`, `OrElse` - Added support for new `div` operator (unsigned integer division) diff --git a/Opcode.h b/Opcode.h index ff78a51..2de00b2 100644 --- a/Opcode.h +++ b/Opcode.h @@ -765,6 +765,9 @@ public: O_TS_REGISTER_HOOK_PROC2, O_TS_REG_ANIM_CALLBACK, O_TS_DIV, + + O_TS_SFALL_METARULE7, + O_TS_SFALL_METARULE8, //sfall end O_END_OP diff --git a/OpcodeAttributes.cpp b/OpcodeAttributes.cpp index 3655b70..c8a7820 100644 --- a/OpcodeAttributes.cpp +++ b/OpcodeAttributes.cpp @@ -806,6 +806,9 @@ COpcode::CF2OpcodeAttributesMap::CF2OpcodeAttributesMap() SetAt(O_TS_REG_ANIM_CALLBACK, COpcodeAttributes("O_TS_REG_ANIM_CALLBACK", "reg_anim_callback", 1, COpcodeAttributes::TYPE_STATEMENT, COpcodeAttributes::CATEGORY_PREFIX, &procArgs[0], 1)); // sfall 4.2.3/3.8.23 SetAt(O_TS_DIV, COpcodeAttributes("O_TS_DIV", "div", 2, expression, infix)); // the operator for unsigned division + // sfall 4.2.9/3.8.29 + SetAt(O_TS_SFALL_METARULE7, COpcodeAttributes("O_TS_SFALL_METARULE7", "sfall_func7", 8, expression)); + SetAt(O_TS_SFALL_METARULE8, COpcodeAttributes("O_TS_SFALL_METARULE8", "sfall_func8", 9, expression)); // sfall end SetAt(O_STRINGOP, COpcodeAttributes("O_STRINGOP", "", 0, expression)); diff --git a/main.cpp b/main.cpp index 33485a7..bb701ea 100644 --- a/main.cpp +++ b/main.cpp @@ -41,7 +41,7 @@ bool ProcessCommandLine(int argc, char* argv[]); int main(int argc, char* argv[]) { - std::cout << "Fallout script decompiler, version 8.4.5 (sfall edition)" << std::endl + std::cout << "Fallout script decompiler, version 8.4.6 (sfall edition)" << std::endl << "Copyright (C) Anchorite (TeamX), 2005-2009" << std::endl << "anchorite2001@yandex.ru" << std::endl << "Continued by Nirran, phobos2077, Mr.Stalin (2014-2020)" << std::endl