Commit Graph

124 Commits

Author SHA1 Message Date
Regalis
7dad837733 Server limits chatmessage length and the number of chatmessages written in one packet 2017-05-08 19:06:05 +03:00
Regalis
64c109f13b Merge branch 'master' into new-netcode
Conflicts:
	Subsurface/Source/Characters/AI/EnemyAIController.cs
	Subsurface/Source/DebugConsole.cs
	Subsurface/Source/Items/Components/Machines/Radar.cs
	Subsurface/Source/Items/Item.cs
2017-04-27 21:33:44 +03:00
Regalis
58de86a98f Heal and revive debug commands can also be used on other characters than the controlled one 2017-04-24 21:34:36 +03:00
Regalis
31f7eca717 Merge branch 'master' into new-netcode
Conflicts:
	Subsurface/Source/GUI/GUIButton.cs
	Subsurface/Source/GameSession/CrewManager.cs
	Subsurface/Source/GameSession/GameSession.cs
	Subsurface/Source/Items/Item.cs
	Subsurface/Source/Networking/GameServer.cs
	Subsurface/Source/Screens/MainMenuScreen.cs
	Subsurface/Source/Screens/ServerListScreen.cs
2017-04-23 21:40:11 +03:00
Regalis
9a5777183f Separate sprites for horizontal and vertical scrollbars, style tweaking 2017-04-18 19:24:13 +03:00
Regalis
fac31b4892 - Fixed railgun sounds not playing at the clients' end
- Server sends updates for batteries when their charge changes (not strictly necessary assuming the rest of the electrical grid stays in sync, but just in case)
- Reactor state is synced with clients if modified through the debug console
- Increased maximum item velocity to 64 units/s, all item are clamped to the max vel
2017-04-10 20:13:33 +03:00
Regalis
e94a50a29a The server keeps track of which ID a client is going to switch to when midround syncing is done, and switches the ID immediately when the client is in sync (instead of waiting for the client to report the new ID).
Fixes clients occasionally getting kicked out the moment they're in sync, because their latest received ID is still set to the ID of the last unique event and the server thinks they're requesting some old event that doesn't necessarily exist anymore.

+ added a debug command that creates a ton of entity events
2017-04-08 20:10:15 +03:00
Regalis
3844dd9dac GUIStyle logic changes: instead of having a predetermined GUIComponentStyle for each type of GUIComponent, any GUIComponent can use any style. The GUIComponent constructors take the name of the style as a parameter, and if no style is specified, the default style for the GUIComponent in question will be used. 2017-04-08 16:46:53 +03:00
Regalis
f863eb331d Moved stun from AnimController to the character class, server notifies clients when the stun ends, husk infection included in character status messages 2017-04-07 19:56:25 +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
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
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
Regalis
7f7ac76484 Merge branch 'master' into new-netcode
Conflicts:
	Subsurface/Source/Characters/Character.cs
	Subsurface/Source/GUI/GUI.cs
	Subsurface/Source/GUI/LoadingScreen.cs
2017-02-13 22:04:28 +02:00
Regalis
5871faa2dd Added a few new console commands: disablehud, lockx & locky (disables submarine movement on the respective axis), followsub (toggles whether the camera moves with the subs) 2017-02-13 16:23:28 +02:00
Regalis
bd7766d3e7 Server clears EntityEventManager before starting a new round, not just when ending it (fixes events breaking during the next round if an item created an event when unloading the previous sub) + some additional error checks 2017-01-14 20:26:41 +02:00
Regalis
1f07b18e5b Merge branch 'master' into new-netcode
Conflicts:
	Subsurface/Properties/AssemblyInfo.cs
	Subsurface/Source/Items/Components/DockingPort.cs
	Subsurface/Source/Items/Components/Signal/Wire.cs
	Subsurface/Source/Items/Item.cs
