Zandronum Chat on our Discord Server Get the latest version: 3.2
Source Code

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002510Zandronum[All Projects] Suggestionpublic2015-10-30 22:242025-04-11 14:05
ReporterEmpyre 
Assigned ToDrinkyBird 
PrioritynormalSeverityminorReproducibilityalways
StatusfeedbackResolutionfixed 
PlatformMicrosoftOSWindowsOS VersionXP/Vista/7
Product Version2.0 
Target VersionFixed in Version 
Summary0002510: Please implement voodoo dolls in single-player with multiplayer emulation.
DescriptionIn single-player, there are fewer monsters and I don't respawn when I die. In client/server I can neither pause nor save the game. Single-player with multiplayer emulation has the best of both worlds and it is my favorite way to play when I want to play alone, except for one rather big issue, maps that depend on voodoo dolls are broken.
I mentioned this in the forums, and was told that voodoo dolls were never implemented in single-player with multiplayer emulation.
Steps To ReproduceOpen the test map in single-player with multiplayer emulation (coop) and use the switch, and then the voodoo doll should open the door. If the door doesn't open, voodoo dolls are broken.
Additional InformationA fix for this would make my day/week/year. It is also limiting my mapping because I feel like I can't use voodoo dolls in my maps since they would be broken, too. The problem is major for me, but I chose minor because I am probably in the minority using this mode.
Attached Fileszip file icon voodoodolltest.zip [^] (1,916 bytes) 2015-10-30 22:24
? file icon voodoodolltest_fixed.wad [^] (4,406 bytes) 2025-03-20 11:00
zip file icon CrashReport.zip [^] (27,091 bytes) 2025-03-24 14:32
? file icon voodoodolltest_fixed_02.wad [^] (4,626 bytes) 2025-03-26 12:21
? file icon voodoodolltest_fixed_03b.wad [^] (5,200 bytes) 2025-03-30 17:56
zip file icon CrashReport_02.zip [^] (26,380 bytes) 2025-04-08 11:08
zip file icon CrashReport_03.zip [^] (26,311 bytes) 2025-04-08 12:13

- Relationships

-  Notes
User avatar (0016765)
Empyre (reporter)
2017-02-06 01:08

This is a pet peeve of mine and I worry that this feature request might have been forgotten. Surely I am not the only player who uses single-player with multiplayer emulation. It is awesome except for the lack of voodoo doll support.
User avatar (0019186)
Empyre (reporter)
2018-05-02 15:49

Since you are working on a new version (3.1), now is the time for feature requests. I wanted to bring this to your attention, but I don't want to be annoying, so I promise not to bump this again this year.
User avatar (0022941)
StrikerMan780 (reporter)
2023-12-31 11:04

