opentnl-cvs Mailing List for Torque Network Library (Page 19)
Brought to you by:
mark_frohnmayer,
s_alanet
You can subscribe to this list here.
2004 |
Jan
|
Feb
|
Mar
|
Apr
(141) |
May
(232) |
Jun
(103) |
Jul
(36) |
Aug
(35) |
Sep
(19) |
Oct
(20) |
Nov
|
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2005 |
Jan
|
Feb
(26) |
Mar
(2) |
Apr
(84) |
May
(5) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Mark F. <mar...@us...> - 2004-05-14 19:57:01
|
Update of /cvsroot/opentnl/tnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20900/tnl Added Files: tnl.dsp Log Message: Added vc6 projects as binary --- NEW FILE: tnl.dsp --- # Microsoft Developer Studio Project File - Name="tnl" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Static Library" 0x0104 CFG=tnl - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "tnl.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "tnl.mak" CFG="tnl - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "tnl - Win32 Release" (based on "Win32 (x86) Static Library") !MESSAGE "tnl - Win32 Debug" (based on "Win32 (x86) Static Library") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe RSC=rc.exe !IF "$(CFG)" == "tnl - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c # ADD CPP /nologo /W3 /GR /GX /Zi /O2 /I "../libtomcrypt" /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /D "TNL_ENABLE_LOGGING" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LIB32=link.exe -lib # ADD BASE LIB32 /nologo # ADD LIB32 /nologo /out:"..\lib\tnl.lib" !ELSEIF "$(CFG)" == "tnl - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "Debug" # PROP BASE Intermediate_Dir "Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "Debug" # PROP Intermediate_Dir "Debug" # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c # ADD CPP /nologo /W3 /Gm /GR /GX /ZI /Od /I "../libtomcrypt" /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /D "TNL_DEBUG" /YX /FD /GZ /c # ADD BASE RSC /l 0x409 /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LIB32=link.exe -lib # ADD BASE LIB32 /nologo # ADD LIB32 /nologo /out:"..\lib\tnld.lib" !ENDIF # Begin Target # Name "tnl - Win32 Release" # Name "tnl - Win32 Debug" # Begin Source File SOURCE=.\assert.cpp # End Source File # Begin Source File SOURCE=.\assert.h # End Source File # Begin Source File SOURCE=.\asymmetricKey.cpp # End Source File # Begin Source File SOURCE=.\asymmetricKey.h # End Source File # Begin Source File SOURCE=.\bitSet.h # End Source File # Begin Source File SOURCE=.\bitStream.cpp # End Source File # Begin Source File SOURCE=.\bitStream.h # End Source File # Begin Source File SOURCE=.\byteBuffer.cpp # End Source File # Begin Source File SOURCE=.\byteBuffer.h # End Source File # Begin Source File SOURCE=.\certificate.cpp # End Source File # Begin Source File SOURCE=.\certificate.h # End Source File # Begin Source File SOURCE=.\clientPuzzle.cpp # End Source File # Begin Source File SOURCE=.\clientPuzzle.h # End Source File # Begin Source File SOURCE=.\connectionStringTable.cpp # End Source File # Begin Source File SOURCE=.\connectionStringTable.h # End Source File # Begin Source File SOURCE=.\dataChunker.cpp # End Source File # Begin Source File SOURCE=.\dataChunker.h # End Source File # Begin Source File SOURCE=.\endian.h # End Source File # Begin Source File SOURCE=.\eventConnection.cpp # End Source File # Begin Source File SOURCE=.\eventConnection.h # End Source File # Begin Source File SOURCE=.\ghostConnection.cpp # End Source File # Begin Source File SOURCE=.\ghostConnection.h # End Source File # Begin Source File SOURCE=.\huffmanStringProcessor.cpp # End Source File # Begin Source File SOURCE=.\huffmanStringProcessor.h # End Source File # Begin Source File SOURCE=.\journal.cpp # End Source File # Begin Source File SOURCE=.\log.cpp # End Source File # Begin Source File SOURCE=.\log.h # End Source File # Begin Source File SOURCE=.\netBase.cpp # End Source File # Begin Source File SOURCE=.\netBase.h # End Source File # Begin Source File SOURCE=.\netConnection.cpp # End Source File # Begin Source File SOURCE=.\netConnection.h # End Source File # Begin Source File SOURCE=.\netEvent.h # End Source File # Begin Source File SOURCE=.\netInterface.cpp # End Source File # Begin Source File SOURCE=.\netInterface.h # End Source File # Begin Source File SOURCE=.\netObject.cpp # End Source File # Begin Source File SOURCE=.\netObject.h # End Source File # Begin Source File SOURCE=.\netStringTable.cpp # End Source File # Begin Source File SOURCE=.\netStringTable.h # End Source File # Begin Source File SOURCE=.\nonce.h # End Source File # Begin Source File SOURCE=.\platform.cpp # End Source File # Begin Source File SOURCE=.\platform.h # End Source File # Begin Source File SOURCE=.\random.cpp # End Source File # Begin Source File SOURCE=.\random.h # End Source File # Begin Source File SOURCE=.\rpc.cpp # End Source File # Begin Source File SOURCE=.\rpc.h # End Source File # Begin Source File SOURCE=.\symmetricCipher.cpp # End Source File # Begin Source File SOURCE=.\symmetricCipher.h # End Source File # Begin Source File SOURCE=.\tnl.h # End Source File # Begin Source File SOURCE=.\tnlJournal.h # End Source File # Begin Source File SOURCE=.\tnlMethodDispatch.cpp # End Source File # Begin Source File SOURCE=.\tnlMethodDispatch.h # End Source File # Begin Source File SOURCE=.\types.h # End Source File # Begin Source File SOURCE=.\udp.cpp # End Source File # Begin Source File SOURCE=.\udp.h # End Source File # Begin Source File SOURCE=.\vector.cpp # End Source File # Begin Source File SOURCE=.\vector.h # End Source File # End Target # End Project |
From: Mark F. <mar...@us...> - 2004-05-14 19:57:01
|
Update of /cvsroot/opentnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20900 Added Files: tnl.dsw Log Message: Added vc6 projects as binary --- NEW FILE: tnl.dsw --- Microsoft Developer Studio Workspace File, Format Version 6.00 # WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! ############################################################################### Project: "TNLTest"=.\test\TNLTest.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name tnl End Project Dependency Begin Project Dependency Project_Dep_Name libtomcrypt End Project Dependency }}} ############################################################################### Project: "libtomcrypt"=.\libtomcrypt\libtomcrypt.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ }}} ############################################################################### Project: "master"=.\master\master.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name libtomcrypt End Project Dependency Begin Project Dependency Project_Dep_Name tnl End Project Dependency }}} ############################################################################### Project: "masterclient"=.\masterclient\masterclient.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name libtomcrypt End Project Dependency Begin Project Dependency Project_Dep_Name tnl End Project Dependency }}} ############################################################################### Project: "server"=.\test\server.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name tnl End Project Dependency Begin Project Dependency Project_Dep_Name libtomcrypt End Project Dependency }}} ############################################################################### Project: "tnl"=.\tnl\tnl.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ }}} ############################################################################### Project: "zap"=.\zap\zap.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name libtomcrypt End Project Dependency Begin Project Dependency Project_Dep_Name tnl End Project Dependency }}} ############################################################################### Global: Package=<5> {{{ }}} Package=<3> {{{ }}} ############################################################################### |
From: Mark F. <mar...@us...> - 2004-05-14 19:56:59
|
Update of /cvsroot/opentnl/tnl/test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20900/test Added Files: TNLTest.dsp server.dsp Log Message: Added vc6 projects as binary --- NEW FILE: server.dsp --- # Microsoft Developer Studio Project File - Name="server" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Application" 0x0101 CFG=server - Win32 Release !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "server.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "server.mak" CFG="server - Win32 Release" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "server - Win32 Release" (based on "Win32 (x86) Application") !MESSAGE "server - Win32 Debug" (based on "Win32 (x86) Application") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe MTL=midl.exe RSC=rc.exe !IF "$(CFG)" == "server - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W4 /O2 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /YX /FD /c # ADD CPP /nologo /MD /W3 /GR /O2 /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /D "_MT" /YX /FD /c # ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 # ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 # ADD BASE RSC /l 0x409 /i "../../include" /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:windows /machine:I386 # ADD LINK32 tnl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:console /machine:I386 /nodefaultlib:"LIBC" /out:"../exe/server.exe" /libpath:"../wxWindows/lib" /libpath:"../lib" # SUBTRACT LINK32 /pdb:none !ELSEIF "$(CFG)" == "server - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "Debug" # PROP BASE Intermediate_Dir "Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "Debug" # PROP Intermediate_Dir "Debug" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W4 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /YX /FD /c # ADD CPP /nologo /MDd /W3 /GR /Zi /Od /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /D "_MT" /YX /FD /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 # ADD BASE RSC /l 0x409 /i "../../include" /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept # ADD LINK32 tnld.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:console /debug /machine:I386 /nodefaultlib:"LIBCD" /out:"../exe/serverD.exe" /pdbtype:sept /libpath:"../wxWindows/lib" /libpath:"../lib" # SUBTRACT LINK32 /pdb:none !ENDIF # Begin Target # Name "server - Win32 Release" # Name "server - Win32 Debug" # Begin Source File SOURCE=.\server.cpp # End Source File # Begin Source File SOURCE=.\testGame.cpp # End Source File # Begin Source File SOURCE=.\testGame.h # End Source File # End Target # End Project --- NEW FILE: TNLTest.dsp --- # Microsoft Developer Studio Project File - Name="TNLTest" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Application" 0x0101 CFG=TNLTest - Win32 Release !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "TNLTest.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "TNLTest.mak" CFG="TNLTest - Win32 Release" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "TNLTest - Win32 Release" (based on "Win32 (x86) Application") !MESSAGE "TNLTest - Win32 Debug" (based on "Win32 (x86) Application") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe MTL=midl.exe RSC=rc.exe !IF "$(CFG)" == "TNLTest - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W4 /O2 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /YX /FD /c # ADD CPP /nologo /MD /W3 /GR /O2 /I "../wxWindows/include" /I "..\wxWindows\lib\msw" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /D "_MT" /D wxUSE_GUI=1 /YX /FD /c # ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 # ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 # ADD BASE RSC /l 0x409 /i "../../include" /d "NDEBUG" # ADD RSC /l 0x409 /i "../wxWindows/include" /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:windows /machine:I386 # ADD LINK32 ../glut/glut32.lib opengl32.lib glu32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:console /machine:I386 /nodefaultlib:"LIBC" /out:"../exe/TNLTest.exe" /libpath:"../lib" # SUBTRACT LINK32 /pdb:none !ELSEIF "$(CFG)" == "TNLTest - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "Debug" # PROP BASE Intermediate_Dir "Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "Debug" # PROP Intermediate_Dir "Debug" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W4 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /YX /FD /c # ADD CPP /nologo /MDd /W3 /GR /Zi /Od /I "../wxWindows/include" /I "..\wxWindows\lib\msw" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D WINVER=0x400 /D "_MT" /D wxUSE_GUI=1 /YX /FD /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 # ADD BASE RSC /l 0x409 /i "../../include" /d "_DEBUG" # ADD RSC /l 0x409 /i "../wxWindows/include" /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept # ADD LINK32 tnld.lib libtomcryptd.lib ../glut/glut32.lib opengl32.lib glu32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib comctl32.lib rpcrt4.lib wsock32.lib /nologo /subsystem:console /debug /machine:I386 /nodefaultlib:"LIBCD" /out:"../exe/TNLTestD.exe" /pdbtype:sept /libpath:"../lib" # SUBTRACT LINK32 /pdb:none !ENDIF # Begin Target # Name "TNLTest - Win32 Release" # Name "TNLTest - Win32 Debug" # Begin Source File SOURCE=.\testGame.cpp # End Source File # Begin Source File SOURCE=.\testGame.h # End Source File # Begin Source File SOURCE=.\testGameRender.cpp # End Source File # Begin Source File SOURCE=.\testWindow.cpp # End Source File # End Target # End Project |
From: Mark F. <mar...@us...> - 2004-05-14 19:56:59
|
Update of /cvsroot/opentnl/tnl/master In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20900/master Added Files: master.dsp Log Message: Added vc6 projects as binary --- NEW FILE: master.dsp --- # Microsoft Developer Studio Project File - Name="master" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Console Application" 0x0103 CFG=master - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "master.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "master.mak" CFG="master - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "master - Win32 Release" (based on "Win32 (x86) Console Application") !MESSAGE "master - Win32 Debug" (based on "Win32 (x86) Console Application") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe RSC=rc.exe !IF "$(CFG)" == "master - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD CPP /nologo /W3 /GR /GX /O2 /I "../tnl" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 # ADD LINK32 wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 /out:"../exe/master.exe" !ELSEIF "$(CFG)" == "master - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "master___Win32_Debug" # PROP BASE Intermediate_Dir "master___Win32_Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "master___Win32_Debug" # PROP Intermediate_Dir "master___Win32_Debug" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c # ADD CPP /nologo /W3 /Gm /GR /GX /ZI /Od /I "../tnl" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c # ADD BASE RSC /l 0x409 /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept # ADD LINK32 wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /out:"../exe/masterd.exe" /pdbtype:sept !ENDIF # Begin Target # Name "master - Win32 Release" # Name "master - Win32 Debug" # Begin Source File SOURCE=.\main.cpp # End Source File # Begin Source File SOURCE=.\masterInterface.cpp # End Source File # Begin Source File SOURCE=.\masterInterface.h # End Source File # End Target # End Project |
From: Mark F. <mar...@us...> - 2004-05-14 19:56:59
|
Update of /cvsroot/opentnl/tnl/masterclient In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20900/masterclient Added Files: masterclient.dsp Log Message: Added vc6 projects as binary --- NEW FILE: masterclient.dsp --- # Microsoft Developer Studio Project File - Name="masterclient" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Console Application" 0x0103 CFG=masterclient - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "masterclient.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "masterclient.mak" CFG="masterclient - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "masterclient - Win32 Release" (based on "Win32 (x86) Console Application") !MESSAGE "masterclient - Win32 Debug" (based on "Win32 (x86) Console Application") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe RSC=rc.exe !IF "$(CFG)" == "masterclient - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD CPP /nologo /W3 /GR /GX /O2 /I "../tnl" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 # ADD LINK32 wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 /out:"../exe/masterclient.exe" !ELSEIF "$(CFG)" == "masterclient - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "masterclient___Win32_Debug" # PROP BASE Intermediate_Dir "masterclient___Win32_Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "masterclient___Win32_Debug" # PROP Intermediate_Dir "masterclient___Win32_Debug" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c # ADD CPP /nologo /W3 /Gm /GR /GX /ZI /Od /I "../tnl" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c # ADD BASE RSC /l 0x409 /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept # ADD LINK32 wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /out:"../exe/masterclientd.exe" /pdbtype:sept !ENDIF # Begin Target # Name "masterclient - Win32 Release" # Name "masterclient - Win32 Debug" # Begin Source File SOURCE=.\main.cpp # End Source File # Begin Source File SOURCE=..\master\masterInterface.cpp # End Source File # Begin Source File SOURCE=..\master\masterInterface.h # End Source File # End Target # End Project |
From: Mark F. <mar...@us...> - 2004-05-14 19:56:59
|
Update of /cvsroot/opentnl/tnl/libtomcrypt In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20900/libtomcrypt Added Files: libtomcrypt.dsp Log Message: Added vc6 projects as binary --- NEW FILE: libtomcrypt.dsp --- # Microsoft Developer Studio Project File - Name="libtomcrypt" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Static Library" 0x0104 CFG=libtomcrypt - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "libtomcrypt.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "libtomcrypt.mak" CFG="libtomcrypt - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "libtomcrypt - Win32 Release" (based on "Win32 (x86) Static Library") !MESSAGE "libtomcrypt - Win32 Debug" (based on "Win32 (x86) Static Library") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe RSC=rc.exe !IF "$(CFG)" == "libtomcrypt - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "libtomcrypt___Win32_Release" # PROP BASE Intermediate_Dir "libtomcrypt___Win32_Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "libtomcrypt___Win32_Release" # PROP Intermediate_Dir "libtomcrypt___Win32_Release" # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c # ADD CPP /nologo /W3 /GX /O2 /I "." /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LIB32=link.exe -lib # ADD BASE LIB32 /nologo # ADD LIB32 /nologo /out:"..\lib\libtomcrypt.lib" !ELSEIF "$(CFG)" == "libtomcrypt - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "libtomcrypt___Win32_Debug" # PROP BASE Intermediate_Dir "libtomcrypt___Win32_Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "libtomcrypt___Win32_Debug" # PROP Intermediate_Dir "libtomcrypt___Win32_Debug" # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c # ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "." /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c # ADD BASE RSC /l 0x409 /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LIB32=link.exe -lib # ADD BASE LIB32 /nologo # ADD LIB32 /nologo /out:"..\lib\libtomcryptd.lib" !ENDIF # Begin Target # Name "libtomcrypt - Win32 Release" # Name "libtomcrypt - Win32 Debug" # Begin Source File SOURCE=.\aes.c # End Source File # Begin Source File SOURCE=.\base64.c # End Source File # Begin Source File SOURCE=.\bits.c # End Source File # Begin Source File SOURCE=.\blowfish.c # End Source File # Begin Source File SOURCE=.\cast5.c # End Source File # Begin Source File SOURCE=.\cbc.c # End Source File # Begin Source File SOURCE=.\cfb.c # End Source File # Begin Source File SOURCE=.\crypt.c # End Source File # Begin Source File SOURCE=.\ctr.c # End Source File # Begin Source File SOURCE=.\des.c # End Source File # Begin Source File SOURCE=.\dh.c # End Source File # Begin Source File SOURCE=.\dsa.c # End Source File # Begin Source File SOURCE=.\ecb.c # End Source File # Begin Source File SOURCE=.\ecc.c # End Source File # Begin Source File SOURCE=.\gf.c # End Source File # Begin Source File SOURCE=.\hash.c # End Source File # Begin Source File SOURCE=.\hmac.c # End Source File # Begin Source File SOURCE=.\keyring.c # End Source File # Begin Source File SOURCE=.\md2.c # End Source File # Begin Source File SOURCE=.\md4.c # End Source File # Begin Source File SOURCE=.\md5.c # End Source File # Begin Source File SOURCE=.\mem.c # End Source File # Begin Source File SOURCE=.\mpi.c # End Source File # Begin Source File SOURCE=.\mycrypt.h # End Source File # Begin Source File SOURCE=.\mycrypt_argchk.h # End Source File # Begin Source File SOURCE=.\mycrypt_cfg.h # End Source File # Begin Source File SOURCE=.\mycrypt_cipher.h # End Source File # Begin Source File SOURCE=.\mycrypt_custom.h # End Source File # Begin Source File SOURCE=.\mycrypt_gf.h # End Source File # Begin Source File SOURCE=.\mycrypt_hash.h # End Source File # Begin Source File SOURCE=.\mycrypt_kr.h # End Source File # Begin Source File SOURCE=.\mycrypt_macros.h # End Source File # Begin Source File SOURCE=.\mycrypt_misc.h # End Source File # Begin Source File SOURCE=.\mycrypt_pk.h # End Source File # Begin Source File SOURCE=.\mycrypt_prng.h # End Source File # Begin Source File SOURCE=.\noekeon.c # End Source File # Begin Source File SOURCE=.\ofb.c # End Source File # Begin Source File SOURCE=.\omac.c # End Source File # Begin Source File SOURCE=.\packet.c # End Source File # Begin Source File SOURCE=.\prime.c # End Source File # Begin Source File SOURCE=.\rc2.c # End Source File # Begin Source File SOURCE=.\rc4.c # End Source File # Begin Source File SOURCE=.\rc5.c # End Source File # Begin Source File SOURCE=.\rc6.c # End Source File # Begin Source File SOURCE=.\rmd128.c # End Source File # Begin Source File SOURCE=.\rmd160.c # End Source File # Begin Source File SOURCE=.\rsa.c # End Source File # Begin Source File SOURCE=".\safer+.c" # End Source File # Begin Source File SOURCE=.\safer.c # End Source File # Begin Source File SOURCE=.\safer_tab.c # End Source File # Begin Source File SOURCE=.\sha1.c # End Source File # Begin Source File SOURCE=.\sha256.c # End Source File # Begin Source File SOURCE=.\sha512.c # End Source File # Begin Source File SOURCE=.\skipjack.c # End Source File # Begin Source File SOURCE=.\sprng.c # End Source File # Begin Source File SOURCE=.\strings.c # End Source File # Begin Source File SOURCE=.\tiger.c # End Source File # Begin Source File SOURCE=.\tommath.h # End Source File # Begin Source File SOURCE=.\twofish.c # End Source File # Begin Source File SOURCE=.\twofish_tab.c # End Source File # Begin Source File SOURCE=.\xtea.c # End Source File # Begin Source File SOURCE=.\yarrow.c # End Source File # End Target # End Project |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:35
|
Update of /cvsroot/opentnl/tnl/exe In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/exe Modified Files: build.sh Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions Index: build.sh =================================================================== RCS file: /cvsroot/opentnl/tnl/exe/build.sh,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** build.sh 14 May 2004 18:50:00 -0000 1.1 --- build.sh 14 May 2004 19:49:52 -0000 1.2 *************** *** 23,27 **** rm -rf tnl ! cvs -d:ext:"$USER"@cvs.sourceforge.net:/cvsroot/opentnl export tnl tar -czf tnl-"$VERSION"-source.tar.gz tnl zip -r tnl-"$VERSION"-source.zip tnl --- 23,27 ---- rm -rf tnl ! cvs -d:ext:"$USER"@cvs.sourceforge.net:/cvsroot/opentnl export -r HEAD tnl tar -czf tnl-"$VERSION"-source.tar.gz tnl zip -r tnl-"$VERSION"-source.zip tnl |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:11
|
Update of /cvsroot/opentnl/tnl/zap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/zap Removed Files: zap.dsp Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- zap.dsp DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:10
|
Update of /cvsroot/opentnl/tnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/tnl Removed Files: tnl.dsp Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- tnl.dsp DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:10
|
Update of /cvsroot/opentnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140 Removed Files: tnl.dsw Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- tnl.dsw DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:07
|
Update of /cvsroot/opentnl/tnl/test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/test Removed Files: TNLTest.dsp server.dsp Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- server.dsp DELETED --- --- TNLTest.dsp DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:07
|
Update of /cvsroot/opentnl/tnl/masterclient In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/masterclient Removed Files: masterclient.dsp Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- masterclient.dsp DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:02
|
Update of /cvsroot/opentnl/tnl/master In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/master Removed Files: master.dsp Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- master.dsp DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 19:50:02
|
Update of /cvsroot/opentnl/tnl/libtomcrypt In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19140/libtomcrypt Removed Files: libtomcrypt.dsp Log Message: Updated build script Removed text vc6 project files in preperation for adding binary versions --- libtomcrypt.dsp DELETED --- |
From: Mark F. <mar...@us...> - 2004-05-14 18:50:35
|
Update of /cvsroot/opentnl/tnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4173/tnl Modified Files: netBase.cpp tnl.dsp Log Message: Added FPS meter to game UI Updated VC6 project for compatibility with current version Added build script for automatic builds Index: netBase.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/netBase.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** netBase.cpp 12 May 2004 19:35:11 -0000 1.2 --- netBase.cpp 14 May 2004 18:49:53 -0000 1.3 *************** *** 110,113 **** --- 110,121 ---- qsort((void *) &dynamicTable[0], dynamicTable.size(), sizeof(NetClassRep *), ACRCompare); + + TNLLogBlock(LogNetBase, + logprintf("Class Group: %d Class Type: %d count: %d", + group, type, dynamicTable.size()); + for(S32 i = 0; i < dynamicTable.size(); i++) + logprintf("%s", dynamicTable[i]->getClassName()); + ) + mClassTable[group][type] = new NetClassRep*[mNetClassCount[group][type]]; Index: tnl.dsp =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/tnl.dsp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** tnl.dsp 13 May 2004 01:45:50 -0000 1.2 --- tnl.dsp 14 May 2004 18:49:53 -0000 1.3 *************** *** 42,46 **** # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c ! # ADD CPP /nologo /W3 /GR /GX /O2 /I "../libtomcrypt" /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" --- 42,46 ---- # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c ! # ADD CPP /nologo /W3 /GR /GX /Zi /O2 /I "../libtomcrypt" /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /D "TNL_ENABLE_LOGGING" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" |
From: Mark F. <mar...@us...> - 2004-05-14 18:50:14
|
Update of /cvsroot/opentnl/tnl/zap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4173/zap Modified Files: UIGame.cpp UIGame.h main.cpp sfx.cpp sfx.h zap.dsp Log Message: Added FPS meter to game UI Updated VC6 project for compatibility with current version Added build script for automatic builds Index: main.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/main.cpp,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** main.cpp 14 May 2004 00:33:38 -0000 1.31 --- main.cpp 14 May 2004 18:49:55 -0000 1.32 *************** *** 247,250 **** --- 247,251 ---- TNL_IMPLEMENT_JOURNAL_ENTRYPOINT(ZapJournal, display, ()) { + glFlush(); if(UserInterface::current) UserInterface::current->render(); *************** *** 259,265 **** } - glFlush(); glutSwapBuffers(); - } --- 260,264 ---- *************** *** 388,391 **** --- 387,391 ---- TNLLogEnable(LogNetInterface, true); TNLLogEnable(LogPlatform, true); + TNLLogEnable(LogNetBase, true); //TNLLogEnable(LogBlah, true); *************** *** 446,454 **** gZapJournal.load(argv[i+1]); } - else if(!stricmp(argv[i], "-gain")) - { - if(hasAdditionalArg) - SFXObject::setCaptureGain(atoi(argv[i+1])); - } else if(!stricmp(argv[i], "-dedicated")) { --- 446,449 ---- Index: sfx.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/sfx.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** sfx.cpp 13 May 2004 01:45:52 -0000 1.20 --- sfx.cpp 14 May 2004 18:49:55 -0000 1.21 *************** *** 129,137 **** captureBuffer->Unlock(buf1, count1, buf2, count2); - // Endeavour futilely to do a gain pass - S16 *data = (S16*)buffer->getBuffer(); - for(U32 i=start/2; i<(start+sizeAdd)/2; i++) - data[i] <<= mCaptureGain; - lastReadOffset += count1 + count2; lastReadOffset %= BufferBytes; --- 129,132 ---- *************** *** 220,224 **** Point SFXObject::mListenerVelocity; F32 SFXObject::mMaxDistance = 500; - S32 SFXObject::mCaptureGain = 0; static ALuint gBuffers[NumSFXBuffers]; --- 215,218 ---- *************** *** 227,235 **** static Vector<SFXHandle> gPlayList; - void SFXObject::setCaptureGain(S32 amt) - { - mCaptureGain = amt; - } - SFXObject::SFXObject(U32 profileIndex, ByteBufferPtr ib, F32 gain, Point position, Point velocity) { --- 221,224 ---- *************** *** 319,327 **** --- 308,322 ---- { ALint processed; + alGetError(); + alGetSourcei(gSources[sourceIndex], AL_BUFFERS_PROCESSED, &processed); + while(processed) { ALuint buffer; alSourceUnqueueBuffers(gSources[sourceIndex], 1, &buffer); + if(alGetError() != AL_NO_ERROR) + return; + //logprintf("unqueued buffer %d\n", buffer); processed--; Index: UIGame.h =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/UIGame.h,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** UIGame.h 9 May 2004 20:35:17 -0000 1.8 --- UIGame.h 14 May 2004 18:49:55 -0000 1.9 *************** *** 69,72 **** --- 69,73 ---- enum { ChatBlinkTime = 100, + FPSAvgCount = 32, }; Mode mCurrentMode; *************** *** 78,82 **** U32 mChatLastBlinkTime; bool mInScoreboardMode; ! VChatHelper *mVChat; --- 79,87 ---- U32 mChatLastBlinkTime; bool mInScoreboardMode; ! ! bool mFPSVisible; ! U32 mIdleTimeDelta[FPSAvgCount]; ! U32 mFrameIndex; ! VChatHelper *mVChat; Index: UIGame.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/UIGame.cpp,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** UIGame.cpp 12 May 2004 22:30:54 -0000 1.25 --- UIGame.cpp 14 May 2004 18:49:55 -0000 1.26 *************** *** 50,53 **** --- 50,58 ---- mCurrentMode = PlayMode; mInScoreboardMode = false; + mFPSVisible = false; + + mFrameIndex = 0; + for(U32 i = 0; i < FPSAvgCount; i++) + mIdleTimeDelta[i] = 50; mChatLastBlinkTime = 0; *************** *** 101,104 **** --- 106,111 ---- } mVoiceRecorder.idle(timeDelta); + mIdleTimeDelta[mFrameIndex % FPSAvgCount] = timeDelta; + mFrameIndex++; } *************** *** 250,253 **** --- 257,267 ---- #endif + if(mFPSVisible) + { + U32 sum = 0; + for(U32 i = 0; i < FPSAvgCount; i++) + sum += mIdleTimeDelta[i]; + drawStringf(710, 10, 30, "%4.2f fps", (1000 * FPSAvgCount) / F32(sum)); + } if(mVChat->isActive()) mVChat->render(); *************** *** 365,368 **** --- 379,385 ---- break; } + case 'P': + mFPSVisible = !mFPSVisible; + break; case 'W': mCurrentMove.up = 1.0; *************** *** 619,627 **** if(!mRecordingAudio) { mUnusedAudio = new ByteBuffer(0); mRecordingAudio = true; mMaxAudioSample = 0; mVoiceAudioTimer.reset(FirstVoiceAudioSampleTime); - SFXObject::startRecording(); // trim the start of the capture buffer: --- 636,647 ---- if(!mRecordingAudio) { + mRecordingAudio = SFXObject::startRecording(); + if(!mRecordingAudio) + return; + mUnusedAudio = new ByteBuffer(0); mRecordingAudio = true; mMaxAudioSample = 0; mVoiceAudioTimer.reset(FirstVoiceAudioSampleTime); // trim the start of the capture buffer: *************** *** 636,640 **** { process(); - SFXObject::stopRecording(); mRecordingAudio = false; --- 656,659 ---- *************** *** 651,654 **** --- 670,676 ---- U32 sampleCount = mUnusedAudio->getBufferSize() / 2; + if(sampleCount == preSampleCount) + return; + S16 *samplePtr = (S16 *) mUnusedAudio->getBuffer(); mMaxAudioSample = 0; Index: zap.dsp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/zap.dsp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** zap.dsp 13 May 2004 01:45:52 -0000 1.5 --- zap.dsp 14 May 2004 18:49:59 -0000 1.6 *************** *** 43,47 **** # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c ! # ADD CPP /nologo /W3 /GR /GX /O2 /I "../tnl" /I "../glut" /I "../openal" /I "c:/dxsdk/include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" --- 43,47 ---- # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c ! # ADD CPP /nologo /W3 /GR /GX /Zi /O2 /I "../tnl" /I "../glut" /I "../openal" /I "c:/dxsdk/include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /D "TNL_ENABLE_LOGGING" /YX /FD /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" *************** *** 51,55 **** LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 ! # ADD LINK32 dsound.lib dinput.lib dinput8.lib dxguid.lib ../openal/alut.lib ../openal/openal32.lib wsock32.lib opengl32.lib glu32.lib ../glut/glut32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 /out:"../exe/zap.exe" /libpath:"c:/dxsdk/lib" !ELSEIF "$(CFG)" == "zap - Win32 Debug" --- 51,55 ---- LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 ! # ADD LINK32 dsound.lib dinput.lib dinput8.lib dxguid.lib ../openal/alut.lib ../openal/openal32.lib wsock32.lib opengl32.lib glu32.lib ../glut/glut32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /out:"../exe/zap.exe" /libpath:"c:/dxsdk/lib" !ELSEIF "$(CFG)" == "zap - Win32 Debug" *************** *** 97,100 **** --- 97,108 ---- # Begin Source File + SOURCE=.\controlObjectConnection.cpp + # End Source File + # Begin Source File + + SOURCE=.\controlObjectConnection.h + # End Source File + # Begin Source File + SOURCE=.\CTFGame.cpp # End Source File *************** *** 121,124 **** --- 129,136 ---- # Begin Source File + SOURCE=.\gameItems.cpp + # End Source File + # Begin Source File + SOURCE=.\gameLoader.cpp # End Source File *************** *** 257,260 **** --- 269,276 ---- # Begin Source File + SOURCE=.\soccerGame.cpp + # End Source File + # Begin Source File + SOURCE=.\sparkManager.cpp # End Source File Index: sfx.h =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/sfx.h,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** sfx.h 8 May 2004 00:03:51 -0000 1.10 --- sfx.h 14 May 2004 18:49:59 -0000 1.11 *************** *** 101,105 **** static bool startRecording(); static void captureSamples(ByteBufferPtr sampleBuffer); - static void setCaptureGain(S32 amt); static void stopRecording(); --- 101,104 ---- |
From: Mark F. <mar...@us...> - 2004-05-14 18:50:11
|
Update of /cvsroot/opentnl/tnl/exe In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4173/exe Added Files: build.sh Log Message: Added FPS meter to game UI Updated VC6 project for compatibility with current version Added build script for automatic builds --- NEW FILE: build.sh --- PLATFORM=$1 VERSION=$2 USER=$3 USAGE="build <win32|macosx|linux|source> <version> [user]" if [ "$PLATFORM" != "win32" -a "$PLATFORM" != "macosx" -a "$PLATFORM" != "linux" -a "$PLATFORM" != "source" ]; then echo "$USAGE" exit 1 fi if [ "$VERSION" = "" ]; then echo "$USAGE" exit 1 fi if [ "$PLATFORM" = "source" ]; then if [ "$USER" = "" ]; then echo User must be specified for source build! exit 1 fi rm -rf tnl cvs -d:ext:"$USER"@cvs.sourceforge.net:/cvsroot/opentnl export tnl tar -czf tnl-"$VERSION"-source.tar.gz tnl zip -r tnl-"$VERSION"-source.zip tnl fi DIR=zap-"$VERSION" echo Writing to dir "$DIR" rm -rf "$DIR" mkdir "$DIR" cp *.txt *.WAV *.wav "$DIR" if [ "$PLATFORM" = "win32" ]; then cp zap.exe *.dll "$DIR" rm "$DIR"-win32.zip zip -r "$DIR"-win32.zip "$DIR" fi if [ "$PLATFORM" = "macosx" ]; then cp ZAP "$DIR" strip "$DIR"/ZAP rm "$DIR"-macosx.tar.gz tar -czf "$DIR"-macosx.tar.gz "$DIR" fi if [ "$PLATFORM" = "linux" ]; then cp zap "$DIR" strip "$DIR"/zap rm "$DIR"-x86linux.tar.gz tar -czf "$DIR"-x86linux.tar.gz "$DIR" fi |
From: Mark F. <mar...@us...> - 2004-05-14 01:34:26
|
Update of /cvsroot/opentnl/tnl/exe In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv495/exe Modified Files: README.txt Log Message: Updated game version to 1.2.1 Index: README.txt =================================================================== RCS file: /cvsroot/opentnl/tnl/exe/README.txt,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** README.txt 12 May 2004 02:28:05 -0000 1.10 --- README.txt 14 May 2004 01:34:17 -0000 1.11 *************** *** 1,20 **** ! ZAP 1.2.0 Welcome to ZAP, the retro multiplayer team action game! ! Changes since version 1.1.2: ! - Added shields, boost and ship energy ! - Added Soccer game type ! - Added level cycling and victory conditions ! - Added deathmatch mini level between team levels ! - Removed player particle trails and added motion trails ! - Added README ! - Added credits on exit ! - Added a new CTF level ! - Added voice recording and playback (recording on Win32 only for now) ! - Added voice compression using the variable LPC10 codec from the ! excellent HawkVoice library. ! - Added more sounds ! - Added journaling capabilities for debugging purposes Controls: --- 1,8 ---- ! ZAP 1.2.1 Welcome to ZAP, the retro multiplayer team action game! ! Changes since version 1.2.0: ! - Fixed bad crashiness. Controls: |
From: Mark F. <mar...@us...> - 2004-05-14 01:34:26
|
Update of /cvsroot/opentnl/tnl/zap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv495/zap Modified Files: game.h Log Message: Updated game version to 1.2.1 Index: game.h =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/game.h,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** game.h 13 May 2004 21:29:56 -0000 1.21 --- game.h 14 May 2004 01:34:17 -0000 1.22 *************** *** 212,216 **** extern void endGame(); ! #define ZAP_GAME_STRING "ZAP 1.2.0 rc 6" }; --- 212,216 ---- extern void endGame(); ! #define ZAP_GAME_STRING "ZAP 1.2.1 rc 1" }; |
From: Mark F. <mar...@us...> - 2004-05-14 01:31:57
|
Update of /cvsroot/opentnl/tnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32509/tnl Modified Files: ghostConnection.cpp tnlGhostConnection.h Log Message: Updated GhostConnection to have an additional phase between ghost always done and ready for normal ghosts that activates the GA objects. Index: tnlGhostConnection.h =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/tnlGhostConnection.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** tnlGhostConnection.h 5 May 2004 09:50:35 -0000 1.2 --- tnlGhostConnection.h 14 May 2004 01:31:44 -0000 1.3 *************** *** 213,217 **** TNL_DECLARE_RPC(rpcGhostAlwaysDone, (U32 sequence)); ! /// RPC from client to server sent when the client receives the rpcGhostAlwaysDone TNL_DECLARE_RPC(rpcReadyForNormalGhosts, (U32 sequence)); --- 213,223 ---- TNL_DECLARE_RPC(rpcGhostAlwaysDone, (U32 sequence)); ! /// RPC from client to server sent when the client receives the rpcGhostAlwaysDone, to notify that it is ready for the activation of the ghost always objects. ! TNL_DECLARE_RPC(rpcReadyForGhostAlwaysActivation, (U32 sequence)); ! ! /// RPC from server to client called after all GhostAlways objects are activated ! TNL_DECLARE_RPC(rpcGhostAlwaysActivated, (U32 sequence)); ! ! /// RPC from client to server sent when the client receives the rpcGhostAlwaysActivated TNL_DECLARE_RPC(rpcReadyForNormalGhosts, (U32 sequence)); *************** *** 257,261 **** KillGhost = BIT(5), ///< The ghost of this GhostInfo's NetObject should be destroyed ASAP. KillingGhost = BIT(6), ///< The ghost of this GhostInfo's NetObject is in the process of being destroyed. - ScopedEvent = BIT(7), ///< This GhostInfo's NetObject is being sent to the client in the form of an event (GhostAlways). /// Flag mask - if any of these are set, the object is not yet available for ghost ID lookup. --- 263,266 ---- Index: ghostConnection.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/ghostConnection.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** ghostConnection.cpp 12 May 2004 19:35:11 -0000 1.6 --- ghostConnection.cpp 14 May 2004 01:31:44 -0000 1.7 *************** *** 748,751 **** --- 748,803 ---- //----------------------------------------------------------------------------- + void GhostConnection::activateGhosting() + { + if(!doesGhostFrom()) + return; + + mGhostingSequence++; + + TNLAssert((mGhostFreeIndex == 0) && (mGhostZeroUpdateIndex == 0), "Error: ghosts in the ghost list before activate."); + + // iterate through the ghost always objects and InScope them... + // also post em all to the other side. + + Vector<NetObject *> &ghostAlwaysSet = mInterface->getScopeAlwaysList(); + + S32 sz = ghostAlwaysSet.size(); + S32 j; + + for(j = 0; j < sz; j++) + { + U32 idx = MaxGhostCount - sz + j; + mGhostArray[j] = mGhostRefs + idx; + mGhostArray[j]->arrayIndex = j; + } + for(j = sz; j < MaxGhostCount; j++) + { + U32 idx = j - sz; + mGhostArray[j] = mGhostRefs + idx; + mGhostArray[j]->arrayIndex = j; + } + mScoping = true; // so that objectInScope will work + for(j = 0; j < sz; j++) + { + objectInScope(ghostAlwaysSet[j]); + } + rpcGhostAlwaysStarting(mGhostingSequence, ghostAlwaysSet.size()); + for(j = mGhostZeroUpdateIndex - 1; j >= 0; j--) + { + TNLAssert((mGhostArray[j]->flags & GhostInfo::ScopeAlways) != 0, "Non-scope always in the scope always list.") + + // we may end up resending state here, but at least initial state + // will not be resent. + mGhostArray[j]->updateMask = 0; + ghostPushToZero(mGhostArray[j]); + mGhostArray[j]->flags &= ~GhostInfo::NotYetGhosted; + mGhostArray[j]->flags |= GhostInfo::Ghosting; + + postNetEvent(new GhostAlwaysObjectEvent(mGhostArray[j]->obj, mGhostArray[j]->index)); + } + rpcGhostAlwaysDone(mGhostingSequence); + //TNLAssert(validateGhostArray(), "Invalid ghost array!"); + } + TNL_DECLARE_ENUM(GhostConnection::GhostCountBitSize); TNL_IMPLEMENT_RPC(GhostConnection, rpcGhostAlwaysStarting, (U32 sequence, Int<GhostConnection::GhostCountBitSize> ghostCount), *************** *** 771,776 **** return; } mGhostingSequence = sequence; ! rpcReadyForNormalGhosts(mGhostingSequence); } --- 823,861 ---- return; } + rpcReadyForGhostAlwaysActivation(sequence); + } + + TNL_IMPLEMENT_RPC(GhostConnection, rpcReadyForGhostAlwaysActivation, (U32 sequence), + NetClassGroupGameMask, RPCGuaranteedOrdered, RPCDirAny, 0) + { + TNLLogMessageV(LogGhostConnection, ("Got ready for ghost always activation %d %d", sequence, mGhostingSequence)); + if(!doesGhostFrom()) + { + setLastError("Invalid packet."); + return; + } + if(sequence != mGhostingSequence) + return; + + for(S32 i = 0; i < mGhostFreeIndex; i++) + { + mGhostArray[i]->flags &= ~GhostInfo::Ghosting; + if(mGhostArray[i]->obj) + mGhostArray[i]->obj->onGhostAvailable(this); + } + rpcGhostAlwaysActivated(mGhostingSequence); + } + + TNL_IMPLEMENT_RPC(GhostConnection, rpcGhostAlwaysActivated, (U32 sequence), + NetClassGroupGameMask, RPCGuaranteedOrdered, RPCDirAny, 0) + { + TNLLogMessageV(LogGhostConnection, ("Got GhostAlwaysActivated %d", sequence)); + if(!doesGhostTo()) + { + setLastError("Invalid packet."); + return; + } mGhostingSequence = sequence; ! rpcReadyForNormalGhosts(mGhostingSequence); } *************** *** 788,800 **** onAllGhostAlwaysObjectsReceived(); mGhosting = true; - for(S32 i = 0; i < mGhostFreeIndex; i++) - { - if(mGhostArray[i]->flags & GhostInfo::ScopedEvent) - { - mGhostArray[i]->flags &= ~(GhostInfo::Ghosting | GhostInfo::ScopedEvent); - if(mGhostArray[i]->obj) - mGhostArray[i]->obj->onGhostAvailable(this); - } - } } --- 873,876 ---- *************** *** 828,883 **** } - void GhostConnection::activateGhosting() - { - if(!doesGhostFrom()) - return; - - mGhostingSequence++; - - TNLAssert((mGhostFreeIndex == 0) && (mGhostZeroUpdateIndex == 0), "Error: ghosts in the ghost list before activate."); - - // iterate through the ghost always objects and InScope them... - // also post em all to the other side. - - Vector<NetObject *> &ghostAlwaysSet = mInterface->getScopeAlwaysList(); - - S32 sz = ghostAlwaysSet.size(); - S32 j; - - for(j = 0; j < sz; j++) - { - U32 idx = MaxGhostCount - sz + j; - mGhostArray[j] = mGhostRefs + idx; - mGhostArray[j]->arrayIndex = j; - } - for(j = sz; j < MaxGhostCount; j++) - { - U32 idx = j - sz; - mGhostArray[j] = mGhostRefs + idx; - mGhostArray[j]->arrayIndex = j; - } - mScoping = true; // so that objectInScope will work - for(j = 0; j < sz; j++) - { - objectInScope(ghostAlwaysSet[j]); - } - rpcGhostAlwaysStarting(mGhostingSequence, ghostAlwaysSet.size()); - for(j = mGhostZeroUpdateIndex - 1; j >= 0; j--) - { - TNLAssert((mGhostArray[j]->flags & GhostInfo::ScopeAlways) != 0, "Non-scope always in the scope always list.") - - // we may end up resending state here, but at least initial state - // will not be resent. - mGhostArray[j]->updateMask = 0; - ghostPushToZero(mGhostArray[j]); - mGhostArray[j]->flags &= ~GhostInfo::NotYetGhosted; - mGhostArray[j]->flags |= GhostInfo::Ghosting | GhostInfo::ScopedEvent; - - postNetEvent(new GhostAlwaysObjectEvent(mGhostArray[j]->obj, mGhostArray[j]->index)); - } - rpcGhostAlwaysDone(mGhostingSequence); - //TNLAssert(validateGhostArray(), "Invalid ghost array!"); - } - void GhostConnection::clearGhostInfo() { --- 904,907 ---- |
From: Mark F. <mar...@us...> - 2004-05-14 00:33:54
|
Update of /cvsroot/opentnl/tnl/zap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22135/zap Modified Files: ZAP.vcproj game.cpp gameConnection.cpp gameConnection.h gameType.cpp main.cpp masterConnection.cpp ship.cpp Added Files: controlObjectConnection.cpp controlObjectConnection.h Log Message: Split GameConnection into two connection classes in preperation for moving most of the game type RPCs into GameConnection --- NEW FILE: controlObjectConnection.cpp --- //----------------------------------------------------------------------------------- // // Torque Network Library - ZAP example multiplayer vector graphics space game // Copyright (C) 2004 GarageGames.com, Inc. // For more information see http://www.opentnl.org // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation; either version 2 of the License, or // (at your option) any later version. // // For use in products that are not compatible with the terms of the GNU // General Public License, alternative licensing options are available // from GarageGames.com. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // //------------------------------------------------------------------------------------ #include "gameObject.h" #include "controlObjectConnection.h" namespace Zap { ControlObjectConnection::ControlObjectConnection() { highSendIndex[0] = 0; highSendIndex[1] = 0; highSendIndex[2] = 0; mLastClientControlCRC = 0; firstMoveIndex = 1; } void ControlObjectConnection::setControlObject(GameObject *theObject) { if(controlObject.isValid()) controlObject->setControllingClient(NULL); controlObject = theObject; setScopeObject(theObject); if(theObject) theObject->setControllingClient((GameConnection *) this); } void ControlObjectConnection::packetReceived(PacketNotify *notify) { for(; firstMoveIndex < ((GamePacketNotify *) notify)->firstUnsentMoveIndex; firstMoveIndex++) pendingMoves.erase(U32(0)); mServerPosition = ((GamePacketNotify *) notify)->lastControlObjectPosition; Parent::packetReceived(notify); } U32 ControlObjectConnection::getControlCRC() { PacketStream stream; GameObject *co = getControlObject(); if(!co) return 0; stream.writeInt(getGhostIndex(co), GhostConnection::GhostIdBitSize); co->writeControlState(&stream); stream.zeroToByteBoundary(); return stream.calculateCRC(0, stream.getBytePosition()); } void ControlObjectConnection::writePacket(BitStream *bstream, PacketNotify *notify) { if(isConnectionToServer()) { U32 firstSendIndex = highSendIndex[0]; if(firstSendIndex < firstMoveIndex) firstSendIndex = firstMoveIndex; bstream->write(getControlCRC()); bstream->write(firstSendIndex); U32 skipCount = firstSendIndex - firstMoveIndex; U32 moveCount = pendingMoves.size() - skipCount; bstream->writeRangedU32(moveCount, 0, MaxPendingMoves); Move dummy; Move *lastMove = &dummy; for(S32 i = skipCount; i < pendingMoves.size(); i++) { pendingMoves[i].pack(bstream, lastMove); lastMove = &pendingMoves[i]; } ((GamePacketNotify *) notify)->firstUnsentMoveIndex = firstMoveIndex + pendingMoves.size(); if(controlObject.isValid()) ((GamePacketNotify *) notify)->lastControlObjectPosition = controlObject->getActualPos(); highSendIndex[0] = highSendIndex[1]; highSendIndex[1] = highSendIndex[2]; highSendIndex[2] = ((GamePacketNotify *) notify)->firstUnsentMoveIndex; } else { S32 ghostIndex = -1; if(controlObject.isValid()) { ghostIndex = getGhostIndex(controlObject); mServerPosition = controlObject->getActualPos(); } // we only compress points relative if we know that the // remote side has a copy of the control object already mCompressPointsRelative = bstream->writeFlag(ghostIndex != -1); if(bstream->writeFlag(getControlCRC() != mLastClientControlCRC)) { if(ghostIndex != -1) { bstream->writeInt(ghostIndex, GhostConnection::GhostIdBitSize); controlObject->writeControlState(bstream); } } } Parent::writePacket(bstream, notify); } void ControlObjectConnection::readPacket(BitStream *bstream) { if(isConnectionToClient()) { bstream->read(&mLastClientControlCRC); U32 firstMove; bstream->read(&firstMove); U32 count = bstream->readRangedU32(0, MaxPendingMoves); Move theMove; for(; firstMove < firstMoveIndex && count > 0; firstMove++) { count--; theMove.unpack(bstream); } for(; count > 0; count--) { theMove.unpack(bstream); // process the move, including crediting time to the client // and all that joy. if(controlObject.isValid()) controlObject->processServerMove(&theMove); firstMoveIndex++; } } else { bool controlObjectValid = bstream->readFlag(); mCompressPointsRelative = controlObjectValid; // CRC mismatch... if(bstream->readFlag()) { if(controlObjectValid) { U32 ghostIndex = bstream->readInt(GhostConnection::GhostIdBitSize); controlObject = (GameObject *) resolveGhost(ghostIndex); controlObject->readControlState(bstream); mServerPosition = controlObject->getActualPos(); for(S32 i = 0; i < pendingMoves.size(); i++) controlObject->processClientMove(&pendingMoves[i], true); } else controlObject = NULL; } } Parent::readPacket(bstream); } void ControlObjectConnection::writeCompressedPoint(Point &p, BitStream *stream) { if(!mCompressPointsRelative) { stream->write(p.x); stream->write(p.y); return; } Point delta = p - mServerPosition; S32 dx = S32(delta.x + Game::PlayerHorizScopeDistance); S32 dy = S32(delta.y + Game::PlayerVertScopeDistance); S32 maxx = Game::PlayerHorizScopeDistance * 2; S32 maxy = Game::PlayerVertScopeDistance * 2; if(stream->writeFlag(dx >= 0 && dx <= maxx && dy >= 0 && dy <= maxy)) { stream->writeRangedU32(dx, 0, maxx); stream->writeRangedU32(dy, 0, maxy); } else { stream->write(p.x); stream->write(p.y); } } void ControlObjectConnection::readCompressedPoint(Point &p, BitStream *stream) { if(!mCompressPointsRelative) { stream->read(&p.x); stream->read(&p.y); return; } if(stream->readFlag()) { U32 maxx = Game::PlayerHorizScopeDistance * 2; U32 maxy = Game::PlayerVertScopeDistance * 2; F32 dx = F32(stream->readRangedU32(0, maxx)) - Game::PlayerHorizScopeDistance; F32 dy = F32(stream->readRangedU32(0, maxy)) - Game::PlayerVertScopeDistance; Point delta(dx, dy); p = mServerPosition + delta; } else { stream->read(&p.x); stream->read(&p.y); } } }; --- NEW FILE: controlObjectConnection.h --- //----------------------------------------------------------------------------------- // // Torque Network Library - ZAP example multiplayer vector graphics space game // Copyright (C) 2004 GarageGames.com, Inc. // For more information see http://www.opentnl.org // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation; either version 2 of the License, or // (at your option) any later version. // // For use in products that are not compatible with the terms of the GNU // General Public License, alternative licensing options are available // from GarageGames.com. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // //------------------------------------------------------------------------------------ #ifndef _CONTROLOBJECTCONNECTION_H_ #define _CONTROLOBJECTCONNECTION_H_ #include "tnl.h" #include "tnlGhostConnection.h" #include "point.h" using namespace TNL; namespace Zap { // some angle conversion functions: const F32 radiansToDegreesConversion = 360.0f * FloatInverse2Pi; inline F32 radiansToDegrees(F32 angle) { return angle * radiansToDegreesConversion; } inline F32 radiansToUnit(F32 angle) { return angle * FloatInverse2Pi; } inline F32 unitToRadians(F32 angle) { return angle * Float2Pi; } struct Move { float left; float right; float up; float down; float angle; bool fire; bool boost; bool shield; U32 time; enum { MaxMoveTime = 127, }; Move() { left = right = up = down = angle = 0; boost = shield = fire = false; time = 32; } bool isEqualMove(Move *prev) { return prev->left == left && prev->right == right && prev->up == up && prev->down == down && prev->angle == angle && prev->fire == fire && prev->boost == boost && prev->shield == shield; } void pack(BitStream *stream, Move *prev) { if(!stream->writeFlag(prev && isEqualMove(prev))) { stream->writeFloat(left, 4); stream->writeFloat(right, 4); stream->writeFloat(up, 4); stream->writeFloat(down, 4); U32 writeAngle = U32(radiansToUnit(angle) * 0xFFF); stream->writeInt(writeAngle, 12); stream->writeFlag(fire); stream->writeFlag(boost); stream->writeFlag(shield); } stream->writeRangedU32(time, 0, MaxMoveTime); } void unpack(BitStream *stream) { if(!stream->readFlag()) { left = stream->readFloat(4); right = stream->readFloat(4); up = stream->readFloat(4); down = stream->readFloat(4); angle = unitToRadians(stream->readInt(12) / F32(0xFFF)); fire = stream->readFlag(); boost = stream->readFlag(); shield = stream->readFlag(); } time = stream->readRangedU32(0, MaxMoveTime); } void prepare() { PacketStream stream; pack(&stream, NULL); stream.setBytePosition(0); unpack(&stream); } }; class GameObject; class ControlObjectConnection : public GhostConnection { typedef GhostConnection Parent; // move management enum { MaxPendingMoves = 63, }; Vector<Move> pendingMoves; SafePtr<GameObject> controlObject; U32 mLastClientControlCRC; Point mServerPosition; bool mCompressPointsRelative; U32 firstMoveIndex; U32 highSendIndex[3]; public: ControlObjectConnection(); void setControlObject(GameObject *theObject); GameObject *getControlObject() { return controlObject; } U32 getControlCRC(); void addPendingMove(Move *theMove) { if(pendingMoves.size() < MaxPendingMoves) pendingMoves.push_back(*theMove); } struct GamePacketNotify : public GhostConnection::GhostPacketNotify { U32 firstUnsentMoveIndex; Point lastControlObjectPosition; GamePacketNotify() { firstUnsentMoveIndex = 0; } }; PacketNotify *allocNotify() { return new GamePacketNotify; } void writePacket(BitStream *bstream, PacketNotify *notify); void readPacket(BitStream *bstream); void packetReceived(PacketNotify *notify); void processMoveServer(Move *theMove); bool isDataToTransmit() { return true; } void writeCompressedPoint(Point &p, BitStream *stream); void readCompressedPoint(Point &p, BitStream *stream); }; }; #endif Index: main.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/main.cpp,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** main.cpp 13 May 2004 01:45:52 -0000 1.30 --- main.cpp 14 May 2004 00:33:38 -0000 1.31 *************** *** 321,325 **** else { ! GameConnection *theConnection = new GameConnection(gClientGame); gClientGame->setConnectionToServer(theConnection); --- 321,325 ---- else { ! GameConnection *theConnection = new GameConnection(); gClientGame->setConnectionToServer(theConnection); *************** *** 328,332 **** name = "Playa"; ! theConnection->setPlayerName(name); theConnection->setSimulatedNetParams(gSimulatedPacketLoss, gSimulatedPing); --- 328,332 ---- name = "Playa"; ! theConnection->setClientName(name); theConnection->setSimulatedNetParams(gSimulatedPacketLoss, gSimulatedPing); Index: gameType.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/gameType.cpp,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** gameType.cpp 8 May 2004 22:01:13 -0000 1.22 --- gameType.cpp 14 May 2004 00:33:38 -0000 1.23 *************** *** 283,287 **** fillVector.clear(); ! if(connection->mInCommanderMap && mTeams.size() > 1) { S32 teamId = mClientList[findClientIndexByConnection(connection)].teamId; --- 283,287 ---- fillVector.clear(); ! if(connection->isInCommanderMap() && mTeams.size() > 1) { S32 teamId = mClientList[findClientIndexByConnection(connection)].teamId; *************** *** 328,332 **** { ClientRef cref; ! cref.name = theClient->playerName; cref.clientConnection = theClient; --- 328,332 ---- { ClientRef cref; ! cref.name = theClient->getClientName(); cref.clientConnection = theClient; *************** *** 455,459 **** getGame()->deleteObject(theControlObject, 0); ! s2cRemoveClient(theClient->playerName); } --- 455,459 ---- getGame()->deleteObject(theControlObject, 0); ! s2cRemoveClient(theClient->getClientName()); } *************** *** 520,524 **** RefPtr<NetEvent> theEvent = TNL_RPC_CONSTRUCT_NETEVENT(this, ! s2cDisplayChatMessage, (global, source->playerName, message)); S32 teamId = 0; --- 520,524 ---- RefPtr<NetEvent> theEvent = TNL_RPC_CONSTRUCT_NETEVENT(this, ! s2cDisplayChatMessage, (global, source->getClientName(), message)); S32 teamId = 0; Index: game.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/game.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** game.cpp 11 May 2004 18:26:24 -0000 1.20 --- game.cpp 14 May 2004 00:33:38 -0000 1.21 *************** *** 201,205 **** delete mGameObjects[0]; ! for(GameConnection *walk = GameConnection::gClientList.mNext; walk != &GameConnection::gClientList; walk = walk->mNext) walk->resetGhosting(); --- 201,205 ---- delete mGameObjects[0]; ! for(GameConnection *walk = GameConnection::getClientList(); walk ; walk = walk->getNextClient()) walk->resetGhosting(); *************** *** 215,219 **** Vector<GameConnection *> connectionList; ! for(GameConnection *walk = GameConnection::gClientList.mNext; walk != &GameConnection::gClientList; walk = walk->mNext) connectionList.push_back(walk); --- 215,219 ---- Vector<GameConnection *> connectionList; ! for(GameConnection *walk = GameConnection::getClientList(); walk ; walk = walk->getNextClient()) connectionList.push_back(walk); Index: gameConnection.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/gameConnection.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** gameConnection.cpp 13 May 2004 01:45:52 -0000 1.13 --- gameConnection.cpp 14 May 2004 00:33:38 -0000 1.14 *************** *** 26,30 **** #include "gameConnection.h" ! #include "gameObject.h" #include "UIGame.h" --- 26,30 ---- #include "gameConnection.h" ! #include "game.h" #include "UIGame.h" *************** *** 33,37 **** namespace Zap { - // Global list of clients (if we're a server). GameConnection GameConnection::gClientList; --- 33,36 ---- *************** *** 39,51 **** TNL_IMPLEMENT_NETCONNECTION(GameConnection, NetClassGroupGame, true); ! GameConnection::GameConnection(Game *game) { mNext = mPrev = this; - highSendIndex[0] = 0; - highSendIndex[1] = 0; - highSendIndex[2] = 0; - mLastClientControlCRC = 0; - firstMoveIndex = 1; - theGame = game; setTranslatesStrings(); mInCommanderMap = false; --- 38,44 ---- TNL_IMPLEMENT_NETCONNECTION(GameConnection, NetClassGroupGame, true); ! GameConnection::GameConnection() { mNext = mPrev = this; setTranslatesStrings(); mInCommanderMap = false; *************** *** 62,85 **** } - void GameConnection::setControlObject(GameObject *theObject) - { - if(controlObject.isValid()) - controlObject->setControllingClient(NULL); - - controlObject = theObject; - setScopeObject(theObject); - - if(theObject) - theObject->setControllingClient(this); - } - - void GameConnection::packetReceived(PacketNotify *notify) - { - for(; firstMoveIndex < ((GamePacketNotify *) notify)->firstUnsentMoveIndex; firstMoveIndex++) - pendingMoves.erase(U32(0)); - mServerPosition = ((GamePacketNotify *) notify)->lastControlObjectPosition; - Parent::packetReceived(notify); - } - /// Adds this connection to the doubly linked list of clients. void GameConnection::linkToClientList() --- 55,58 ---- *************** *** 91,268 **** } ! U32 GameConnection::getControlCRC() { ! PacketStream stream; ! GameObject *co = getControlObject(); ! ! if(!co) ! return 0; ! ! stream.writeInt(getGhostIndex(co), GhostConnection::GhostIdBitSize); ! co->writeControlState(&stream); ! stream.zeroToByteBoundary(); ! return stream.calculateCRC(0, stream.getBytePosition()); } ! void GameConnection::writePacket(BitStream *bstream, PacketNotify *notify) { ! if(isConnectionToServer()) ! { ! U32 firstSendIndex = highSendIndex[0]; ! if(firstSendIndex < firstMoveIndex) ! firstSendIndex = firstMoveIndex; ! ! bstream->write(getControlCRC()); ! ! bstream->write(firstSendIndex); ! U32 skipCount = firstSendIndex - firstMoveIndex; ! U32 moveCount = pendingMoves.size() - skipCount; ! ! bstream->writeRangedU32(moveCount, 0, MaxPendingMoves); ! Move dummy; ! Move *lastMove = &dummy; ! for(S32 i = skipCount; i < pendingMoves.size(); i++) ! { ! pendingMoves[i].pack(bstream, lastMove); ! lastMove = &pendingMoves[i]; ! } ! ((GamePacketNotify *) notify)->firstUnsentMoveIndex = firstMoveIndex + pendingMoves.size(); ! if(controlObject.isValid()) ! ((GamePacketNotify *) notify)->lastControlObjectPosition = controlObject->getActualPos(); ! ! highSendIndex[0] = highSendIndex[1]; ! highSendIndex[1] = highSendIndex[2]; ! highSendIndex[2] = ((GamePacketNotify *) notify)->firstUnsentMoveIndex; ! } ! else ! { ! S32 ghostIndex = -1; ! if(controlObject.isValid()) ! { ! ghostIndex = getGhostIndex(controlObject); ! mServerPosition = controlObject->getActualPos(); ! } ! ! // we only compress points relative if we know that the ! // remote side has a copy of the control object already ! mCompressPointsRelative = bstream->writeFlag(ghostIndex != -1); ! ! if(bstream->writeFlag(getControlCRC() != mLastClientControlCRC)) ! { ! if(ghostIndex != -1) ! { ! bstream->writeInt(ghostIndex, GhostConnection::GhostIdBitSize); ! controlObject->writeControlState(bstream); ! } ! } ! } ! Parent::writePacket(bstream, notify); } ! void GameConnection::readPacket(BitStream *bstream) { ! if(isConnectionToClient()) ! { ! bstream->read(&mLastClientControlCRC); ! ! U32 firstMove; ! bstream->read(&firstMove); ! U32 count = bstream->readRangedU32(0, MaxPendingMoves); ! ! Move theMove; ! for(; firstMove < firstMoveIndex && count > 0; firstMove++) ! { ! count--; ! theMove.unpack(bstream); ! } ! for(; count > 0; count--) ! { ! theMove.unpack(bstream); ! // process the move, including crediting time to the client ! // and all that joy. ! if(controlObject.isValid()) ! controlObject->processServerMove(&theMove); ! firstMoveIndex++; ! } ! } ! else ! { ! bool controlObjectValid = bstream->readFlag(); ! ! mCompressPointsRelative = controlObjectValid; ! ! // CRC mismatch... ! if(bstream->readFlag()) ! { ! if(controlObjectValid) ! { ! U32 ghostIndex = bstream->readInt(GhostConnection::GhostIdBitSize); ! controlObject = (GameObject *) resolveGhost(ghostIndex); ! controlObject->readControlState(bstream); ! mServerPosition = controlObject->getActualPos(); ! ! for(S32 i = 0; i < pendingMoves.size(); i++) ! controlObject->processClientMove(&pendingMoves[i], true); ! } ! else ! controlObject = NULL; ! } ! } ! Parent::readPacket(bstream); } ! void GameConnection::writeCompressedPoint(Point &p, BitStream *stream) { ! if(!mCompressPointsRelative) ! { ! stream->write(p.x); ! stream->write(p.y); ! return; ! } ! ! Point delta = p - mServerPosition; ! S32 dx = S32(delta.x + Game::PlayerHorizScopeDistance); ! S32 dy = S32(delta.y + Game::PlayerVertScopeDistance); ! ! U32 maxx = Game::PlayerHorizScopeDistance * 2; ! U32 maxy = Game::PlayerVertScopeDistance * 2; ! ! if(stream->writeFlag(dx >= 0 && dx <= maxx && dy >= 0 && dy <= maxy)) ! { ! stream->writeRangedU32(dx, 0, maxx); ! stream->writeRangedU32(dy, 0, maxy); ! } ! else ! { ! stream->write(p.x); ! stream->write(p.y); ! } } - void GameConnection::readCompressedPoint(Point &p, BitStream *stream) - { - if(!mCompressPointsRelative) - { - stream->read(&p.x); - stream->read(&p.y); - return; - } - if(stream->readFlag()) - { - U32 maxx = Game::PlayerHorizScopeDistance * 2; - U32 maxy = Game::PlayerVertScopeDistance * 2; - S32 dx = S32(stream->readRangedU32(0, maxx)) - Game::PlayerHorizScopeDistance; - S32 dy = S32(stream->readRangedU32(0, maxy)) - Game::PlayerVertScopeDistance; - - Point delta(dx, dy); - p = mServerPosition + delta; - } - else - { - stream->read(&p.x); - stream->read(&p.y); - } - } void GameConnection::writeConnectRequest(BitStream *stream) --- 64,90 ---- } ! GameConnection *GameConnection::getClientList() { ! return gClientList.getNextClient(); } ! GameConnection *GameConnection::getNextClient() { ! if(mNext == &gClientList) ! return NULL; ! return mNext; } ! TNL_IMPLEMENT_RPC(GameConnection, c2sRequestCommanderMap, (), NetClassGroupGameMask, RPCGuaranteedOrdered, RPCDirClientToServer, 1) { ! mInCommanderMap = true; } ! TNL_IMPLEMENT_RPC(GameConnection, c2sReleaseCommanderMap, (), NetClassGroupGameMask, RPCGuaranteedOrdered, RPCDirClientToServer, 1) { ! mInCommanderMap = false; } void GameConnection::writeConnectRequest(BitStream *stream) *************** *** 270,274 **** Parent::writeConnectRequest(stream); ! stream->writeString(playerName.getString()); } --- 92,96 ---- Parent::writeConnectRequest(stream); ! stream->writeString(mClientName.getString()); } *************** *** 294,300 **** checkPlayerName: ! for(GameConnection *walk = gClientList.mNext; walk != &gClientList; walk = walk->mNext) { ! if(!strcmp(walk->playerName.getString(), buf)) { dSprintf(buf + len, 3, ".%d", index); --- 116,122 ---- checkPlayerName: ! for(GameConnection *walk = getClientList(); walk; walk = walk->getNextClient()) { ! if(!strcmp(walk->mClientName.getString(), buf)) { dSprintf(buf + len, 3, ".%d", index); *************** *** 304,308 **** } ! playerName = buf; return true; } --- 126,130 ---- } ! mClientName = buf; return true; } *************** *** 364,376 **** } - TNL_IMPLEMENT_RPC(GameConnection, c2sRequestCommanderMap, (), NetClassGroupGameMask, RPCGuaranteedOrdered, RPCDirClientToServer, 1) - { - mInCommanderMap = true; - } - - TNL_IMPLEMENT_RPC(GameConnection, c2sReleaseCommanderMap, (), NetClassGroupGameMask, RPCGuaranteedOrdered, RPCDirClientToServer, 1) - { - mInCommanderMap = false; - } - }; \ No newline at end of file --- 186,188 ---- Index: ZAP.vcproj =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/ZAP.vcproj,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** ZAP.vcproj 12 May 2004 19:35:11 -0000 1.17 --- ZAP.vcproj 14 May 2004 00:33:37 -0000 1.18 *************** *** 294,297 **** --- 294,303 ---- </Filter> <File + RelativePath=".\controlObjectConnection.cpp"> + </File> + <File + RelativePath=".\controlObjectConnection.h"> + </File> + <File RelativePath=".\game.cpp"> </File> Index: masterConnection.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/masterConnection.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** masterConnection.cpp 13 May 2004 01:45:52 -0000 1.7 --- masterConnection.cpp 14 May 2004 00:33:38 -0000 1.8 *************** *** 157,161 **** Nonce serverNonce(connectionData.getBuffer() + Nonce::NonceSize); ! GameConnection *conn = new GameConnection(gClientGame); const char *name = gNameEntryUserInterface.getText(); if(!name[0]) --- 157,161 ---- Nonce serverNonce(connectionData.getBuffer() + Nonce::NonceSize); ! GameConnection *conn = new GameConnection(); const char *name = gNameEntryUserInterface.getText(); if(!name[0]) *************** *** 163,167 **** conn->setSimulatedNetParams(gSimulatedPacketLoss, gSimulatedPing); ! conn->setPlayerName(name); gClientGame->setConnectionToServer(conn); --- 163,167 ---- conn->setSimulatedNetParams(gSimulatedPacketLoss, gSimulatedPing); ! conn->setClientName(name); gClientGame->setConnectionToServer(conn); Index: gameConnection.h =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/gameConnection.h,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** gameConnection.h 12 May 2004 20:45:17 -0000 1.11 --- gameConnection.h 14 May 2004 00:33:38 -0000 1.12 *************** *** 28,179 **** #define _GAMECONNECTION_H_ ! #include "../tnl/tnl.h" ! #include "../tnl/tnlGhostConnection.h" ! ! #include "point.h" - using namespace TNL; - // some angle conversion functions: namespace Zap { static char *gConnectStatesTable[] = { - //NotConnected, ///< Initial state of a NetConnection instance - not connected. "Not connected...", - //AwaitingChallengeResponse, ///< We've sent a challenge request, awaiting the response. "Sending challenge request.", - //SendingPunchPackets, ///< The state of a pending arranged connection when both sides haven't heard from the other yet "Punching through firewalls.", - //ComputingPuzzleSolution, ///< We've received a challenge response, and are in the process of computing a solution to its puzzle. "Computing puzzle solution.", - //AwaitingConnectResponse, ///< We've received a challenge response and sent a connect request. "Sent connect request.", - //ConnectTimedOut, ///< The connection timed out during the connection process. "Connection timed out.", - //ConnectRejected, ///< The connection was rejected. "Connection rejected.", - //Connected, ///< We've accepted a connect request, or we've received a connect response accept. "Connected.", - //Disconnected, ///< The connection has been disconnected. "Disconnected.", - //TimedOut, ///< The connection timed out. "Connection timed out.", "" }; ! const F32 constantPi = 3.141592f; ! const F32 radiansToDegreesConversion = 360.0f / (2 * constantPi); ! const F32 radiansToUnitConversion = 1 / (2 * constantPi); ! const F32 unitToRadiansConversion = 2 * constantPi; ! ! inline F32 radiansToDegrees(F32 angle) ! { ! return angle * radiansToDegreesConversion; ! } ! ! inline F32 radiansToUnit(F32 angle) ! { ! return angle * radiansToUnitConversion; ! } ! ! inline F32 unitToRadians(F32 angle) ! { ! return angle * unitToRadiansConversion; ! } ! ! struct Move ! { ! float left; ! float right; ! float up; ! float down; ! float angle; ! bool fire; ! bool boost; ! bool shield; ! U32 time; ! ! enum { ! MaxMoveTime = 127, ! }; ! ! Move() { left = right = up = down = angle = 0; boost = shield = fire = false; time = 32; } ! ! bool isEqualMove(Move *prev) ! { ! return prev->left == left && ! prev->right == right && ! prev->up == up && ! prev->down == down && ! prev->angle == angle && ! prev->fire == fire && ! prev->boost == boost && ! prev->shield == shield; ! } ! ! void pack(BitStream *stream, Move *prev) ! { ! if(!stream->writeFlag(prev && isEqualMove(prev))) ! { ! stream->writeFloat(left, 4); ! stream->writeFloat(right, 4); ! stream->writeFloat(up, 4); ! stream->writeFloat(down, 4); ! U32 writeAngle = U32(radiansToUnit(angle) * 0xFFF); ! ! stream->writeInt(writeAngle, 12); ! stream->writeFlag(fire); ! stream->writeFlag(boost); ! stream->writeFlag(shield); ! } ! stream->writeRangedU32(time, 0, MaxMoveTime); ! } ! void unpack(BitStream *stream) ! { ! if(!stream->readFlag()) ! { ! left = stream->readFloat(4); ! right = stream->readFloat(4); ! up = stream->readFloat(4); ! down = stream->readFloat(4); ! angle = unitToRadians(stream->readInt(12) / F32(0xFFF)); ! fire = stream->readFlag(); ! boost = stream->readFlag(); ! shield = stream->readFlag(); ! } ! time = stream->readRangedU32(0, MaxMoveTime); ! } ! void prepare() ! { ! PacketStream stream; ! pack(&stream, NULL); ! stream.setBytePosition(0); ! unpack(&stream); ! } ! }; ! ! class GameObject; ! class Game; ! ! class GameConnection : public GhostConnection { ! typedef GhostConnection Parent; ! public: ! // move management ! enum { ! MaxPendingMoves = 63, ! }; ! Vector<Move> pendingMoves; ! SafePtr<GameObject> controlObject; ! Game *theGame; ! ! bool mInCommanderMap; ! StringTableEntry playerName; ! U32 mLastClientControlCRC; ! Point mServerPosition; ! bool mCompressPointsRelative; ! ! U32 firstMoveIndex; ! U32 highSendIndex[3]; // The server maintains a linked list of clients... --- 28,53 ---- #define _GAMECONNECTION_H_ ! #include "controlObjectConnection.h" namespace Zap { static char *gConnectStatesTable[] = { "Not connected...", "Sending challenge request.", "Punching through firewalls.", "Computing puzzle solution.", "Sent connect request.", "Connection timed out.", "Connection rejected.", "Connected.", "Disconnected.", "Connection timed out.", "" }; ! class GameConnection : public ControlObjectConnection { ! typedef ControlObjectConnection Parent; // The server maintains a linked list of clients... *************** *** 182,237 **** static GameConnection gClientList; ! GameConnection(Game *game = NULL); ! ~GameConnection(); ! ! void setPlayerName(const char *string) { playerName = string; } ! void setControlObject(GameObject *theObject); ! ! GameObject *getControlObject() { return controlObject; } ! U32 getControlCRC(); void linkToClientList(); ! void addPendingMove(Move *theMove) ! { ! if(pendingMoves.size() < MaxPendingMoves) ! pendingMoves.push_back(*theMove); ! } ! ! struct GamePacketNotify : public GhostConnection::GhostPacketNotify ! { ! U32 firstUnsentMoveIndex; ! Point lastControlObjectPosition; ! GamePacketNotify() { firstUnsentMoveIndex = 0; } ! }; ! PacketNotify *allocNotify() { return new GamePacketNotify; } ! void writePacket(BitStream *bstream, PacketNotify *notify); ! void readPacket(BitStream *bstream); ! void packetReceived(PacketNotify *notify); ! void processMoveServer(Move *theMove); void writeConnectRequest(BitStream *stream); bool readConnectRequest(BitStream *stream, const char **errorString); - /// Adds this connection to the doubly linked list of clients. void onConnectionEstablished(bool isInitiator); - void onConnectionRejected(const char *reason); void onDisconnect(const char *reason); void onTimedOut(); - void onConnectionTerminated(const char *reason); - - void writeCompressedPoint(Point &p, BitStream *stream); - void readCompressedPoint(Point &p, BitStream *stream); - void onConnectTimedOut(); ! bool isDataToTransmit() { return true; } TNL_DECLARE_NETCONNECTION(GameConnection); - TNL_DECLARE_RPC(c2sRequestCommanderMap, ()); - TNL_DECLARE_RPC(c2sReleaseCommanderMap, ()); }; --- 56,90 ---- static GameConnection gClientList; ! bool mInCommanderMap; ! StringTableEntry mClientName; void linkToClientList(); + public: + GameConnection(); + ~GameConnection(); ! void setClientName(const char *string) { mClientName = string; } ! StringTableEntryRef getClientName() { return mClientName; } ! bool isInCommanderMap() { return mInCommanderMap; } ! TNL_DECLARE_RPC(c2sRequestCommanderMap, ()); ! TNL_DECLARE_RPC(c2sReleaseCommanderMap, ()); ! static GameConnection *getClientList(); ! GameConnection *getNextClient(); void writeConnectRequest(BitStream *stream); bool readConnectRequest(BitStream *stream, const char **errorString); void onConnectionEstablished(bool isInitiator); void onConnectionRejected(const char *reason); + void onDisconnect(const char *reason); void onTimedOut(); void onConnectTimedOut(); ! void onConnectionTerminated(const char *reason); TNL_DECLARE_NETCONNECTION(GameConnection); }; Index: ship.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/ship.cpp,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -d -r1.28 -r1.29 *** ship.cpp 12 May 2004 21:08:25 -0000 1.28 --- ship.cpp 14 May 2004 00:33:38 -0000 1.29 *************** *** 442,446 **** bool shouldWritePosition = (updateMask & InitialMask) || ! gameConnection->controlObject != (GameObject *) this; if(!shouldWritePosition) --- 442,446 ---- bool shouldWritePosition = (updateMask & InitialMask) || ! gameConnection->getControlObject() != this; if(!shouldWritePosition) |
From: Mark F. <mar...@us...> - 2004-05-13 23:03:12
|
Update of /cvsroot/opentnl/tnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4573/tnl Modified Files: netObject.cpp rpc.cpp tnlNetObject.h tnlRPC.h Log Message: Fixed holes in RPCs so they cannot be delivered to instances of the wrong class. Index: tnlRPC.h =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/tnlRPC.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** tnlRPC.h 6 May 2004 00:33:38 -0000 1.5 --- tnlRPC.h 13 May 2004 23:03:03 -0000 1.6 *************** *** 164,169 **** void process(EventConnection *ps); ! /// Returns the "this" pointer that the remote method should be called on ! virtual void *getThisPointer(EventConnection *ps) { return (void *) ps; } }; --- 164,169 ---- void process(EventConnection *ps); ! /// Returns true if this RPC is being sent to an object of the appropriate class. ! virtual bool checkClassType(Object *theObject) = NULL; }; *************** *** 197,200 **** --- 197,201 ---- { mFuncPtr = &className::name##_remote; } \ TNL_DECLARE_CLASS( RPC_##className##_##name ); \ + bool checkClassType(TNL::Object *theObject) { return dynamic_cast<className *>(theObject) != NULL; } \ void getFuncPtr(MethodPointer &m) { m.v1=*((U32 *) &mFuncPtr); m.v2 = *(((U32 *) &mFuncPtr) + 1); } }; \ TNL_IMPLEMENT_NETEVENT( RPC_##className##_##name, groupMask, rpcVersion ); \ Index: rpc.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/rpc.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** rpc.cpp 6 May 2004 00:33:38 -0000 1.2 --- rpc.cpp 13 May 2004 23:03:03 -0000 1.3 *************** *** 62,68 **** void RPCEvent::process(EventConnection *ps) { MethodPointer p; getFuncPtr(p); ! mCall.dispatch(getThisPointer(ps), &p); } --- 62,71 ---- void RPCEvent::process(EventConnection *ps) { + if(!checkClassType(ps)) + return; + MethodPointer p; getFuncPtr(p); ! mCall.dispatch(ps, &p); } Index: netObject.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/netObject.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** netObject.cpp 20 Apr 2004 04:27:18 -0000 1.1 --- netObject.cpp 13 May 2004 23:03:03 -0000 1.2 *************** *** 327,332 **** if(mDestObject.isNull()) return; NetObject::mRPCSourceConnection = (GhostConnection *) ps; ! RPCEvent::process(ps); NetObject::mRPCSourceConnection = NULL; } --- 327,340 ---- if(mDestObject.isNull()) return; + + if(!checkClassType(mDestObject)) + return; + + void *thisPointer = (void *) mDestObject.getPointer(); + NetObject::mRPCSourceConnection = (GhostConnection *) ps; ! MethodPointer p; ! getFuncPtr(p); ! mCall.dispatch(thisPointer, &p); NetObject::mRPCSourceConnection = NULL; } Index: tnlNetObject.h =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/tnlNetObject.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** tnlNetObject.h 6 May 2004 00:33:38 -0000 1.2 --- tnlNetObject.h 13 May 2004 23:03:03 -0000 1.3 *************** *** 425,429 **** void unpack(EventConnection *ps, BitStream *bstream); void process(EventConnection *ps); - void *getThisPointer(EventConnection *ps) { return (void *) mDestObject.getPointer(); } }; --- 425,428 ---- *************** *** 442,445 **** --- 441,445 ---- { mFuncPtr = &className::name##_remote; } \ TNL_DECLARE_CLASS( RPCEV_##className##_##name ); \ + bool checkClassType(TNL::Object *theObject) { return dynamic_cast<className *>(theObject) != NULL; } \ void getFuncPtr(MethodPointer &p) { p.v1=*((U32 *) &mFuncPtr); p.v2 = *(((U32 *) &mFuncPtr) + 1); } }; \ TNL_IMPLEMENT_NETEVENT( RPCEV_##className##_##name, groupMask, rpcVersion ); \ |
From: Mark F. <mar...@us...> - 2004-05-13 21:30:04
|
Update of /cvsroot/opentnl/tnl/zap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18777/zap Modified Files: game.h Log Message: Upped game version Index: game.h =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/game.h,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** game.h 12 May 2004 20:45:16 -0000 1.20 --- game.h 13 May 2004 21:29:56 -0000 1.21 *************** *** 212,216 **** extern void endGame(); ! #define ZAP_GAME_STRING "ZAP 1.2.0 rc 5" }; --- 212,216 ---- extern void endGame(); ! #define ZAP_GAME_STRING "ZAP 1.2.0 rc 6" }; |
From: Mark F. <mar...@us...> - 2004-05-13 19:21:59
|
Update of /cvsroot/opentnl/tnl/tnl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21928/tnl Modified Files: huffmanStringProcessor.cpp tnlVector.h Log Message: Made some fixes to Vector class updated barrier code to not break on vector resize updated levels 3 and 4 to remove duplicate barrier makers Index: tnlVector.h =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/tnlVector.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** tnlVector.h 6 May 2004 01:36:01 -0000 1.3 --- tnlVector.h 13 May 2004 19:21:49 -0000 1.4 *************** *** 43,63 **** //----------------------------------------------------------------------------- - #ifdef DEBUG_GUARD - extern bool VectorResize(U32 *aSize, U32 *aCount, void **arrayPtr, U32 newCount, U32 elemSize, - const char* fileName, - const U32 lineNum); - #else - extern bool VectorResize(U32 *aSize, U32 *aCount, void **arrayPtr, U32 newCount, U32 elemSize); - #endif - - - // Use the following macro to bind a vector to a particular line - // of the owning class for memory tracking purposes - #ifdef DEBUG_GUARD - #define VECTOR_SET_ASSOCIATION(x) x.setFileAssociation(__FILE__, __LINE__) - #else - #define VECTOR_SET_ASSOCIATION(x) - #endif - /// VectorRep is an image of a Vector template object that is used /// for marshalling and unmarshalling Vectors across RPCs. --- 43,46 ---- *************** *** 67,74 **** U32 arraySize; U8 *array; - #ifdef DEBUG_GUARD - const char *fileAssociation; - U32 lineAssociation; - #endif }; --- 50,53 ---- *************** *** 88,97 **** T* mArray; ///< Pointer to the Vector elements. ! #ifdef DEBUG_GUARD ! const char* mFileAssociation; ! U32 mLineAssociation; ! #endif ! ! bool resize(U32); ///< Resizes, but does no construction/destruction. void destroy(U32 start, U32 end); ///< Destructs elements from <i>start</i> to <i>end-1</i> void construct(U32 start, U32 end); ///< Constructs elements from <i>start</i> to <i>end-1</i> --- 67,71 ---- T* mArray; ///< Pointer to the Vector elements. ! void checkSize(U32 newElementCount);///< checks the element count against the array size and resizes the array if necessary void destroy(U32 start, U32 end); ///< Destructs elements from <i>start</i> to <i>end-1</i> void construct(U32 start, U32 end); ///< Constructs elements from <i>start</i> to <i>end-1</i> *************** *** 99,111 **** public: Vector(const U32 initialSize = 0); - Vector(const U32 initialSize, const char* fileName, const U32 lineNum); - Vector(const char* fileName, const U32 lineNum); Vector(const Vector&); ~Vector(); - #ifdef DEBUG_GUARD - void setFileAssociation(const char* file, const U32 line); - #endif - /// @name VectorSTL STL interface /// --- 73,79 ---- *************** *** 117,122 **** typedef const T& const_reference; - typedef T* iterator; - typedef const T* const_iterator; typedef S32 difference_type; typedef U32 size_type; --- 85,88 ---- *************** *** 126,140 **** Vector<T>& operator=(const Vector<T>& p); - iterator begin(); - const_iterator begin() const; - iterator end(); - const_iterator end() const; - S32 size() const; bool empty() const; - void insert(iterator, const T&); - void erase(iterator); - T& front(); const T& front() const; --- 92,98 ---- *************** *** 154,158 **** void reserve(U32); - U32 capacity() const; /// @} --- 112,115 ---- *************** *** 166,177 **** T* address() const; U32 setSize(U32); - void increment(); - void decrement(); - void increment(U32); - void decrement(U32); void insert(U32); void erase(U32); void erase_fast(U32); - void erase_fast(iterator); void clear(); void compact(); --- 123,129 ---- *************** *** 196,204 **** template<class T> inline Vector<T>::Vector(const U32 initialSize) { - #ifdef DEBUG_GUARD - mFileAssociation = NULL; - mLineAssociation = 0; - #endif - mArray = 0; mElementCount = 0; --- 148,151 ---- *************** *** 208,270 **** } - template<class T> inline Vector<T>::Vector(const U32 initialSize, - const char* fileName, - const U32 lineNum) - { - #ifdef DEBUG_GUARD - mFileAssociation = fileName; - mLineAssociation = lineNum; - #else - fileName; - lineNum; - #endif - - mArray = 0; - mElementCount = 0; - mArraySize = 0; - if(initialSize) - reserve(initialSize); - } - - template<class T> inline Vector<T>::Vector(const char* fileName, - const U32 lineNum) - { - #ifdef DEBUG_GUARD - mFileAssociation = fileName; - mLineAssociation = lineNum; - #else - fileName; - lineNum; - #endif - - mArray = 0; - mElementCount = 0; - mArraySize = 0; - } - template<class T> inline Vector<T>::Vector(const Vector& p) { - #ifdef DEBUG_GUARD - mFileAssociation = p.mFileAssociation; - mLineAssociation = p.mLineAssociation; - #endif - mArray = 0; ! resize(p.mElementCount); construct(0, p.mElementCount, p.mArray); - //if (p.mElementCount) - // memcpy(mArray,p.mArray,mElementCount * sizeof(value_type)); } - #ifdef DEBUG_GUARD - template<class T> inline void Vector<T>::setFileAssociation(const char* file, - const U32 line) - { - mFileAssociation = file; - mLineAssociation = line; - } - #endif - template<class T> inline void Vector<T>::destroy(U32 start, U32 end) // destroys from start to end-1 { --- 155,170 ---- } template<class T> inline Vector<T>::Vector(const Vector& p) { mArray = 0; ! mArraySize = 0; ! mElementCount = 0; ! ! checkSize(p.mElementCount); ! mElementCount = p.mElementCount; construct(0, p.mElementCount, p.mArray); } template<class T> inline void Vector<T>::destroy(U32 start, U32 end) // destroys from start to end-1 { *************** *** 288,296 **** } - template<class T> inline U32 Vector<T>::memSize() const - { - return capacity() * sizeof(T); - } - template<class T> inline T* Vector<T>::address() const { --- 188,191 ---- *************** *** 300,369 **** template<class T> inline U32 Vector<T>::setSize(U32 size) { ! U32 oldSize = mElementCount; if(size > mElementCount) { ! if (size > mArraySize) ! resize(size); ! construct(oldSize, size); } else if(size < mElementCount) - destroy(size, oldSize); - mElementCount = size; - - if(!mElementCount) { ! free(mArray); ! mArray = NULL; ! mArraySize = 0; } return mElementCount; } - template<class T> inline void Vector<T>::increment() - { - if(mElementCount == mArraySize) - resize(mElementCount + 1); - else - mElementCount++; - constructInPlace(&mArray[mElementCount - 1]); - } - - template<class T> inline void Vector<T>::decrement() - { - mElementCount--; - destructInPlace(&mArray[mElementCount]); - } - - template<class T> inline void Vector<T>::increment(U32 delta) - { - U32 count = mElementCount; - if ((mElementCount += delta) > mArraySize) - resize(mElementCount); - construct(count, mElementCount); - } - - template<class T> inline void Vector<T>::decrement(U32 delta) - { - U32 count = mElementCount; - if (mElementCount > delta) - mElementCount -= delta; - else - mElementCount = 0; - destroy(mElementCount, count); - } - template<class T> inline void Vector<T>::insert(U32 index) { ! // Assert: index >= 0 && index < mElementCount ! if(mElementCount == mArraySize) ! resize(mElementCount + 1); ! else ! mElementCount++; for(U32 i = mElementCount - 1; i > index; i--) mArray[i] = mArray[i - 1]; destructInPlace(&mArray[index]); - //memmove(&mArray[index + 1], - // &mArray[index], - // (mElementCount - index - 1) * sizeof(value_type)); constructInPlace(&mArray[index]); } --- 195,227 ---- template<class T> inline U32 Vector<T>::setSize(U32 size) { ! checkSize(size); ! if(size > mElementCount) { ! construct(mElementCount, size); ! mElementCount = size; } else if(size < mElementCount) { ! destroy(size, mElementCount); ! mElementCount = size; ! if(!mElementCount) ! { ! free(mArray); ! mArray = NULL; ! mArraySize = 0; ! } } return mElementCount; } template<class T> inline void Vector<T>::insert(U32 index) { ! checkSize(mElementCount + 1); ! mElementCount++; ! for(U32 i = mElementCount - 1; i > index; i--) mArray[i] = mArray[i - 1]; destructInPlace(&mArray[index]); constructInPlace(&mArray[index]); } *************** *** 375,381 **** mArray[i] = mArray[i+1]; destructInPlace(&mArray[mElementCount - 1]); - //memmove(&mArray[index], - // &mArray[index + 1], - // (mElementCount - index - 1) * sizeof(value_type)); mElementCount--; } --- 233,236 ---- *************** *** 387,398 **** // size of the vector. // Assert: index >= 0 && index < mElementCount if(index != mElementCount - 1) mArray[index] = mArray[mElementCount - 1]; destructInPlace(&mArray[mElementCount - 1]); mElementCount--; - - //if (index < (mElementCount - 1)) - // memmove(&mArray[index], &mArray[mElementCount - 1], sizeof(value_type)); - //mElementCount--; } --- 242,250 ---- // size of the vector. // Assert: index >= 0 && index < mElementCount + if(index != mElementCount - 1) mArray[index] = mArray[mElementCount - 1]; destructInPlace(&mArray[mElementCount - 1]); mElementCount--; } *************** *** 423,467 **** } - template<class T> inline void Vector<T>::compact() - { - resize(mElementCount); - } - - //----------------------------------------------------------------------------- template<class T> inline Vector<T>& Vector<T>::operator=(const Vector<T>& p) { ! if(mElementCount > p.mElementCount) ! destroy(p.mElementCount, mElementCount); ! U32 i; ! for(i = 0; i < mElementCount; i++) ! mArray[i] = p.mArray[i]; ! resize(p.mElementCount); ! if(i < p.mElementCount) ! construct(i, p.mElementCount, p.mArray); return *this; } - template<class T> inline typename Vector<T>::iterator Vector<T>::begin() - { - return mArray; - } - - template<class T> inline typename Vector<T>::const_iterator Vector<T>::begin() const - { - return mArray; - } - - template<class T> inline typename Vector<T>::iterator Vector<T>::end() - { - return mArray + mElementCount; - } - - template<class T> inline typename Vector<T>::const_iterator Vector<T>::end() const - { - return mArray +mElementCount; - } - template<class T> inline S32 Vector<T>::size() const { --- 275,290 ---- } //----------------------------------------------------------------------------- template<class T> inline Vector<T>& Vector<T>::operator=(const Vector<T>& p) { ! destroy(0, mElementCount); ! mElementCount = 0; ! checkSize(p.mElementCount); ! construct(0, p.mElementCount, p.mArray); ! mElementCount = p.mElementCount; return *this; } template<class T> inline S32 Vector<T>::size() const { *************** *** 474,494 **** } - template<class T> inline void Vector<T>::insert(iterator p,const T& x) - { - U32 index = (U32) (p - mArray); - insert(index); - mArray[index] = x; - } - - template<class T> inline void Vector<T>::erase(iterator q) - { - erase(U32(q - mArray)); - } - - template<class T> inline void Vector<T>::erase_fast(iterator q) - { - erase_fast(U32(q - mArray)); - } - template<class T> inline T& Vector<T>::front() { --- 297,300 ---- *************** *** 511,515 **** } ! template<class T> inline void Vector<T>::push_front(const T& x) { insert(0); --- 317,321 ---- } ! template<class T> inline void Vector<T>::push_front(const T &x) { insert(0); *************** *** 517,524 **** } ! template<class T> inline void Vector<T>::push_back(const T& x) { ! increment(); ! mArray[mElementCount - 1] = x; } --- 323,331 ---- } ! template<class T> inline void Vector<T>::push_back(const T &x) { ! checkSize(mElementCount + 1); ! mElementCount++; ! constructInPlace(mArray + mElementCount - 1, &x); } *************** *** 530,534 **** template<class T> inline void Vector<T>::pop_back() { ! decrement(); } --- 337,342 ---- template<class T> inline void Vector<T>::pop_back() { ! mElementCount--; ! destructInPlace(mArray + mElementCount); } *************** *** 545,586 **** template<class T> inline void Vector<T>::reserve(U32 size) { ! if (size > mArraySize) { ! U32 ec = mElementCount; ! if (resize(size)) ! mElementCount = ec; ! } ! } ! ! template<class T> inline U32 Vector<T>::capacity() const ! { ! return mArraySize; } ! template<class T> inline void Vector<T>::set(void * addr, U32 sz) ! { ! setSize(sz); ! if (addr) ! memcpy(address(),addr,sz*sizeof(T)); ! } //----------------------------------------------------------------------------- ! template<class T> inline bool Vector<T>::resize(U32 ecount) { ! U32 blk = VectorBlockSize - (ecount % VectorBlockSize); ! U32 newCount = ecount + ((blk != VectorBlockSize) ? blk : 0); ! T *array = (T *) malloc(sizeof(T) * newCount); ! ! for(U32 i = 0; i < mElementCount; i++) ! { ! constructInPlace(&array[i], &mArray[i]); ! destructInPlace(&mArray[i]); ! } ! free(mArray); ! mArray = array; mArraySize = newCount; - mElementCount = ecount; - return true; } --- 353,386 ---- template<class T> inline void Vector<T>::reserve(U32 size) { ! checkSize(size); } ! //template<class T> inline void Vector<T>::set(void * addr, U32 sz) ! //{ ! // setSize(sz); ! // if (addr) ! // memcpy(address(),addr,sz*sizeof(T)); ! //} //----------------------------------------------------------------------------- ! template<class T> inline void Vector<T>::checkSize(U32 newCount) { ! if(newCount <= mArraySize) ! return; ! U32 blk = VectorBlockSize - (newCount % VectorBlockSize); ! newCount += blk; ! ! T *newArray = (T *) malloc(sizeof(T) * newCount); ! T *oldArray = mArray; ! ! mArray = newArray; ! construct(0, mElementCount, oldArray); ! mArray = oldArray; ! destroy(0, mElementCount); ! free(oldArray); ! mArray = newArray; mArraySize = newCount; } Index: huffmanStringProcessor.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/tnl/huffmanStringProcessor.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** huffmanStringProcessor.cpp 20 Apr 2004 04:27:18 -0000 1.1 --- huffmanStringProcessor.cpp 13 May 2004 19:21:49 -0000 1.2 *************** *** 91,95 **** mHuffLeaves.setSize(256); mHuffNodes.reserve(256); ! mHuffNodes.increment(); for (i = 0; i < 256; i++) { HuffLeaf& rLeaf = mHuffLeaves[i]; --- 91,95 ---- mHuffLeaves.setSize(256); mHuffNodes.reserve(256); ! mHuffNodes.setSize(mHuffNodes.size() + 1); for (i = 0; i < 256; i++) { HuffLeaf& rLeaf = mHuffLeaves[i]; *************** *** 127,131 **** // Create a node for this... ! mHuffNodes.increment(); HuffNode& rNode = mHuffNodes.last(); rNode.pop = pWrap[index1].getPop() + pWrap[index2].getPop(); --- 127,131 ---- // Create a node for this... ! mHuffNodes.setSize(mHuffNodes.size() + 1); HuffNode& rNode = mHuffNodes.last(); rNode.pop = pWrap[index1].getPop() + pWrap[index2].getPop(); |
From: Mark F. <mar...@us...> - 2004-05-13 19:21:59
|
Update of /cvsroot/opentnl/tnl/zap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21928/zap Modified Files: barrier.cpp Log Message: Made some fixes to Vector class updated barrier code to not break on vector resize updated levels 3 and 4 to remove duplicate barrier makers Index: barrier.cpp =================================================================== RCS file: /cvsroot/opentnl/tnl/zap/barrier.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** barrier.cpp 30 Apr 2004 20:27:41 -0000 1.6 --- barrier.cpp 13 May 2004 19:21:49 -0000 1.7 *************** *** 85,88 **** --- 85,90 ---- { F32 extendAmt = Barrier::BarrierWidth * 0.5 * tan( acos(cosTheta) / 2 ); + if(extendAmt > 0.01) + extendAmt -= 0.01; extend.push_back(extendAmt); } *************** *** 91,95 **** lastEdge = curEdge; } ! extend.push_back(extend[0]); for(S32 i = 0; i < edgeVector.size(); i++) --- 93,98 ---- lastEdge = curEdge; } ! F32 first = extend[0]; ! extend.push_back(first); for(S32 i = 0; i < edgeVector.size(); i++) *************** *** 167,171 **** --- 170,176 ---- void Barrier::clipRenderLinesToPoly(Vector<Point> &polyPoints) { + //return; Vector<Point> clippedSegments; + for(S32 i = 0; i < mRenderLineSegments.size(); i+= 2) *************** *** 174,189 **** Point rp2 = mRenderLineSegments[i + 1]; - /* Point cp1 = polyPoints[polyPoints.size() - 1]; - for(S32 j = 0; j < polyPoints.size(); j++) - { - Point cp2 = polyPoints[j]; - Point ce = cp2 - cp1; - - // If we're collinear, just don't clip - - cp1 = cp2; - } */ - - Point cp1 = polyPoints[polyPoints.size() - 1]; for(S32 j = 0; j < polyPoints.size(); j++) --- 179,182 ---- *************** *** 199,216 **** F32 d2 = n.dot(rp2); ! bool d1in = d1 > distToZero; ! bool d2in = d2 > distToZero; ! ! // collinearity check ! Point a = ce; ! Point b = rp2-rp1; ! a.normalize(); ! b.normalize(); ! F32 v = a.dot(b); ! ! // And locality check ! F32 lc = getMin( getMin( (cp1 - rp1).len(), (cp1 - rp2).len() ), getMin( (cp2 - rp1).len(), (cp2 - rp2).len() )); ! if(!d1in && !d2in || (v >= 1.f && lc < 0.1)) // both points are outside this edge of the poly, so... { // add them to the render poly --- 192,199 ---- F32 d2 = n.dot(rp2); ! bool d1in = d1 >= distToZero; ! bool d2in = d2 >= distToZero; ! if(!d1in && !d2in) // both points are outside this edge of the poly, so... { // add them to the render poly |