NETWORK - Modified the protocol creation structure

This commit is contained in:
dean11 2013-12-09 14:23:30 +01:00
parent cb8fee9227
commit 5473c5160f
5 changed files with 190 additions and 395 deletions

View File

@ -23,13 +23,26 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OysterNetworkServer", "Netw
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "NetworkDependencies", "Network\NetworkDependencies\NetworkDependencies.vcxproj", "{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GameLogic", "GameLogic\GameLogic.vcxproj", "{B1195BB9-B3A5-47F0-906C-8DEA384D1520}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GamePhysics", "GamePhysics\GamePhysics.vcxproj", "{104FA3E9-94D9-4E1D-A941-28A03BC8A095}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Tester", "Tester\Tester.vcxproj", "{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DanBiasGame", "DanBiasGame\DanBiasGame.vcxproj", "{2A1BC987-AF42-4500-802D-89CD32FC1309}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DanBiasGame", "Game\DanBiasGame\DanBiasGame.vcxproj", "{2A1BC987-AF42-4500-802D-89CD32FC1309}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Game", "Game", "{20720CA7-795C-45AD-A302-9383A6DD503A}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GameLogic", "Game\GameLogic\GameLogic.vcxproj", "{B1195BB9-B3A5-47F0-906C-8DEA384D1520}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DanBiasServer", "Game\DanBiasServer\DanBiasServer.vcxproj", "{52380DAA-0F4A-4D97-8E57-98DF39319CAF}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DanBiasLauncher", "Game\DanBiasLauncher\DanBiasLauncher.vcxproj", "{8690FDDF-C5B7-4C42-A337-BD5243F29B85}"
ProjectSection(ProjectDependencies) = postProject
{52380DAA-0F4A-4D97-8E57-98DF39319CAF} = {52380DAA-0F4A-4D97-8E57-98DF39319CAF}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "NetworkAPI", "Network\NetworkAPI\NetworkAPI.vcxproj", "{460D625F-2AC9-4559-B809-0BA89CEAEDF4}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GameProtocols", "Game\GameProtocols\GameProtocols.vcxproj", "{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@ -41,162 +54,137 @@ Global
Release|x64 = Release|x64
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|Mixed Platforms.Build.0 = Release|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|Win32.ActiveCfg = Debug|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|Win32.Build.0 = Debug|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|x64.ActiveCfg = Debug|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Debug|x64.Build.0 = Debug|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|Mixed Platforms.Build.0 = Release|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|Mixed Platforms.ActiveCfg = Release|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|Mixed Platforms.Build.0 = Release|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|Win32.ActiveCfg = Release|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|Win32.Build.0 = Release|Win32
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|x64.ActiveCfg = Release|x64
{0EC83E64-230E-48EF-B08C-6AC9651B4F82}.Release|x64.Build.0 = Release|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|Mixed Platforms.Build.0 = Release|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|Win32.ActiveCfg = Debug|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|Win32.Build.0 = Debug|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|x64.ActiveCfg = Debug|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Debug|x64.Build.0 = Debug|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|Mixed Platforms.Build.0 = Release|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|Mixed Platforms.ActiveCfg = Release|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|Mixed Platforms.Build.0 = Release|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|Win32.ActiveCfg = Release|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|Win32.Build.0 = Release|Win32
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|x64.ActiveCfg = Release|x64
{F10CBC03-9809-4CBA-95D8-327C287B18EE}.Release|x64.Build.0 = Release|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|Mixed Platforms.Build.0 = Release|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|Win32.ActiveCfg = Debug|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|Win32.Build.0 = Debug|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|x64.ActiveCfg = Debug|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Debug|x64.Build.0 = Debug|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|Mixed Platforms.Build.0 = Release|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|Mixed Platforms.ActiveCfg = Release|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|Mixed Platforms.Build.0 = Release|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|Win32.ActiveCfg = Release|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|Win32.Build.0 = Release|Win32
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|x64.ActiveCfg = Release|x64
{4285BD3F-3C6C-4670-B7AF-A29AFEF5F6A8}.Release|x64.Build.0 = Release|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|Mixed Platforms.Build.0 = Release|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|Win32.ActiveCfg = Debug|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|Win32.Build.0 = Debug|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|x64.ActiveCfg = Debug|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Debug|x64.Build.0 = Debug|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|Mixed Platforms.Build.0 = Release|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|Mixed Platforms.ActiveCfg = Release|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|Mixed Platforms.Build.0 = Release|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|Win32.ActiveCfg = Release|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|Win32.Build.0 = Release|Win32
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|x64.ActiveCfg = Release|x64
{34D6295A-00DD-4B1A-8258-97DA2818EC26}.Release|x64.Build.0 = Release|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|Mixed Platforms.Build.0 = Release|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|Win32.ActiveCfg = Debug|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|Win32.Build.0 = Debug|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|x64.ActiveCfg = Debug|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Debug|x64.Build.0 = Debug|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|Mixed Platforms.Build.0 = Release|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|Mixed Platforms.ActiveCfg = Release|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|Mixed Platforms.Build.0 = Release|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|Win32.ActiveCfg = Release|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|Win32.Build.0 = Release|Win32
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|x64.ActiveCfg = Release|x64
{35AEA3C0-E0A7-4E1E-88CD-514AA5A442B1}.Release|x64.Build.0 = Release|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|Mixed Platforms.Build.0 = Release|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|Win32.ActiveCfg = Debug|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|Win32.Build.0 = Debug|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|x64.ActiveCfg = Debug|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Debug|x64.Build.0 = Debug|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|Mixed Platforms.Build.0 = Release|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|Mixed Platforms.ActiveCfg = Release|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|Mixed Platforms.Build.0 = Release|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|Win32.ActiveCfg = Release|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|Win32.Build.0 = Release|Win32
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|x64.ActiveCfg = Release|x64
{7E3990D2-3D94-465C-B58D-64A74B3ECF9B}.Release|x64.Build.0 = Release|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|Mixed Platforms.Build.0 = Release|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|Win32.ActiveCfg = Debug|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|Win32.Build.0 = Debug|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|x64.ActiveCfg = Debug|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Debug|x64.Build.0 = Debug|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|Mixed Platforms.Build.0 = Release|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|Mixed Platforms.ActiveCfg = Release|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|Mixed Platforms.Build.0 = Release|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|Win32.ActiveCfg = Release|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|Win32.Build.0 = Release|Win32
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|x64.ActiveCfg = Release|x64
{2EC4DDED-8F75-4C86-A10B-E1E8EB29F3EE}.Release|x64.Build.0 = Release|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|Mixed Platforms.Build.0 = Release|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|Win32.ActiveCfg = Debug|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|Win32.Build.0 = Debug|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|x64.ActiveCfg = Debug|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Debug|x64.Build.0 = Debug|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|Mixed Platforms.Build.0 = Release|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|Mixed Platforms.ActiveCfg = Release|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|Mixed Platforms.Build.0 = Release|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|Win32.ActiveCfg = Release|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|Win32.Build.0 = Release|Win32
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|x64.ActiveCfg = Release|x64
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8}.Release|x64.Build.0 = Release|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|Mixed Platforms.Build.0 = Release|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|Win32.ActiveCfg = Debug|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|Win32.Build.0 = Debug|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|x64.ActiveCfg = Debug|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Debug|x64.Build.0 = Debug|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|Mixed Platforms.Build.0 = Release|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|Mixed Platforms.ActiveCfg = Release|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|Mixed Platforms.Build.0 = Release|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|Win32.ActiveCfg = Release|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|Win32.Build.0 = Release|Win32
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|x64.ActiveCfg = Release|x64
{6A066806-F43F-4B31-A4E3-57179674F460}.Release|x64.Build.0 = Release|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|Mixed Platforms.ActiveCfg = Release|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|Mixed Platforms.Build.0 = Release|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|Win32.ActiveCfg = Debug|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|Win32.Build.0 = Debug|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|x64.ActiveCfg = Debug|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Debug|x64.Build.0 = Debug|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|Mixed Platforms.Build.0 = Release|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|Mixed Platforms.ActiveCfg = Release|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|Mixed Platforms.Build.0 = Release|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|Win32.ActiveCfg = Release|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|Win32.Build.0 = Release|Win32
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|x64.ActiveCfg = Release|x64
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50}.Release|x64.Build.0 = Release|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Win32.ActiveCfg = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Win32.Build.0 = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|x64.ActiveCfg = Debug|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|x64.Build.0 = Debug|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Mixed Platforms.Build.0 = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Win32.ActiveCfg = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Win32.Build.0 = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|x64.ActiveCfg = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|Mixed Platforms.ActiveCfg = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|Mixed Platforms.Build.0 = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|Win32.ActiveCfg = Debug|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|Win32.Build.0 = Debug|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|x64.ActiveCfg = Debug|x64
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Debug|x64.Build.0 = Debug|x64
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|Mixed Platforms.Build.0 = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|Win32.ActiveCfg = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|Win32.Build.0 = Release|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|x64.ActiveCfg = Release|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|x64.ActiveCfg = Release|x64
{104FA3E9-94D9-4E1D-A941-28A03BC8A095}.Release|x64.Build.0 = Release|x64
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|Mixed Platforms.ActiveCfg = Release|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|Win32.ActiveCfg = Debug|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|Win32.Build.0 = Debug|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|x64.ActiveCfg = Debug|x64
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Debug|x64.ActiveCfg = Debug|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Release|Mixed Platforms.Build.0 = Release|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Release|Win32.ActiveCfg = Release|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Release|Win32.Build.0 = Release|Win32
{1B3BEA4C-CF75-438A-9693-60FB8444BBF3}.Release|x64.ActiveCfg = Release|Win32
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Debug|Win32.ActiveCfg = Debug|Win32
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Debug|Win32.Build.0 = Debug|Win32
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Debug|x64.ActiveCfg = Debug|x64
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Debug|x64.Build.0 = Debug|x64
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Release|Mixed Platforms.ActiveCfg = Release|Win32
@ -205,6 +193,60 @@ Global
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Release|Win32.Build.0 = Release|Win32
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Release|x64.ActiveCfg = Release|x64
{2A1BC987-AF42-4500-802D-89CD32FC1309}.Release|x64.Build.0 = Release|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|Win32.ActiveCfg = Debug|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|x64.ActiveCfg = Debug|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Debug|x64.Build.0 = Debug|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Mixed Platforms.Build.0 = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Win32.ActiveCfg = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|Win32.Build.0 = Release|Win32
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|x64.ActiveCfg = Release|x64
{B1195BB9-B3A5-47F0-906C-8DEA384D1520}.Release|x64.Build.0 = Release|x64
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Debug|Win32.ActiveCfg = Debug|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Debug|x64.ActiveCfg = Debug|x64
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Debug|x64.Build.0 = Debug|x64
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Release|Mixed Platforms.Build.0 = Release|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Release|Win32.ActiveCfg = Release|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Release|Win32.Build.0 = Release|Win32
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Release|x64.ActiveCfg = Release|x64
{52380DAA-0F4A-4D97-8E57-98DF39319CAF}.Release|x64.Build.0 = Release|x64
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Debug|Win32.ActiveCfg = Debug|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Debug|x64.ActiveCfg = Debug|x64
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Debug|x64.Build.0 = Debug|x64
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Release|Mixed Platforms.Build.0 = Release|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Release|Win32.ActiveCfg = Release|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Release|Win32.Build.0 = Release|Win32
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Release|x64.ActiveCfg = Release|x64
{8690FDDF-C5B7-4C42-A337-BD5243F29B85}.Release|x64.Build.0 = Release|x64
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Debug|Win32.ActiveCfg = Debug|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Debug|x64.ActiveCfg = Debug|x64
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Debug|x64.Build.0 = Debug|x64
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Release|Mixed Platforms.Build.0 = Release|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Release|Win32.ActiveCfg = Release|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Release|Win32.Build.0 = Release|Win32
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Release|x64.ActiveCfg = Release|x64
{460D625F-2AC9-4559-B809-0BA89CEAEDF4}.Release|x64.Build.0 = Release|x64
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Debug|Win32.ActiveCfg = Debug|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Debug|x64.ActiveCfg = Debug|x64
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Debug|x64.Build.0 = Debug|x64
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Release|Mixed Platforms.Build.0 = Release|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Release|Win32.ActiveCfg = Release|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Release|Win32.Build.0 = Release|Win32
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78}.Release|x64.ActiveCfg = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@ -213,5 +255,11 @@ Global
{838B25C2-D19E-49FE-8CB0-9A977CA3C7E8} = {C27B926E-B3EF-4990-8822-47580E43A0BE}
{6A066806-F43F-4B31-A4E3-57179674F460} = {C27B926E-B3EF-4990-8822-47580E43A0BE}
{C5AA09D0-6594-4CD3-BD92-1D380C7B3B50} = {C27B926E-B3EF-4990-8822-47580E43A0BE}
{460D625F-2AC9-4559-B809-0BA89CEAEDF4} = {C27B926E-B3EF-4990-8822-47580E43A0BE}
{2A1BC987-AF42-4500-802D-89CD32FC1309} = {20720CA7-795C-45AD-A302-9383A6DD503A}
{B1195BB9-B3A5-47F0-906C-8DEA384D1520} = {20720CA7-795C-45AD-A302-9383A6DD503A}
{52380DAA-0F4A-4D97-8E57-98DF39319CAF} = {20720CA7-795C-45AD-A302-9383A6DD503A}
{8690FDDF-C5B7-4C42-A337-BD5243F29B85} = {20720CA7-795C-45AD-A302-9383A6DD503A}
{DA2AA800-ED64-4649-8B3B-E7F1E3968B78} = {20720CA7-795C-45AD-A302-9383A6DD503A}
EndGlobalSection
EndGlobal

