Spoiler: sample codeTo reproduce, simply paste the above code into a decorate.txt file, -file it, and then use "Give invisible" from the console.
Without knowing which one is intended, I'm just going to drop this here. It may be that the weapon is supposed to vanish in both renderers, or that it's supposed to stay visible in both renderers, but right now, the two renderers do two different things, hence the bug report. If it's supposed to disappear then it's obviously a ZDoom bug and not a GZDoom bug, and I'll forward the report appropriately.