mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 10:54:24 -04:00
move finalExitCallbacks to CMU implementation
This commit is contained in:
parent
681dc378dc
commit
e90652e89e
@ -29,6 +29,8 @@ class ClientRepository(ClientRepositoryBase):
|
|||||||
ClientRepositoryBase.__init__(self, dcFileNames = dcFileNames, dcSuffix = dcSuffix, connectMethod = connectMethod, threadedNet = threadedNet)
|
ClientRepositoryBase.__init__(self, dcFileNames = dcFileNames, dcSuffix = dcSuffix, connectMethod = connectMethod, threadedNet = threadedNet)
|
||||||
self.setHandleDatagramsInternally(False)
|
self.setHandleDatagramsInternally(False)
|
||||||
|
|
||||||
|
base.finalExitCallbacks.append(self.shutdown)
|
||||||
|
|
||||||
# The doId allocator. The CMU LAN server may choose to
|
# The doId allocator. The CMU LAN server may choose to
|
||||||
# send us a block of doIds. If it chooses to do so, then we
|
# send us a block of doIds. If it chooses to do so, then we
|
||||||
# may create objects, using those doIds.
|
# may create objects, using those doIds.
|
||||||
|
@ -56,8 +56,6 @@ class ConnectionRepository(
|
|||||||
# the world, helpful for sending messages specific to each one.
|
# the world, helpful for sending messages specific to each one.
|
||||||
self.uniqueId = hash(self)
|
self.uniqueId = hash(self)
|
||||||
|
|
||||||
base.finalExitCallbacks.append(self.shutdown)
|
|
||||||
|
|
||||||
# Accept this hook so that we can respond to lost-connection
|
# Accept this hook so that we can respond to lost-connection
|
||||||
# events in the main thread, instead of within the network
|
# events in the main thread, instead of within the network
|
||||||
# thread (if there is one).
|
# thread (if there is one).
|
||||||
|
@ -85,6 +85,8 @@ class ServerRepository:
|
|||||||
# Default value.
|
# Default value.
|
||||||
threadedNet = config.GetBool('threaded-net', False)
|
threadedNet = config.GetBool('threaded-net', False)
|
||||||
|
|
||||||
|
base.finalExitCallbacks.append(self.shutdown)
|
||||||
|
|
||||||
# Set up networking interfaces.
|
# Set up networking interfaces.
|
||||||
numThreads = 0
|
numThreads = 0
|
||||||
if threadedNet:
|
if threadedNet:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user