Regalis
5bdd801da4
Having multiple sub files with the same name doesn't prevent clients from selecting or requesting the correct one
2017-03-28 21:01:44 +03:00
Regalis
1a3c18c727
EntitySpawner sends spawn/removal messages to clients using EntityEvents.
...
EntityEvents and EntitySpawner used to work independently of each other, with separate IDs, and there was no guarantee that spawning and events would happen in the correct order. For example, a client could fail to read events during midround syncing because the entity has been removed, or read an event for an incorrect entity because the entity has been removed and the ID taken by some other entity.
2017-03-27 21:05:32 +03:00
Regalis
ccc09560a1
Fixed another off-by-one error in EntitySpawner ID comparisons, clients reset their ChatMessage ID when (re)connecting to the server
2017-03-24 17:56:56 +02:00
Regalis
2c688f40e3
Syncing RespawnManager state with clients
2017-03-20 20:44:20 +02:00
Regalis
8d8620047d
Fixed clients who leave a server and re-join becoming desynced and not being kicked by the server.
...
The clients didn't reset their ChatMessage.LastID, which caused an exception to be thrown when clamping the chatmsg ID server-side, preventing the server from updating the lastRecvEntityEventID of the client later in the method. The server wouldn't kick the client, because ServerEntityEventManager wouldn't handle cases where a client is waiting for an event that doesn't exist anymore.
2017-03-14 22:43:15 +02:00
Regalis
2d7d7f3d8d
Fixed turret syncing, clients don't get a notification about changed permissions if they're assigned the same permissions they already have
2017-03-13 20:52:31 +02:00
Regalis
5bdb57b98a
Merge branch 'master' into new-netcode
...
Conflicts:
Subsurface/Properties/AssemblyInfo.cs
Subsurface/Source/Characters/AICharacter.cs
Subsurface/Source/Characters/Animation/HumanoidAnimController.cs
Subsurface/Source/Characters/Character.cs
Subsurface/Source/GameMain.cs
Subsurface/Source/Items/Components/Signal/Connection.cs
Subsurface/Source/Items/Item.cs
Subsurface/Source/Networking/GameServer.cs
Subsurface/Source/Networking/GameServerLogin.cs
Subsurface/Source/Physics/PhysicsBody.cs
2017-03-11 13:24:09 +02:00
Regalis
e406b76cd5
Some more logic to handle missing sub files and active file transfers when starting a round:
...
- server waits for transfers to finish before starting the round (up to a max 20 seconds, can be skipped by the host)
- clients enable the spectate button when the round starts (in case they fail to start the round due to a missing sub file or an error)
- clients notify the server if a transfer is cancelled
+ FileReceivers can't be instantiated if a server is running
2017-03-09 19:56:27 +02:00
Regalis
ca402396a0
Client-side file transfer UI, FileSender has a limit on how many transfers can be active simultaneously (todo: queue transfers?), some extra debug logging & small fixes
2017-03-08 22:56:11 +02:00
Regalis
6bae2cf47b
File transfers (somewhat) working. Todo: testing, show active transfers in the UI
2017-03-07 23:01:01 +02:00
juanjp600
d6c292a2cc
SharpFont + ScalableFont implementation
...
https://github.com/Robmaister/SharpFont
TODO: replace Code Bold.otf with the full version, fix any bugs, build on Linux, possibly move ToolBox string wrapping and limiting logic to ScalableFont class for better results.
2017-03-07 13:44:42 -03:00
juanjp600
ecb7500df9
Converted UInt32 ID's to UInt16
...
TODO: test everything, make sure nothing broke
2017-03-06 16:25:12 -03:00
juanjp600
7935ecce46
- fixed crash in UpdateVoteStatus
...
- fixed clients reconnecting automatically after being kicked for desync
2017-03-01 17:04:51 -03:00
Regalis
04f86865f7
Changed GUIMessageBox.MessageBoxes from a queue to a list to make it easier to remove messageboxes that aren't currently visible, fixed clients creating multiple "permissions changed" messageboxes if there's another messagebox on the screen
2017-02-18 15:58:46 +02:00
Regalis
6c8f5b8999
The server maintains a list of unique EntityEvents created during the round and sends them to clients who join mid-round
2017-02-18 15:09:13 +02:00
Regalis
b98ebe6e21
Readded client permissions
2017-02-06 21:07:24 +02:00
Regalis
4b8d1054b1
Changed lobby & chatMsg IDs to from uint to ushort, added a utility class that handles the wrap around of IDs
2017-02-05 22:55:19 +02:00
Regalis
89e881cb57
Readded voting (submarine, mode, end round & kick)
2017-02-04 18:30:40 +02:00
Regalis
05c5880269
Displaying the names of the connected players in the server lobby
2017-02-01 18:10:48 +02:00
Regalis
0cd2d7a0b9
Readded traitors
2017-01-30 19:49:13 +02:00
Regalis
6252db7928
- fixed server validating its own name instead of the name of a client who's logging in
...
- clients automatically reconnect to the server when the connection is lost and return back to server list if they fail to reconnect
- showing the error msg as a GUIMessageBox and returning to main menu if starting a server fails
2017-01-14 16:57:47 +02:00
Regalis
08053bec85
Clients can join the game mid-round
2017-01-12 20:42:15 +02:00
Regalis
ed675dc75e
Lobby update ID isn't included in ingame update messages, resetting lastRecvGeneralUpdate in InitClientSync
2017-01-11 23:37:30 +02:00
Regalis
037bd09c2c
- clients ignore lobby updates if they already received a more up-to-date one
...
- server tells clients their ID in the first lobby update
- clients take control of a spawned character if their ID matches the ownerID of the character (-> respawning works now)
2017-01-11 21:31:19 +02:00
Regalis
ff96f152ce
Resetting EntityEvent & EntitySpawner IDs when starting a new round, LOS effect is enabled when a client takes control of a character
2017-01-09 18:22:37 +02:00
Regalis
402c745fc3
Reimplemented chat range & radio messages. Each client now has their own chatMsgQueue, so all chat messages don't have to be sent to all clients.
2017-01-07 19:22:48 +02:00
Regalis
5d83a33876
Notifying clients when the round ends
2017-01-06 19:06:11 +02:00
Regalis
518eea746e
Transforming in-sub MemPos/MemLocalPos coordinates to outside coordinates if the character is outside and vice versa, server doesn't start sending ingame updates until they receive the first ingame update message from the client (no need to send updates while the client is loading or if they fail to start the round)
2017-01-05 18:16:58 +02:00
Regalis
1f454d593e
Inventory syncing, objHeader is passed to the ClientRead/ServerRead methods so they can determine how to read the msg (is it an inventory update, position, input, etc)
2016-12-10 16:39:58 +02:00
Regalis
adde3461ea
Merge branch 'master' into new-netcode
...
Conflicts:
Subsurface/Properties/AssemblyInfo.cs
Subsurface/Source/Characters/Animation/HumanoidAnimController.cs
Subsurface/Source/Characters/Character.cs
Subsurface/Source/Items/Components/Door.cs
Subsurface/Source/Items/Components/Power/PowerContainer.cs
Subsurface/Source/Items/Components/Signal/Wire.cs
Subsurface/Source/Items/Item.cs
Subsurface/Source/Networking/ChatMessage.cs
Subsurface/Source/Networking/GameClient.cs
Subsurface/Source/Networking/GameServer.cs
Subsurface/Source/Networking/GameServerLogin.cs
Subsurface/Source/Networking/GameServerSettings.cs
Subsurface/Source/Networking/NetworkMember.cs
2016-11-24 19:52:40 +02:00
Regalis
c3b84ca835
Re-enabled client permission settings in NetLobbyScreen, fixed clients not setting their permissions when receiving PacketTypes.Permissions
2016-11-21 17:46:03 +02:00
Regalis
4cef011131
Hull volume helper is hidden when no hulls are selected, using the HasPermission method for consistency
2016-11-21 16:55:56 +02:00
juanjp600
ba7fcad8f2
Readded special client permissions
...
Also added a command that requires a password to gain the permissions.
I think they were never vulnerable in the first place, gamerfood was just trying to intimidate us.
2016-11-20 22:01:37 -03:00
juanjp600
7a3bce3973
Hull volume helper in editor + Character name matches client name + Better-looking Watcher light source
...
Also '' is a thing of the past, use \" instead
2016-11-20 18:47:22 -03:00
Regalis
3d234aef73
Sending NetEntityEvents from client to server, ItemComponent class doesn't implement the INetSerializable interfaces (only the derived classes do), reactor syncing
2016-11-13 19:34:23 +02:00
Regalis
498c72c64a
Server sends ServerEntityEvents to clients, NetEntityEvents can contain an object array which will be passed to the serializable entity (now only used for ItemComponent indices)
2016-11-13 13:56:48 +02:00
Regalis
c314b37029
Some classes for syncing entity state changes. Similar to the NetworkEvents in the old netcode, but the logic is split into separate classes which prevent the server from reading updates for entities that aren't IClientSerializable.
...
todo: add NetEntityEventManagers to server & client, some logic to prevent sending events that don't need to be sent (e.g. duplicate event state updates)
2016-11-12 20:56:06 +02:00
Regalis
eb2c51c2f1
Cleanup with resharper (mostly removing redundancies & using collection.Length/Count properties instead of the Count method)
2016-10-31 20:50:20 +02:00
Regalis
5cc605bc01
Dust particles are drawn in the same batch as the background sprites (-> far-away particles are rendered behind the sprites), limiting character name length in the crew info menu, the "submarine not found in your folder" -tooltip is updated after downloading a sub file
2016-10-29 15:38:40 +03:00
Regalis
980f8e0d33
- option to select which location autopilot navigates towards
...
- generating "dummy locations" for the MP gamesessions (visible in sonar and mission descriptions)
- EndGame network message tells the clients if the mission was successful (because the message may arrive before the sub has reached the exit or before some character has died at the client's end)
2016-10-26 19:22:40 +03:00
Regalis
6f9160e4a7
Removing & spawning entities in the same order as the server, EntitySpawner does both removing and spawning
2016-10-26 16:44:59 +03:00
Regalis
df9f89e383
Submarine position syncing
2016-10-25 20:50:47 +03:00
Regalis
07f8c966ab
Submarine position is synced using the same logic as the characters, AICharacter position syncing
2016-10-25 19:01:19 +03:00
Regalis
641e579e92
Backported animcontroller-overhaul
2016-10-22 15:18:16 +03:00
Regalis
e2d0e7fe24
Moved collider position correction logic to the physicsbody class (so that it can be used for sub & item syncing), character position msg length is written in bytes instead of bits, misc cleanup/refactoring
2016-10-19 20:49:18 +03:00
Regalis
9fed308705
InGame update messages include a timestamp which is passed to the ClientRead methods
...
Now only used in character position syncing, but some other entities may also have an use for it (e.g. discarding outdated data)
2016-10-18 19:04:32 +03:00
Regalis
b68eeda8a8
WIP position syncing
2016-10-17 22:34:59 +03:00
Regalis
170e1a0da8
ItemRemover -> EntityRemover, clients reset spawner & remover when starting a new round
2016-10-12 20:46:47 +03:00
Regalis
60b36e020c
Changed ItemSpawner to EntitySpawner, used for syncing both item and character spawning
2016-10-12 19:25:01 +03:00
Regalis
ac3539da63
Item spawn syncing
2016-10-12 18:29:44 +03:00