>// File: mazeserver.cpp
ackets.h"
>//-----------------------------------------------------------------------------
> m_dwServerReliableRate = 15;; b( S/ T$ U1 p2 c4 {1 \
> m_ClientNetConfig.ubReliableRate = 15;
> m_ClientNetConfig.dwThreadWait = 0;</P>; y1 u3 ^4 C7 Z: _
> m_ClientNetConfig.ubClientPackIndex = 0;8 t+ `# s$ m6 x P: N
>8 Y" |2 X2 O% p0 P
aram"), E_FAIL );</P>
> // Grab height and width of maze4 H3 v" X6 G4 y$ n
> m_ClientNetConfig.dwMazeWidth = m_dwWidth;2 y. ?4 \$ x* Y# f9 u7 |: `- q/ C
> // Validate size. Must be a power-of-2 times LOCK_GRID_SIZE. Compute the shifts.; A9 H/ Z/ W/ `9 l5 t3 D) u2 o1 z# E* r
> DWORD scale = m_dwWidth / LOCK_GRID_SIZE;7 P2 T! k, ~3 a! q& X6 H3 X% i: m
> scale = m_dwHeight / LOCK_GRID_SIZE;! `4 V1 A- Z& ]8 R. w, ^2 h
> if( ((DWORD(LOCK_GRID_SIZE) << m_dwMazeXShift) != m_dwWidth) ||
> // Initialise the player list
> m_PlayerDatas[0].pNext = &m_PlayerDatas[1];
> // Initialise the cells
> return S_OK;$ J6 `' L2 W0 v' c5 G: G1 i
>, x& x# T5 h6 D& w- _( ~, ]) V! ^9 m
>
ockRange( DWORD x1, DWORD y1, DWORD x2, DWORD y2 )
>
>
ockCell( DWORD x, DWORD y )" @: P$ V" J! B1 ~% B; E- e$ v! e
>
>. m* j: h+ Q2 l" m& h% z/ \
ockCellPair( DWORD x1, DWORD y1, DWORD x2, DWORD y2 )
> return;
> DWORD x1shift = x1>>m_dwMazeXShift;
> if( x1 == 0xffff )1 |; |; g% u: x3 ]7 L) I
>/ O3 N/ k; `* }5 e4 p+ K+ i
> return;
estroyPlayerData( PlayerData* pPlayerData )2 |$ _) C0 Z# x' J# P4 n
isplayNextConnectionInfo(). }0 C; D+ _& `* N* A
rintStats()% c5 L" ]; G) z* N# u6 a/ d
isplayConnectionInfo( DWORD dwID )| 欢迎光临 数学建模社区-数学中国 (http://www.madio.net/) | Powered by Discuz! X2.5 |