Bug Tracker – Bug 1248

Add sv_sharekeys

Last modified: 2019-01-26 07:02:28 UTC
Bug 1248 - Add sv_sharekeys
Summary: Add sv_sharekeys
Status: NEW
Alias: None
Product: Odamex
Classification: Unclassified
Component: Server & Client (show other bugs)
Version: 0.8.x
Hardware: All Other
: P5 enhancement
Assignee: Odamex Bug Reporter
Depends on:
Reported: 2019-01-25 16:05 UTC by Ralph Vickers
Modified: 2019-01-26 07:02 UTC (History)
1 user (show)

See Also:


Add an attachment (proposed patch, testcase, etc.)

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Vickers 2019-01-25 16:05:56 UTC
Add sv_sharekeys for coop. Shares keys between the players. When a key is picked up, print a global notification.
Comment 1 Maëllig Desmottes 2019-01-26 07:02:28 UTC
Shouldn't be hard to do it (without even making some protocol changes !)

1) Make serverside (or commonside ?) the CVAR sv_sharekeys
2) Make from the server a byte[MAX KEYS] flagging keys.
3) Whenever a client gets a key, increment from that byte.
4) in the Player Think, check if we don't have the same keys from the server. If so, sync them with the server.
5) In the player (re?)spawn function, sync 
6) (Optionnal ?) If we enable the CVAR midgame, sync them between all players.