2016-12-29 22:18:27 +02:00
Regalis
f9ea876edf - sub list in the main menu is refreshed when MainMenuScreen is selected (-> downloaded and newly created subs appear in the list)
- fixed "editing menu" not disappearing after an entity is removed in the editor
- debugconsole textbox is automatically selected when opening the console
- clearing the current gamesession if returning to main menu using the console
2016-12-12 14:49:16 +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
219f9258e2 v0.5.4.0 + converting parameters of the spawn command to correct case 2016-11-22 17:17:14 +02:00
juanjp600
145abe03f1 Fixed crash with admin command 2016-11-20 22:04:21 -03: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
Regalis
d37bad2d44 Wire sections are updated after flipping, made the wire node list private and added public methods which ensure that sections are updated when modifying nodes 2016-11-16 18:41:32 +02:00
juanjp600
d2c17274fe GUI elements now respect render order + some minor distance comparison optimization 2016-11-15 22:26:36 -03:00
juanjp600
62d79aff03 Removed testasd command 2016-11-10 21:48:50 -03:00
juanjp600
0e9c20c666 Case-sensitivity checks on Windows
Should prevent "TigerThresher" from happening again.
2016-11-10 21:45:59 -03:00
Regalis
ac65a431a8 Merge branch 'master' into new-netcode
Conflicts:
	Subsurface/Properties/AssemblyInfo.cs
	Subsurface/Source/Items/Components/Signal/Wire.cs
	Subsurface/Source/Items/Item.cs
	Subsurface/Source/Items/ItemInventory.cs
	Subsurface/Source/Networking/GameServer.cs
