Skip to content

v0.4.0-pre4: fixes from the third two-player test

Pre-release
Pre-release

Choose a tag to compare

@Dudiebug Dudiebug released this 18 Oct 22:52

Pre-release: fixes from the third two-player test. Not yet re-tested on two machines. Every offline check passes: build with -Werror, 38 unit test programs under ASan/UBSan, a 300k-input protocol fuzz, 560/560 mutants killed, and the DLL export check. Protocol revision 11, the same as pre3: a pre3 player can still join, but both players need this version, because each machine fixes the copies of the other players it shows.

Fixed

  • Forged weapons, shields, punches and kicks did nothing on the other screen. The mod only counted procedural weapons as weapons. Blows from the forged sword or the shield were blocked instead of sent, never clashed, and their drops were lost. All of them count now. Punches and kicks are weapon blows too, with friendly fire and kill credit like any weapon.
  • Floating shield, and "he lost his weapon but could still hit me". The other player's copy on your screen let go of its weapon by itself. The weapon then floated, or vanished from that copy's hand, while the real player still held it and still landed blows. The copy can no longer let go by itself. If a weapon still slips out, it is put back in the hand, or falls to the floor normally.
  • Weapon changes did not show. Picking a weapon up, switching weapons or putting one away should now show on the other screen within about half a second, 2 s at worst.
  • The game got slower round after round. Every respawn left the old body's feet, cut-off fists and sheathed weapons in the level as loose physics objects. They are removed now. Whether this was the whole cause of the slowdown is not known yet.

New in the log

Every 5 s, HSMMod.log now also shows the cost of the mod's game-event hooks, how many weapons and objects are in the level, and counters for weapon pickups and drops on the other players' copies. Please send both logs after playing.

Install

Copy dwmapi.dll into <Half Sword>/HalfswordUE5/Binaries/Win64/, replacing any older copy. HSMMod.ini is created on first run. Everyone needs this same version and Steam game build 24185754.
Linux / Steam Deck (Proton): Proton loads its own built-in dwmapi.dll unless told otherwise. In Steam, right-click Half Sword → Properties → General → Launch Options and set:

WINEDLLOVERRIDES="dwmapi=n,b" %command%

Windows players need no launch option.

To use the older host-simulates-everyone sync, the host sets sync_mode=host under [net] in HSMMod.ini.

Known limits

  • Level props (barrels, debris) are not synced; each machine simulates its own.
  • A pickup is shown only if this machine has its own copy of that weapon lying within about 1.5 m of where it was picked up.
  • With two loose weapons of the same kind in reach, the other screen takes the nearer one, which may not be the one picked up.
  • A weapon moved to the other side's sheath (right-hand weapon into a left slot) is not mirrored.
  • The grab pull is a soft handle, not the game's own grab constraint.

Please report bugs with the HSMMod.log from both machines.

dwmapi.dll SHA-256: fef5d04f539dc422db02939911d6c1b658ca03f97b13772379263099ac9f5e35

Contains code ported from Cyrex0/HalfSword-MP, Copyright (c) 2026 Cyrex0 and the HalfSword-MP contributors, MIT (see THIRD_PARTY_NOTICES.md, attached). Unofficial fan mod, not affiliated with Half Sword Games.