Closed Deirel closed 1 year ago
After conducting some research, I discovered that if I run the following code:
local debugger = require('debugger.debugger')
debugger.start()
instead of:
require('debugger.debugger').start()
then the error disappears and the build starts successfully.
Not really sure why is it so, but FYI.
Very strange, because it's pretty much the same thing.
Maybe the problem is in the Defold analyser of required modules. Yes, it analyzes the require()
uses before building the game.
Anyway, it's more correct to assign to a local variable first. There is no need for such minification here. Besides, it was like that earlier in the guide.
So I will change it to the variant that works for you. Thanks!
Confirmed, it's a bug in Defold — https://github.com/defold/defold/issues/7963.
I have added the "debugger" script to the main collection, as stated in the instructions. Running a debug session from VS Code works great. However, when I try to run the build from the Defold Editor by pressing Ctrl+B, the following logs appear in the console:
Defold is fairly new to me, so perhaps I'm missing something obvious?