2016-11-09 17:58:56 +02:00
Regalis
cd5c72eff2 Number of children in the debugconsole listbox limited to 200 (prevents framerate drop if adding tons of messages) 2016-11-07 20:45:23 +02:00
juanjp600
f0acf69065 Merge remote-tracking branch 'barotrauma/master' into new-netcode
# Conflicts:
#	Subsurface/Properties/AssemblyInfo.cs
#	Subsurface/Source/Characters/AI/EnemyAIController.cs
#	Subsurface/Source/Characters/AICharacter.cs
#	Subsurface/Source/Characters/Character.cs
#	Subsurface/Source/Items/Components/Signal/Connection.cs
#	Subsurface/Source/Items/Item.cs
#	Subsurface/Source/Map/Structure.cs
#	Subsurface/Source/Networking/GameClient.cs
#	Subsurface/Source/Networking/GameServer.cs
#	Subsurface/Source/Screens/NetLobbyScreen.cs
2016-11-05 18:18:20 -03:00
Regalis
799efd8474 - attempt to fix "DXGI_ERROR_NOT_CURRENTLY_AVAILABLE" exceptions (the game tries forcing focus to the window and running GameMain again, and if that doesn't help, disables hardware mode switching)
- messages can be added to debugconsole before it's initialized
2016-11-02 20:38:55 +02: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
641e579e92 Backported animcontroller-overhaul 2016-10-22 15:18:16 +03:00
Regalis
de203cc424 - a WIP attempt to correct the position of the controlled character based on updates from the server
- fixed server not being able to move character controllers
- renamed IsNetworkPlayer -> IsRemotePlayer
2016-10-19 00:15:29 +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
juanjp600
72033a581e Merge remote-tracking branch 'refs/remotes/barotrauma/master'
Conflicts:
	Subsurface/Properties/AssemblyInfo.cs
	Subsurface/Source/Characters/Character.cs
	Subsurface/Source/GUI/GUI.cs
	Subsurface/Source/GameMain.cs
	Subsurface/Source/GameSettings.cs
	Subsurface/Source/Items/CharacterInventory.cs
	Subsurface/Source/Items/Components/ItemComponent.cs
	Subsurface/Source/Items/Components/Machines/Pump.cs
	Subsurface/Source/Items/Components/Machines/Radar.cs
	Subsurface/Source/Items/Components/Machines/Steering.cs
	Subsurface/Source/Items/Components/Power/PowerContainer.cs
	Subsurface/Source/Items/Inventory.cs
	Subsurface/Source/Items/Item.cs
	Subsurface/Source/Items/ItemSpawner.cs
	Subsurface/Source/Map/Levels/WaterRenderer.cs
	Subsurface/Source/Map/LinkedSubmarine.cs
	Subsurface/Source/Map/Map/Map.cs
	Subsurface/Source/Map/Structure.cs
	Subsurface/Source/Map/Submarine.cs
	Subsurface/Source/Map/WayPoint.cs
	Subsurface/Source/Networking/GameClient.cs
	Subsurface/Source/Networking/GameServer.cs
	Subsurface/Source/Physics/PhysicsBody.cs
	Subsurface/Source/Screens/GameScreen.cs
2016-10-11 20:19:25 -03:00
Regalis
cb992c7d66 Fixed crashing if a matching waypoint isn't found when spawning a monster 2016-10-10 21:38:19 +03:00
juanjp600
f0f385c2b2 Fixed clients not seeing additional cargo + spawn monster cursor 2016-10-10 11:05:33 -03:00
juanjp600
fc8eab688d Merged branch master into new-netcode 2016-09-27 19:45:14 -03:00
Regalis
2bdc7441fc Merge branch 'level-gen-overhaul' 2016-09-27 20:19:29 +03:00
juanjp600
02d98f5d29 Merge remote-tracking branch 'refs/remotes/barotrauma/master'
Conflicts:
	Subsurface/Source/Networking/FileStreamReceiver.cs
	Subsurface/Source/Networking/FileStreamSender.cs
	Subsurface/Source/Networking/GameClient.cs
	Subsurface/Source/Networking/GameServer.cs
	Subsurface/Source/Networking/GameServerLogin.cs
	Subsurface/Source/Networking/NetworkEvent.cs
	Subsurface/Source/Screens/NetLobbyScreen.cs
2016-09-24 21:28:37 -03:00
juanjp600
d537e8795a Replace '' (two single quotes) with \" (double quote)
We must correct post-traumatic Blitz disorder
2016-09-24 21:26:08 -03:00
juanjp600
edab86f730 Character freezing + Misc fixes 2016-09-21 16:46:12 -03:00
Regalis
c6105afc80 A separate class for parameters used by the level generator, different "level types" with configurable parameters 2016-09-12 20:48:43 +03:00
Regalis
4fbb83e2e7 The server can start the game 2016-09-09 19:49:13 +03:00
juanjp600
6f25bee9e1 Merge remote-tracking branch 'refs/remotes/barotrauma/master'
Conflicts:
	.vs/Subsurface_Solution/v14/.suo
	Subsurface/Barotrauma.csproj
	Subsurface/Properties/AssemblyInfo.cs
	Subsurface/Source/Items/ItemSpawner.cs
	Subsurface/Source/Networking/GameClient.cs
	Subsurface/Source/Networking/GameServer.cs
	Subsurface/Source/Networking/GameServerLogin.cs
2016-09-03 17:54:33 -03:00
Regalis
2c51ba50a8 v0.5.1.2: spawnitem console command, "spawn inside" always spawns characters in the main sub, a new music clip, modified the topwindow sprite a bit 2016-08-31 22:06:05 +03:00
juanjp600
7bdcc51bae Made game compilable
Networking functionality is fully disabled now.

I think it's time to start rewriting everything. OH BOY
2016-08-30 21:13:36 -03:00
Regalis
7ed95c430b Option to choose which character to control with the console command when there are multiple characters with the same name 2016-08-30 19:04:06 +03:00
Regalis
712953cc9e WIP client special permissions (kick, ban, end round) 2016-08-24 11:47:46 +03:00
Regalis
dc67eeebd4 Humans can be spawned through console in multiplayer 2016-08-23 14:19:50 +03:00