Changeset 7d7df47 in network-game for client


Ignore:
Timestamp:
Nov 19, 2012, 8:45:48 PM (12 years ago)
Author:
dportnoy <dmp1488@…>
Branches:
master
Children:
aee34b9
Parents:
51f5101
Message:

Added a directory for common code and added basic boost library code to the client

Location:
client
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • client/.gitignore

    r51f5101 r7d7df47  
    11Debug/
    22ipch/
     3Client.suo
    34Client.sdf
    4 Client.suo
     5Client.opensdf
  • client/Client/Client.vcxproj

    r51f5101 r7d7df47  
    4242      <WarningLevel>Level3</WarningLevel>
    4343      <Optimization>Disabled</Optimization>
     44      <AdditionalIncludeDirectories>C:\Program Files\boost\boost_1_51;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    4445    </ClCompile>
    4546    <Link>
     
    6364    <ClCompile Include="main.cpp" />
    6465  </ItemGroup>
     66  <ItemGroup>
     67    <ClInclude Include="..\..\common\message.h" />
     68  </ItemGroup>
    6569  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
    6670  <ImportGroup Label="ExtensionTargets">
  • client/Client/Client.vcxproj.filters

    r51f5101 r7d7df47  
    1414      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
    1515    </Filter>
     16    <Filter Include="Source Files\common">
     17      <UniqueIdentifier>{9ecfb491-9e8e-4a29-bc07-dd887204d590}</UniqueIdentifier>
     18    </Filter>
    1619  </ItemGroup>
    1720  <ItemGroup>
     
    2023    </ClCompile>
    2124  </ItemGroup>
     25  <ItemGroup>
     26    <ClInclude Include="..\..\common\message.h">
     27      <Filter>Source Files\common</Filter>
     28    </ClInclude>
     29  </ItemGroup>
    2230</Project>
  • client/Client/main.cpp

    r51f5101 r7d7df47  
    1010#include <iostream>
    1111
     12#include <boost/lambda/lambda.hpp>
     13
     14#include "../../common/message.h"
     15
    1216#pragma comment(lib, "ws2_32.lib")
    1317
     
    1519
    1620void error(const char *);
     21
     22int boost_main()
     23{
     24    using namespace boost::lambda;
     25    typedef istream_iterator<int> in;
     26
     27    for_each(in(cin), in(), cout << (_1 * 3) << " " );
     28
     29        return 0;
     30}
     31
    1732int main(int argc, char *argv[])
    1833{
     
    7388}
    7489
     90/*
     91int sendMessage(short type, string contents, int sock, struct sockaddr_in *dest)
     92{
     93        NETWORK_MSG msg;
     94
     95        msg.type = type;
     96        strcpy(msg.buffer, contents.c_str());
     97
     98        return sendto(sock, (char*)&msg, sizeof(NETWORK_MSG), 0, (struct sockaddr *)dest, sizeof(dest));
     99}
     100*/
     101
    75102void error(const char *msg)
    76103{
Note: See TracChangeset for help on using the changeset viewer.