[0.18.17] Crash when accessing LuaPlayer.entity_copy_source while player is dead
Posted: Wed Apr 01, 2020 10:10 pm
Please see JustARandomGeek's first post below for a more succinct reproduction process.
Old Title: [0.18.17] Crash using "--instrument-mod" "debugadapter" in specific use case
I'm logging this here first rather than with JustARandomGeek as its a hard game crash. However, I fully appreciate that the issue is surfacing from the vsCode extension and so it may not be an interest to other than him.
With a the attached muppet_streamer mod extract it to a folder in the Factorio mods folder.
Open the mod folder in VS Code with the debug adpater.
Add a breakpoint on scripts\leaky-flamethrower.lua line 85.
Run the game within the VSCode debugger.
Start a new game
Kill the player: /c game.player.character.die()
Click respawn and before the respawn timer completes do the next step.
Run the command to trigger the mod replacing "muppet9010" with your player name: /muppet_streamer_leaky_flamethrower {"delay":0, "ammoCount":5, "target":"muppet9010"}
The breakpoint will be hit in VS Code
In VScode hover over the variable "targetPlayer" on the line 85.
Give the game a second and the game will crash.
Old Title: [0.18.17] Crash using "--instrument-mod" "debugadapter" in specific use case
I'm logging this here first rather than with JustARandomGeek as its a hard game crash. However, I fully appreciate that the issue is surfacing from the vsCode extension and so it may not be an interest to other than him.
With a the attached muppet_streamer mod extract it to a folder in the Factorio mods folder.
Open the mod folder in VS Code with the debug adpater.
Add a breakpoint on scripts\leaky-flamethrower.lua line 85.
Run the game within the VSCode debugger.
Start a new game
Kill the player: /c game.player.character.die()
Click respawn and before the respawn timer completes do the next step.
Run the command to trigger the mod replacing "muppet9010" with your player name: /muppet_streamer_leaky_flamethrower {"delay":0, "ammoCount":5, "target":"muppet9010"}
The breakpoint will be hit in VS Code
In VScode hover over the variable "targetPlayer" on the line 85.
Give the game a second and the game will crash.