[EMAIL PROTECTED] wrote:
I'd like to change a little part of the HL2 Code to make the server wait for everyp layer to be connected after a level change in Deathmatch. I have had a look in the bool CServerGameDLL::LevelInit() function in GameInterface.cpp.
There is no simple way to do this. It sounds like you want to delay the spawning of items (i.e. don't let the ::Spawn() function do it's stuff until some rule is statisfied). The engine spawns items as the are processed from the map file. What you would have to do is modify each entities Spawn() function to check this rule. If the rule isn't satisfied, instead of spawning the item, add that item to a queue (list) of items waiting to be spawned, then check every frame to see if the rule is satisified and if the spawn queue has stuff in it. If so, call the Spawn function again for each of those items (which should actually spawn it this time since the rule was satisfied) and then remove that entity from your queue. This is NOT a trivial excerise for someone who's never done much Half-Life coding before. So if you are a newbie at Half-Life coding, start with some easier tutorials on modifying weapons and whatnot until you gain a little better understanding of how things work in the engine. -- Jeffrey "botman" Broome _______________________________________________ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders

