[Release] [Zombies] Origins 8 Player Crash Fix for Dedicated Servers
-
This is a mod that fixes the 5+ player crashes that can occur on an Origins server. https://github.com/JezuzLizard/Recompilable-gscs-for-BO2-zombies-and-multiplayer/tree/master/Plutonium specific gsc-related fixes
Do note that Origins is the least compatible with 8 player zombies in comparison to other maps, and this mod DOES NOT balance or help accommodate more than 4 players. There are some Treyarch related memes such as binding many mechanics to the players character, such as box rewards, which result in the box rewards not working whatsoever for the other 4 Dempseys( the default character on Origins ).
Despite this I wanted to be able to play Origins without crashing on more than 8 players so I figured the community would be interested in a fix despite some balance issues.
I do intend on releasing an Origins server improvement mod which fixes a lot of issues related to running the map on a server. Treyarch never thought that people would join/leave as frequently as they do on a pluto server, and this causes some issues related to the main quest among other things.
Anyway, the actual reason Origins was broken for 8 player in the first place was due to clientfields not being registered for more than 4 players but the method for setting clientfields for more than 8 players was supported.
For example in maps/mp/zm_tomb_craftables.gsc
bits = getminbitcountfornum( 5 ); registerclientfield( "world", "staff_player1", 14000, bits, "int", undefined, 0 ); registerclientfield( "world", "staff_player2", 14000, bits, "int", undefined, 0 ); registerclientfield( "world", "staff_player3", 14000, bits, "int", undefined, 0 ); registerclientfield( "world", "staff_player4", 14000, bits, "int", undefined, 0 );
Only clientfields for 4 players are registered, and these clientfields control which player the ui displays owning a staff.
The method for setting looks like this:
n_player = e_owner getentitynumber() + 1; level setclientfield( "staff_player" + n_player, 1 );
Basically if a player picks up a staff the gsc will tell the ui thru setlientfield() to update and display that player as the owner of the staff. The same thing happens when the player no longer owns the staff. The issue arises when setclientfield() is called on a clientfield that hasn't been registered. staff_player8 doesn't exist so when the game goes to tell the ui to update it crashes the server instead. In Origins's case there are 16 playernumber specific clientfields registered and used throughout the game.
In order to fix the crashes I simply created if statements checking if the playernumber would be higher than 4 to determine whether the clientfield should be set. This does mean players in the 5+ slot don't get shovel, golden helmet, staff, and crystal clientfields. Meaning ownership of those items isn't diplayed in the scoreboard ui nor do the shovel, and golden helmet icons show up for those players( though they still work ).
If you discover any bugs while using this mod feel free to report them here. I tested the mod up to the 3 robots main quest step step and encountered zero crashes or game breaking glitches.
-
How is the patch installed?
-
@ZunDhr said in [Release] [Zombies] Origins 8 Player Crash Fix for Dedicated Servers:
How is the patch installed?
Follow the instructions on the github.
-
I'm getting a fatal error with this mod installed,
This is a bit weird considering the override has nothing to do with the tank as far as I can see.
-
Martix Are you installing the mod correctly?
Compiling zm_tomb_zmb.gsc as zm_tomb_amb.gsc, and placing in it maps/mp ?
Compiling zm_tomb_craftables.gsc as zm_tomb_craftables.gsc and placing it in maps/mp ?
Compiling zm_tomb_dig.gsc as zm_tomb_dig.gsc and placing it in maps/mp ?
-
JezuzLizard im having the same issue, i made sure to compile the files and put it in the maps/mp folder, so i dont know what im doing wrong
-
link is no longer working for git hub is this mod still available elsewhere?
-
GamerActual Mod is no longer needed as Plutonium has patched the crash internally.
-
JezuzLizard interesting, I was playing origins on my dedicated server yesterday until about round 20 with 4 players. Player 5 joined and complained about lag, 2 minutes later server kaput. Is there any info on this patch, does it need configuring?