Skip to content

feat(packets): add extended player shop price packets (0.9.11) - #1190

Merged
sven-n merged 2 commits into
masterfrom
claude/openmu-1186-packet-nuget-dphx9w
Oct 11, 2026
Merged

sven-n merged 2 commits into
masterfrom
claude/openmu-1186-packet-nuget-dphx9w

Conversation

@sven-n

@sven-n sven-n commented Oct 11, 2026 •

Copy link
Copy Markdown
Member

Protocol part of #1186. It's split out so the MUnique.OpenMU.Network.Packets NuGet package (bumped to 0.9.11, published by publish.yml on merge) can be released before the open source client (MuMain) adopts it. The server-side implementation is #1191, stacked on this PR.

Changes

All of these are XML changes; the C#, test and markdown files are regenerated from it. No original (non-Extended) packet layout changes.

A price uses the same three fields everywhere, as PlayerShopItemExtended already defines them:

  • MoneyPrice: zen, or account coins;
  • PriceItemType: the price item (group << 12 | number), or a reserved coin value (0xFFF0 WCoin C, 0xFFF1 WCoin P, 0xFFF2 Goblin Points);
  • RequiredItemAmount: the number of item pieces; 0 when the price isn't paid in items.

Packets:

  • C3 3F 09 PlayerShopSetItemPriceExtended (client → server, 13 bytes): MoneyPrice, PriceItemType, RequiredItemAmount and ItemSlot. Any price the item list can show can also be set, and the protocol doesn't fix which items can be used as a price.
  • C1 3F 0A PlayerShopPriceTypesExtended (server → client, variable length): a count and the PriceItemType values that are allowed in addition to zen. It's only sent while the server feature is enabled.
  • PlayerShopBuyResultExtended.ResultKind.LackOfPriceCurrency (10): lets the client tell "not enough items/coins" apart from "not enough zen".
  • PlayerShopItemExtended: the field descriptions now spell out this encoding.
  • Package version 0.9.10 → 0.9.11.

The first commit used a fixed ShopCurrencyType enum for the set-price packet. The second commit replaces it with the encoding above, so both packets describe a price the same way. Squashing on merge is fine.

Testing

  • Built MUnique.OpenMU.Network.Packets locally without ci=true, so the structs, ref structs, connection extensions and docs/Packets were regenerated. CommonEnums is unchanged compared to master.
  • dotnet test tests/MUnique.OpenMU.Network.Packets.Tests: 628 passed.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Y7XufeAZ22z7ocXAXUqUsE

Adds the protocol for player shop prices in other currencies than zen
(see #1186), without changing any of the original packet layouts:

- C3 3F 09 PlayerShopSetItemPriceExtended: sets a price with a currency.
- C1 3F 0A PlayerShopCurrenciesExtended: tells the client which
  currencies are enabled, as a bit mask.
- ShopCurrencyType common enum (Zen, five jewels, three account coins).
- PlayerShopBuyResultExtended gets LackOfPriceCurrency.
- Documents how PlayerShopItemExtended carries jewel and coin prices.

Bumps the MUnique.OpenMU.Network.Packets package to 0.9.11, so the
open source client can consume the new definitions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y7XufeAZ22z7ocXAXUqUsE
The extended set-price packet carried a fixed currency enum, while the
item list describes a price by MoneyPrice, PriceItemType and
RequiredItemAmount. The enum limited prices to a hard-coded set of
jewels and coins, and any other price item would have needed a protocol
change.

- C3 3F 09 PlayerShopSetItemPriceExtended now has the same three price
  fields as PlayerShopItemExtended (including the reserved account coin
  values), followed by the item slot.
- C1 3F 0A is now PlayerShopPriceTypesExtended: the list of allowed
  PriceItemType values, instead of a bit mask over the enum.
- The ShopCurrencyType enum is removed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y7XufeAZ22z7ocXAXUqUsE
@sven-n
sven-n merged commit 3cc795b into master Oct 11, 2026
2 checks passed
@sven-n
sven-n deleted the claude/openmu-1186-packet-nuget-dphx9w branch October 11, 2026 12:24
@sven-n sven-n changed the title feat(packets): add extended player shop currency packets (0.9.11) feat(packets): add extended player shop price packets (0.9.11) Oct 11, 2026
@sven-n
sven-n restored the claude/openmu-1186-packet-nuget-dphx9w branch October 11, 2026 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant