Start moving towards working on actual bot, add simplewebsocket submodule

This commit is contained in:
Jack Bond-Preston 2016-06-20 17:42:31 +01:00
parent 5f300cc7ed
commit 17f79b4e0b
7 changed files with 36 additions and 14 deletions

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "TriviaBot/bot/simplewebsocket"]
path = TriviaBot/bot/simplewebsocket
url = https://github.com/eidheim/Simple-WebSocket-Server.git

View File

@ -21,7 +21,7 @@ static int callback(void *x, int argc, char **argv, char **azColName) {
return 0;
}
int main(int argc, char* argv[]) {
int loadDB() {
sqlite3 *db;
char *zErrMsg = 0;
int rc;
@ -30,7 +30,7 @@ int main(int argc, char* argv[]) {
if (rc) {
std::cerr << "Can't open database: " << sqlite3_errmsg(db) << std::endl;
return(0);
return 1;
}
else {
std::cout << "Opened database successfully" << std::endl;
@ -58,7 +58,6 @@ int main(int argc, char* argv[]) {
int result = sqlite3_step(insertThreeQuestions);
std::cout << result << " ";
}
std::cout << std::endl;

View File

@ -1,5 +0,0 @@
#include <stdio.h>
int main(int argc, char* argv[]) {
}

View File

@ -69,20 +69,20 @@
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;$(IncludePath)</IncludePath>
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;C:\Users\Jack\Documents\GitHubVisualStudio\TriviaDiscord\lib\curl\include;$(IncludePath)</IncludePath>
<LibraryPath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3\x64;$(LibraryPath)</LibraryPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;$(IncludePath)</IncludePath>
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;C:\Users\Jack\Documents\GitHubVisualStudio\TriviaDiscord\lib\curl\include;$(IncludePath)</IncludePath>
<LibraryPath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3\x64;$(LibraryPath)</LibraryPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LibraryPath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3\x86;$(LibraryPath)</LibraryPath>
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;$(IncludePath)</IncludePath>
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;C:\Users\Jack\Documents\GitHubVisualStudio\TriviaDiscord\lib\curl\include;$(IncludePath)</IncludePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LibraryPath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3\x86;$(LibraryPath)</LibraryPath>
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;$(IncludePath)</IncludePath>
<IncludePath>C:\Users\Jack\Documents\Visual Studio 2015\Projects\TriviaBot\lib\sqlite3;C:\Users\Jack\Documents\GitHubVisualStudio\TriviaDiscord\lib\curl\include;$(IncludePath)</IncludePath>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
@ -141,13 +141,18 @@
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="TriviaBot.cpp" />
<ClCompile Include="bot\TriviaBot.cpp" />
<ClCompile Include="CSV\LoadDB.cpp" />
</ItemGroup>
<ItemGroup>
<None Include="..\..\..\..\..\AppData\Local\Temp\Rar$DRa0.635\fast-cpp-csv-parser-master\LICENSE" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="bot\simplewebsocket\client_ws.hpp" />
<ClInclude Include="bot\simplewebsocket\client_wss.hpp" />
<ClInclude Include="bot\simplewebsocket\crypto.hpp" />
<ClInclude Include="bot\simplewebsocket\server_ws.hpp" />
<ClInclude Include="bot\simplewebsocket\server_wss.hpp" />
<ClInclude Include="CSV\csv.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />

View File

@ -21,12 +21,27 @@
<ClInclude Include="CSV\csv.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="bot\simplewebsocket\server_wss.hpp">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="bot\simplewebsocket\server_ws.hpp">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="bot\simplewebsocket\crypto.hpp">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="bot\simplewebsocket\client_wss.hpp">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="bot\simplewebsocket\client_ws.hpp">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ClCompile Include="CSV\LoadDB.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="TriviaBot.cpp">
<ClCompile Include="bot\TriviaBot.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>

View File

@ -0,0 +1,4 @@
#include <stdio.h>
int main() {
}

@ -0,0 +1 @@
Subproject commit c284e5a2829ed854712230e7a9112f39ebfc5aae