Currently helping a friend make a mod that requires multiplayer emulation enabled to play properly in SP (as it uses survival's lives system with 1-ups), and not having voodoo dolls working in this mode breaks a majority of megawads.
User avatar (0024240)
DrinkyBird (developer)
2025-03-06 23:08

'https://foss.heptapod.net/zandronum/zandronum-stable/-/merge_requests/269 [^]'
User avatar (0024262)
unknownna (updater)
2025-03-20 11:08

The example wad had the player starts reversed so I fixed it.

* The voodoo doll works well, but if you start the game as a netgame or use "map map01" after enabling multiplayer emulation, exiting the map causes your player to lose all weapons in the next map.
* Entering the map as a spectator in multiplayer emulation still doesn't have working voodoo dolls. This also seems to happen online actually. Is this intended? I think maps will break with this behavior.
User avatar (0024306)
DrinkyBird (developer)
2025-03-24 11:55
edited on: 2025-03-24 12:06

Quote
The voodoo doll works well, but if you start the game as a netgame or use "map map01" after enabling multiplayer emulation, exiting the map causes your player to lose all weapons in the next map.


I can't seem to reproduce this. nevermind, I can now. Does this also happen online? I guess it's carrying the inventory of the player over from the voodoo doll rather than their real body.

Quote
Entering the map as a spectator in multiplayer emulation still doesn't have working voodoo dolls. This also seems to happen online actually. Is this intended? I think maps will break with this behavior


If sv_coopunassignedvoodoodolls is off, voodoo dolls only spawn when the map starts or a player connects to the server (not joins the game). I guess it should be made so they spawn on join as well.

I did some additional testing assisted by Dark-Assassin and most of the quirks with voodoo dolls are either Doom behaviour or just unrelated to multiplayer emulation specifically. (I marked the ticket as resolved before I saw your response...) Notably Plutonia MAP06 doesn't give weapons - but this doesn't work in vanilla co-op either, and in GZD 1.8.6 it only gives to the highest-idx player.

User avatar (0024307)
unknownna (updater)
2025-03-24 12:22

Quote from DrinkyBird
I can't seem to reproduce this.


I see, could you try the steps below with your latest fix and see if it happens to you? When I enter MAP02 after pressing the exit switch, the player spawns without the pistol. This only happens during multiplayer emulation offline.

1. zandronum -file voodoodolltest_fixed.wad +netgame +map map01
2. Go press the switch to open the door to the exit switch.
3. Press the exit switch and it will spawn you in MAP02 without any weapons.

Quote from DrinkyBird
This is how voodoo dolls are handled in coop, if sv_coopunassignedvoodoodolls is off [...]


Interesting, toggling this on and off doesn't seem to change the behavior with the example wad. No matter what it's set to, the voodoo doll is not spawned if the map is entered with spectators only.
User avatar (0024308)
DrinkyBird (developer)
2025-03-24 13:36
edited on: 2025-03-24 13:54

Yeah, I reproduced the inventory bug. Turns out if you enable MP emulation, then map map01, the real player body doesn't spawn with any inventory, but you can still raise and use a pistol. Notice how you can't switch to the fist either. Then when you go to map02 it properly reflects your lack of inventory. Weird.

edit: ok, I think I figured it out. The issue is that the player inventory isn't being copied from the voodoo doll (since the inventory is given to the first voodoo doll when it spawns, then is copied in a chain for each player body that spawns, up until the real one). This is due to this specific if statement, which unsets the player's mo if not in pure singleplayer, causing it to lose track of which body to copy the inventory from.

User avatar (0024309)
DrinkyBird (developer)
2025-03-24 14:07

'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/92624de40cf47ab200d0d2837cd76d8e6a365ff0 [^]' should fix the inventory bug, although I have no idea why that
NETWORK_GetState( ) != NETSTATE_SINGLE
condition was there as it predates the source control history. The player's mobj is set to null at the start of P_SetupLevel (before spawning dolls) so I don't think this should cause other issues.
User avatar (0024310)
unknownna (updater)
2025-03-24 14:17

Hey, I tested the pipeline build and it still seems to be broken, on top of not displaying any ammo, and crashing the client if you try to fire the pistol in the example wad.
User avatar (0024311)
DrinkyBird (developer)
2025-03-24 14:28

That is worrying... I tried with both my local Linux build and the automatic Win64 build and it seems to work fine for me. If I enable multiplayer emulation then map map01, I have all ammo and keep my inventory after exiting into the next map. I am very confused.
User avatar (0024312)
unknownna (updater)
2025-03-24 14:32
edited on: 2025-03-24 14:34

Hmm, I always use the Win32 builds when I test, does that make a difference?

I just followed the steps above: zandronum -file voodoodolltest_fixed.wad +netgame +map map01

And it reproduces the crash and missing ammo counter. I also uploaded a crash report if it helps.

I tested the 64 bit build and it also crashes there for me.

User avatar (0024314)
DrinkyBird (developer)
2025-03-24 17:10
edited on: 2025-03-24 17:13

Ah, it happens when unassignedvoodoodolls is on. This is because the voodoo doll is spawned as a voodoo doll for the actual player at the relevant index, then gets yanked away to the dummy player, but the real player's mobj still points to the voodoo doll, causing things to break when it takes ownership of the doll's inventory.

The best solution is probably to just to spawn the dolls for the dummy player instead of transferring them from a real player to the dummy player. That way there's no inventory transfer shenanigans since they're entirely separate.

Give'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/bbc2613b718a70bde0db995fd2ced55a55703501 [^]' a try. This includes the previous commit as well, since that fixed the inventory issue when unassigned dolls were off (there, we need to transfer the inventory from a player's doll to their real body.)

User avatar (0024315)
unknownna (updater)
2025-03-24 17:32
edited on: 2025-03-24 17:48

I gave the latest fix a try, and while it seems to have fixed the crash and missing ammo counter, the player still only gets the pistol and can't select the fist, and still loses the weapons in the next map in the example wad.
Using "printinv" shows that there's no actual inventory present for the player.

Edit:
Scratch that, I double checked and was possibly testing with the wrong build. Re-downloaded and can confirm it's working.

One big problem, the server crashes immediately if you try start it with the example wad loaded.

User avatar (0024316)
DrinkyBird (developer)
2025-03-24 19:13
edited on: 2025-03-24 19:16

Thanks. This amended version should fix that server crash:'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/b616cbcd86130661f2ff652dc042a2b8d4ee2e5a [^]'

edit: updated to the right commit

User avatar (0024317)
unknownna (updater)
2025-03-24 20:01

Thanks, that took care of the issues.

I noticed one minor issue that only happens offline in multiplayer emulation when sv_coopunassignedvoodoodolls is 0: There's no respawn protection for the local player when using "map map01".
User avatar (0024359)
DrinkyBird (developer)
2025-03-26 11:03

This should fix the respawn invulnerability:'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/44a42932edb45668cb8a887ce34bb90e9d5c8adb [^]'
User avatar (0024360)
unknownna (updater)
2025-03-26 12:21

That seems to have fixed that particular problem, however I noticed that the server no longer gives its inventory to players when the voodoo doll picks them up with "sv_coopunassignedvoodoodolls 1", unlike 3.1.

In the updated example wad, the voodoo doll picks up:

- all keys
- a megasphere
- a backpack
- a SSG
- a radiation suit

On a site note, I was a bit confused myself when testing this, as it turns out you have to enable "alwaysapplydmflags 1" to make the respawn invul appear. Doom Explorer sets this automatically for me when I test through it, but when using the command line it has to be explicitly enabled from the looks of it. I was about to state I discovered a separate problem until I realized this.
User avatar (0024363)
DrinkyBird (developer)
2025-03-29 20:35

Thanks for the updated WAD. I fixed that and a few other edge cases that unveiled, here is the latest commit:'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/85190c3b403fd0925c485ac8ebb1618410ae7794 [^]'

This doesn't print the pickup messages or play the pickup sound when an unassigned voodoo doll picks up an item in multiplayer emulation. I'm averse to duplicating the code for that later in AInventory::Touch, and so long as it gives the items at all I think it's good enough for now.
User avatar (0024364)
unknownna (updater)
2025-03-29 22:16

I tested it briefly, and it seems to give the pickups when the voodoo doll picks them up, but it doesn't remember the weapon and key pickups like it's supposed to, if I'm not mistaken. See this commit.

And the server now crashes again if you start one with the example wad.
User avatar (0024366)
DrinkyBird (developer)
2025-03-29 23:48

Should fix both:'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/8a522ad257d3dcfdd8f5619409311cb18189b289 [^]'
User avatar (0024369)
unknownna (updater)
2025-03-30 04:53

Using: zandronum -file voodoodolltest_fixed_02.wad +alwaysapplydmflags 1 +netgame +map map01

I found some issues:

* After pushing the switch, getting the items and then entering "sv_coopunassignedvoodoodolls 0; map map01" into the console, it will spawn me in the map again with all the keys and the SSG at a fresh map start. It erroneously keeps the items across the map change.
* Joining the game from a spectator doesn't select the SSG offline with "sv_coopunassignedvoodoodolls 1", unlike online.
* The player doesn't auto-switch to the SSG when picked up by voodoo doll in multiplayer emulation compared to online play and true singleplayer.

Although it's rather unrealistic scenarios, I'm not quite sure if this is the correct behavior yet. I appreciate your continued work however.
User avatar (0024370)
DrinkyBird (developer)
2025-03-30 15:14
edited on: 2025-03-30 15:28

It appears the current behaviour (not calling Touch for each real player, but pretending the server did) originates from'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/beb0122a5d4d1d17898c7eecddc40c5eb999c27f. [^]' I could call Touch in multiplayer emulation, which would fix the pickup message and weapon switching etc, but then you won't receive weapons from voodoo dolls if sv_weaponstay is off when sv_coopunassignedvoodoodolls is on. This is a rabbit hole...

At this point it's getting kind of complex to patch every edge case, so if it gives the inventory items at all, I think that'd be good enough for now, and I can chase perfect behaviour some other time (especially since 3.2's release is approaching very soon).

This will fix the items being carried over at least:'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/3181505c61f03531cb3399b45f9a7f0548456891 [^]'

User avatar (0024371)
unknownna (updater)
2025-03-30 17:56
edited on: 2025-04-07 03:38

I tested it and messed around with it for a bit, and while it fixed the issue with the inventory being carried over to the next map after a "map" map change, I also managed to make it crash with my newer example wad.

This happens if the client for some reason decides to turn into a spectator first, and then joins the game again before telefragging the voodoo doll.

This whole issue is rather problematic indeed, where fixing one thing quickly breaks other things.

1. zandronum -file voodoodolltest_fixed_03b.wad +alwaysapplydmflags 1 +netgame +map map01 +spectate
2. Join the game, press the switch and go into the teleporter to telefrag the voodoo doll. The game will crash.

Edit:
I tested this again, and the crash started to occur after your 3rd fix from the looks of it, so it wasn't caused by your latest changes.

If you're somehow able to squeeze the patch into 3.2 and want to make users happy, it should work ok enough for now. Maybe add a note somewhere telling users not to spectate first when playing with voodoo dolls in multiplayer emulation.

User avatar (0024393)
DrinkyBird (developer)
2025-04-08 11:02

Whoops, I got sidetracked and then kind of forgot about this...

I'm not able to reproduce the crash, with sv_coopunassignedvoodoodolls 1 I just get stuck in the voodoo doll, and with it 0 the voodoo doll won't spawn. Can you send a crash report?

It does feel like ever more specific edge cases though - I wonder how often someone is likely to telefrag a voodoo doll after joining as a spectator (and perhaps only in multiplayer emulation?)
User avatar (0024394)
unknownna (updater)
2025-04-08 11:07

Sure, the crash happens offline in multiplayer emulation. I uploaded the crash report using voodoodolltest_fixed_03b.wad.
User avatar (0024395)
DrinkyBird (developer)
2025-04-08 12:05

Annoyingly, the Heptapod artefacts have expired, so I can't download the symbols anymore, and I can't use a rebuild since Visual Studio requires the original exe be exactly identical to the one used to generate the crash report.

Can you try this commit, and upload a crash report from this? It's the same commit as the previous build, albeit rebased atop the latest changes in the main branch.'https://foss.heptapod.net/zandronum/zandronum-stable/-/pipelines/103472 [^]'
User avatar (0024397)
unknownna (updater)
2025-04-08 12:14

I uploaded a new crash report using the pipeline build from your link.
User avatar (0024398)
DrinkyBird (developer)
2025-04-08 12:43

Very useful, thanks! That crash is with cl_identifytarget 2, as it was trying to get the health of the dummy player, but it doesn't have an individual associated mobj to access. This should fix that:'https://foss.heptapod.net/zandronum/zandronum-stable/-/commit/b0728ca2c3c1053b72ac6c8e0f90db73a2b12ef3 [^]'
User avatar (0024399)
unknownna (updater)
2025-04-08 13:36

That took care of the crash, nice job! So it seems to work fine now other than the minor discrepancies below:

* The player doesn't auto-switch to the SSG when picked up by voodoo doll in offline multiplayer with "sv_coopunassignedvoodoodolls 1".

* Joining the game from a spectator doesn't auto-select the SSG in offline multiplayer with "sv_coopunassignedvoodoodolls 1".

* No pickup messages or pickup sounds when voodoo doll picks up items in offline multiplayer with "sv_coopunassignedvoodoodolls 1".

* No pickup sounds in offline multiplayer when joining from being a spectator with "sv_coopunassignedvoodoodolls 0", unlike online. (Though this one seems odd, the loudness of the sounds depends on a 2nd client's distance from your own spawnspot.)

Seems like it's just the discrepancy with the unassigned voodoo dolls remaining, and then it's nearly identical between offline and online play. This can be refined further later.
User avatar (0024424)
DrinkyBird (developer)
2025-04-11 14:05

Unfortunately none of those further fixes will probably make it into 3.2, since we are possibly days away from release at this point, and I'd like these to be tested more thoroughly, but I don't think this is crucial enough to delay 3.2 any further.

I'd also like to fix the lack of Touch behaviour in multiplayer emulation, and some other voodoo doll behaviour changes, including some of the tickets spawned from this and some feedback Dark-Assassin mentioned, but those wouldn't be targeted for 3.2 anyway.

Issue Community Support
Only registered users can voice their support. Click here to register, or here to log in.
Supporters: Empyre Combinebobnt WaTaKiD Dark-Assassin StrikerMan780
Opponents: No one explicitly opposes this issue yet.

- Issue History
Date Modified Username Field Change
2015-10-30 22:24 Empyre New Issue
2015-10-30 22:24 Empyre File Added: voodoodolltest.zip
2017-02-06 01:08 Empyre Note Added: 0016765
2018-05-02 15:49 Empyre Note Added: 0019186
2023-12-31 11:04 StrikerMan780 Note Added: 0022941
2025-03-06 22:15 DrinkyBird Assigned To => DrinkyBird
2025-03-06 22:15 DrinkyBird Status new => assigned
2025-03-06 22:16 DrinkyBird Target Version => 3.2
2025-03-06 23:08 DrinkyBird Note Added: 0024240
2025-03-06 23:08 DrinkyBird Status assigned => needs review
2025-03-08 17:06 DrinkyBird Status needs review => assigned
2025-03-12 01:38 DrinkyBird Status assigned => needs review
2025-03-16 10:12 DrinkyBird Status needs review => needs testing
2025-03-20 11:00 unknownna File Added: voodoodolltest_fixed.wad
2025-03-20 11:08 unknownna Note Added: 0024262
2025-03-24 11:55 DrinkyBird Note Added: 0024306
2025-03-24 11:55 DrinkyBird Status needs testing => resolved
2025-03-24 11:55 DrinkyBird Fixed in Version => 3.2
2025-03-24 11:55 DrinkyBird Resolution open => fixed
2025-03-24 11:59 DrinkyBird Note Edited: 0024306 View Revisions
2025-03-24 11:59 DrinkyBird Status resolved => needs testing
2025-03-24 12:02 DrinkyBird Note Edited: 0024306 View Revisions
2025-03-24 12:04 DrinkyBird Note Edited: 0024306 View Revisions
2025-03-24 12:06 DrinkyBird Note Edited: 0024306 View Revisions
2025-03-24 12:22 unknownna Note Added: 0024307
2025-03-24 12:22 unknownna Status needs testing => feedback
2025-03-24 13:36 DrinkyBird Note Added: 0024308
2025-03-24 13:37 DrinkyBird Note Edited: 0024308 View Revisions
2025-03-24 13:54 DrinkyBird Note Edited: 0024308 View Revisions
2025-03-24 14:07 DrinkyBird Note Added: 0024309
2025-03-24 14:17 unknownna Note Added: 0024310
2025-03-24 14:28 DrinkyBird Note Added: 0024311
2025-03-24 14:32 unknownna Note Added: 0024312
2025-03-24 14:32 unknownna File Added: CrashReport.zip
2025-03-24 14:34 unknownna Note Edited: 0024312 View Revisions
2025-03-24 17:10 DrinkyBird Note Added: 0024314
2025-03-24 17:13 DrinkyBird Note Edited: 0024314 View Revisions
2025-03-24 17:32 unknownna Note Added: 0024315
2025-03-24 17:35 unknownna Note Edited: 0024315 View Revisions
2025-03-24 17:48 unknownna Note Edited: 0024315 View Revisions
2025-03-24 19:13 DrinkyBird Note Added: 0024316
2025-03-24 19:16 DrinkyBird Note Edited: 0024316 View Revisions
2025-03-24 19:16 DrinkyBird Note Edited: 0024316 View Revisions
2025-03-24 20:01 unknownna Note Added: 0024317
2025-03-26 11:03 DrinkyBird Note Added: 0024359
2025-03-26 12:21 unknownna Note Added: 0024360
2025-03-26 12:21 unknownna File Added: voodoodolltest_fixed_02.wad
2025-03-29 20:35 DrinkyBird Note Added: 0024363
2025-03-29 22:16 unknownna Note Added: 0024364
2025-03-29 23:48 DrinkyBird Note Added: 0024366
2025-03-30 04:53 unknownna Note Added: 0024369
2025-03-30 15:14 DrinkyBird Note Added: 0024370
2025-03-30 15:28 DrinkyBird Note Edited: 0024370 View Revisions
2025-03-30 17:56 unknownna Note Added: 0024371
2025-03-30 17:56 unknownna File Added: voodoodolltest_fixed_03b.wad
2025-04-07 03:38 unknownna Note Edited: 0024371 View Revisions
2025-04-08 11:02 DrinkyBird Note Added: 0024393
2025-04-08 11:07 unknownna Note Added: 0024394
2025-04-08 11:08 unknownna File Added: CrashReport_02.zip
2025-04-08 12:05 DrinkyBird Note Added: 0024395
2025-04-08 12:13 unknownna File Added: CrashReport_03.zip
2025-04-08 12:14 unknownna Note Added: 0024397
2025-04-08 12:43 DrinkyBird Note Added: 0024398
2025-04-08 13:36 unknownna Note Added: 0024399
2025-04-11 13:58 DrinkyBird Fixed in Version 3.2 =>
2025-04-11 13:58 DrinkyBird Target Version 3.2 =>
2025-04-11 14:05 DrinkyBird Note Added: 0024424






Questions or other issues? Contact Us.

Links


Copyright © 2000 - 2025 MantisBT Team
Powered by Mantis Bugtracker