View File

@ -0,0 +1,58 @@
/////////////////////////////////////////////////////////////////////
// Created by [Dennis Andersen] [2013]
/////////////////////////////////////////////////////////////////////
#include "CustomNetProtocol.h"
#include <map>
using namespace Network;
struct CustomNetProtocol::PrivateData
{
std::map<int, NetAttributeContainer> attributes;
PrivateData()
{ }
~PrivateData()
{
for (auto i = attributes.begin(); i != attributes.end(); i++)
{
RemoveAttribute(i->first);
}
}
void RemoveAttribute(int ID)
{
auto i = attributes.find(ID);
if(i == attributes.end()) return;
switch (i->second.type)
{
case NetAttributeType_CharArray:
delete [] i->second.value.netCharPtr;
break;
}
}
//Do network stuff
};
CustomNetProtocol::CustomNetProtocol()
{
this->privateData = new PrivateData();
}
CustomNetProtocol::~CustomNetProtocol()
{
delete this->privateData;
}
NetAttributeContainer& CustomNetProtocol::operator[](int ID)
{
if(this->privateData->attributes.find(ID) == this->privateData->attributes.end())
{
this->privateData->attributes[ID];
this->privateData->attributes[ID].type = NetAttributeType_UNKNOWN;
memset(&this->privateData->attributes[ID].value, 0, sizeof(NetAttributeValue));
}
return this->privateData->attributes[ID];
}

