UnderminersTeam / UndertaleModTool

The most complete tool for modding, decompiling and unpacking Undertale (and other GameMaker games!)
GNU General Public License v3.0
1.18k stars 222 forks source link

Decompiler freezes on kinda complicated code. (Anon entries) #1224

Open Romualdo666 opened 1 year ago

Romualdo666 commented 1 year ago

Describe the bug

Been trying to import the code that looks like on the attached image; basically, when trying to compile, the decompiler stucks trying to compile the code and never ends. Pretty sure the problem is because you may see the complexity of it. But can't really tell how to call this. image I also tried using the Exporting and Importing code scripts, but on importing it just can't get to understand the code, again, because of its complexity.

Reproducing steps

  1. Just paste the code: function catch_error() //gml_Script_catch_error { exception_unhandled_handler(function(argument0) //gml_Script_anon_catch_error_gml_GlobalScript_catch_error_57_catch_error_gml_GlobalScript_catch_error { show_debug_message("--------------------------------------------------------------") show_debug_message(("Unhandled exception " + string(argument0))) show_debug_message("--------------------------------------------------------------") if file_exists("crash.txt") file_delete("crash.txt") var _f = file_text_open_write("crash.txt") file_text_write_string(_f, string(argument0)) file_text_close(_f) show_message(argument0.longMessage) return 0; } ) }

  2. Try to compile.

  3. Freeze

Setup Details

Latest version of Bleeding edge. Windows 11. Deltarune version 1.10

XDOneDude commented 1 year ago

its already fixed on utmtce

VladiStep commented 10 months ago

its already fixed on utmtce

But the changes are not in the "master" (not available in the "bleeding edge" version), also it has some bugs.

Jacky720 commented 8 months ago

This now produces the error System.NullReferenceException: Object reference not set to an instance of an object. rather than a freeze (apparently at AssemblyWriter line 1289).