test for greg

This commit is contained in:
Dave Schuyler 2005-04-30 01:34:54 +00:00
parent bb0c57bcd8
commit 866645f18c

View File

@ -311,6 +311,9 @@ class ClockDelta(DirectObject.DirectObject):
Preserves the lower NetworkTimeBits of the networkTime value, Preserves the lower NetworkTimeBits of the networkTime value,
and extends the sign bit all the way up. and extends the sign bit all the way up.
""" """
if 1:
r = ((networkTime & NetworkTimeMask) << NetworkTimeTopBits) >> NetworkTimeTopBits
else:
if networkTime < 0: if networkTime < 0:
# flip the sign, mask it as if it were positive, flip the sign back: # flip the sign, mask it as if it were positive, flip the sign back:
r = (networkTime * -1 & NetworkTimeSignedMask) * -1 r = (networkTime * -1 & NetworkTimeSignedMask) * -1