View File

@ -46,7 +46,7 @@ namespace Network
float netFloat;
double netDouble;
char* netCharPtr;
NetAttributeValue(){ memset(this, 0, sizeof(NetAttributeValue)); }
NetAttributeValue(bool v) : netBool (v) {}
NetAttributeValue(char v) : netChar (v) {}
@ -67,34 +67,19 @@ namespace Network
NetAttributeValue value;
NetAttributeContainer() { type = NetAttributeType_UNKNOWN; }
};
class CustomNetProtocol;
struct CustomProtocolObject
{
virtual CustomNetProtocol* GetProtocol() = 0;
};
class NET_PROTOCOL_EXPORT CustomNetProtocol
{
public:
CustomNetProtocol();
~CustomNetProtocol();
NetAttributeContainer* operator[](int ID);
NetAttributeContainer* BuildValue(NetAttributeContainer value, short attributeId);
NetAttributeContainer* BuildValue(NetAttributeValue value, NetAttributeType type, short attributeId);
NetAttributeContainer* BuildValue(const bool & attribute, short attributeId);
NetAttributeContainer* BuildValue(const char & attribute, short attributeId);
NetAttributeContainer* BuildValue(const unsigned char & attribute, short attributeId);
NetAttributeContainer* BuildValue(const short & attribute, short attributeId);
NetAttributeContainer* BuildValue(const unsigned short & attribute, short attributeId);
NetAttributeContainer* BuildValue(const int & attribute, short attributeId);
NetAttributeContainer* BuildValue(const unsigned int & attribute, short attributeId);
NetAttributeContainer* BuildValue(const __int64 & attribute, short attributeId);
NetAttributeContainer* BuildValue(const unsigned __int64 & attribute, short attributeId);
NetAttributeContainer* BuildValue(const float & attribute, short attributeId);
NetAttributeContainer* BuildValue(const double & attribute, short attributeId);
NetAttributeContainer* BuildValue(const std::string & attribute, short attributeId);
NetAttributeContainer* BuildValue(const char * attribute, short attributeId);
//void SetArrayValue(NetAttributeContainer attribute[], unsigned int attributeCount, int attributeId);
NetAttributeContainer& GetSingleValue(int attributeID);
//NetAttributeContainer* GetArrayValue(int attributeID);
NetAttributeContainer& operator[](int ID);
private:
struct PrivateData;

View File

@ -21,8 +21,8 @@
<PropertyGroup Label="Globals">
<ProjectGuid>{460D625F-2AC9-4559-B809-0BA89CEAEDF4}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>NetworkProtocol</RootNamespace>
<ProjectName>NetworkProtocol</ProjectName>
<RootNamespace>NetworkAPI</RootNamespace>
<ProjectName>NetworkAPI</ProjectName>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">

View File

@ -1,296 +0,0 @@
/////////////////////////////////////////////////////////////////////
// Created by [Dennis Andersen] [2013]
/////////////////////////////////////////////////////////////////////
#include "CustomNetProtocol.h"
#include <map>
using namespace Network;
enum NetContainerType
{
NetContainer_Array,
NetContainer_Single,
NetContainer_UNKNOWN,
};
struct NetAttributeArray
{
NetAttributeContainer *value;
int count;
NetAttributeArray()
:value(0)
, count(0)
{}
};
union NetAttributeData
{
struct { NetAttributeContainer singleVal; };
struct { NetAttributeArray arrayVal; };
};
struct NetDataValue
{
NetContainerType containerType;
NetAttributeData attributeData;
NetDataValue()
{
//memset(&attributeData, 0, sizeof(NetAttributeData));
containerType = NetContainer_UNKNOWN;
attributeData.singleVal.type = NetAttributeType_UNKNOWN;
}
};
struct CustomNetProtocol::PrivateData
{
std::map<int, NetDataValue> attributes;
//DataValue *val;
//unsigned int size;
PrivateData()
{
//val = new DataValue[_size];
//size = _size;
}
~PrivateData()
{
for (auto i = attributes.begin(); i != attributes.end(); i++)
{
RemoveAttribute(i->first);
}
}
void RemoveAttribute(int ID)
{
auto i = attributes.find(ID);
if(i == attributes.end()) return;
if(i->second.containerType == NetContainer_Single)
{
switch (i->second.attributeData.singleVal.type)
{
case NetAttributeType_CharArray:
delete [] i->second.attributeData.singleVal.value.netCharPtr;
break;
}
}
else if(i->second.containerType == NetContainer_Array)
{
}
}
//Do network stuff
};
CustomNetProtocol::CustomNetProtocol()
{
this->privateData = new PrivateData();
}
CustomNetProtocol::~CustomNetProtocol()
{
delete this->privateData;
}
NetAttributeContainer* CustomNetProtocol::operator[](int ID)
{
NetAttributeContainer *retVal = 0;
if(this->privateData->attributes.find(ID) == this->privateData->attributes.end())
return retVal;
if(this->privateData->attributes[ID].containerType == NetContainer_Single)
retVal = &this->privateData->attributes[ID].attributeData.singleVal;
if(this->privateData->attributes[ID].containerType == NetContainer_Array)
retVal = this->privateData->attributes[ID].attributeData.arrayVal.value;
return retVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(NetAttributeContainer val, short ID)
{
if(val.type == NetAttributeType_UNKNOWN) return 0;
this->privateData->RemoveAttribute(ID);
this->privateData->attributes[ID].attributeData.singleVal = val;
return &this->privateData->attributes[ID].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(NetAttributeValue value, NetAttributeType type, short ID)
{
if(type == NetAttributeType_UNKNOWN) return 0;
this->privateData->RemoveAttribute(ID);
this->privateData->attributes[ID].attributeData.singleVal.value = value;
this->privateData->attributes[ID].attributeData.singleVal.type = type;
return &this->privateData->attributes[ID].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const bool & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netBool = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Bool;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const char & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netChar = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Char;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const unsigned char & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netUChar = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_UnsignedChar;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const short & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netShort = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Short;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const unsigned short & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netUShort = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_UnsignedShort;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const int & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netInt = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Int;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const unsigned int & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netUInt = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_UnsignedInt;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const __int64 & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netInt64 = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Int64;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const unsigned __int64 & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netUInt64 = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_UnsignedInt64;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const float & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netFloat = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Float;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const double & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netDouble = attribute;
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_Double;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const std::string & attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netCharPtr = _strdup(attribute.c_str());
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_CharArray;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
NetAttributeContainer* CustomNetProtocol::BuildValue(const char* attribute, short attributeId)
{
this->privateData->RemoveAttribute(attributeId);
this->privateData->attributes[attributeId].attributeData.singleVal.value.netCharPtr = _strdup(attribute);
this->privateData->attributes[attributeId].attributeData.singleVal.type = NetAttributeType_CharArray;
this->privateData->attributes[attributeId].containerType = NetContainer_Single;
return &this->privateData->attributes[attributeId].attributeData.singleVal;
}
//void CustomNetProtocol::SetArrayValue(NetAttributeContainer attribute[], unsigned int attributeCount, int ID)
//{
// if(this->privateData->attributes.find(ID) == this->privateData->attributes.end())
// {
// this->privateData->attributes[ID] = NetDataValue();
// }
//
// if(this->privateData->attributes[ID].containerType == NetContainer_UNKNOWN)
// this->privateData->attributes[ID].containerType = NetContainer_Array;
//
// this->privateData->attributes[ID].attributeData.arrayVal.value = attribute;
//}
NetAttributeContainer& CustomNetProtocol::GetSingleValue(int attributeID)
{
return this->privateData->attributes[attributeID].attributeData.singleVal;
}
//NetAttributeContainer* CustomNetProtocol::GetArrayValue(int attributeID)
//{
// return this->privateData->attributes[attributeID].attributeData.arrayVal.value;
//}