Skip to content

Commit

Permalink
错误提交
Browse files Browse the repository at this point in the history
  • Loading branch information
candlewill committed Apr 5, 2017
1 parent 4e84acd commit 7e82a7e
Show file tree
Hide file tree
Showing 53 changed files with 65 additions and 20,702 deletions.
4 changes: 3 additions & 1 deletion Bot_tools/Usage/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,6 @@ add_executable(ChatScript_Main Dialog.cpp)

# 添加链接库
# 使用命令 target_link_libraries 指明可执行文件 main 需要连接一个名为 MathFunctions 的链接库
target_link_libraries(ChatScript_Main ChatScript curl)
target_link_libraries(ChatScript_Main ChatScript curl)

add_library()
41 changes: 39 additions & 2 deletions Bot_tools/Usage/Dialog.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,42 @@
#include "common.h"
#include "evserver.h"

// char sourceInput_1[200];

void ChatLoop() // local machine loop
{

char user[MAX_WORD_SIZE];
*ourMainInputBuffer = 0;
sourceFile = stdin;
// if (*sourceInput_1) sourceFile = FopenReadNormal(sourceInput_1);
// else
if (userInitFile) sourceFile = userInitFile;
if (!*loginID)
{
printf((char*)"%s", (char*)"\r\nEnter user name: ");
ReadALine(user, stdin);
printf((char*)"%s", (char*)"\r\n");
if (*user == '*') // let human go first - say "*bruce
{
memmove(user, user + 1, strlen(user));
printf((char*)"%s", (char*)"\r\nEnter starting input: ");
ReadALine(ourMainInputBuffer, stdin);
printf((char*)"%s", (char*)"\r\n");
}
}
else strcpy(user, loginID);
PerformChat(user, computerID, ourMainInputBuffer, NULL, ourMainOutputBuffer); // unknown bot, no input,no ip
printf("%s %s", "output: ", ourMainOutputBuffer);

retry:
ProcessInputFile();
sourceFile = stdin;
*ourMainInputBuffer = 0;
ourMainInputBuffer[1] = 0;
if (!quitting) goto retry;
}

int main(int argc, char * argv[])
{
for (int i = 1; i < argc; ++i)
Expand All @@ -9,7 +45,7 @@ int main(int argc, char * argv[])
{
chdir((char*)argv[i] + 5);
}
}
}

FILE* in = FopenStaticReadOnly((char*)"SRC/dictionarySystem.h"); // SRC/dictionarySystem.h
if (!in) // if we are not at top level, try going up a level
Expand All @@ -21,7 +57,8 @@ int main(int argc, char * argv[])
if (!server)
{
quitting = false; // allow local bots to continue regardless
MainLoop();
// MainLoop();
ChatLoop();
}
else if (quitting) { ; } // boot load requests quit
CloseSystem();
Expand Down
26 changes: 0 additions & 26 deletions Bot_tools/Usage/LOGS/bugs.txt

This file was deleted.

17 changes: 0 additions & 17 deletions Bot_tools/Usage/LOGS/log1024.txt

This file was deleted.

20 changes: 0 additions & 20 deletions Bot_tools/Usage/LOGS/startlog.txt

This file was deleted.

52 changes: 0 additions & 52 deletions Bot_tools/Usage/TMP/backup-user_test.bin

This file was deleted.

Binary file removed Bot_tools/Usage/TMP/prebuild0.bin
Binary file not shown.
Binary file removed Bot_tools/Usage/TMP/prebuild1.bin
Binary file not shown.
Binary file removed Bot_tools/Usage/TMP/prebuild2.bin
Binary file not shown.
3 changes: 0 additions & 3 deletions Bot_tools/Usage/TOPIC/BUILD1/dict1.txt

This file was deleted.

3 changes: 0 additions & 3 deletions Bot_tools/Usage/TOPIC/BUILD1/facts1.txt

This file was deleted.

10 changes: 0 additions & 10 deletions Bot_tools/Usage/TOPIC/BUILD1/keywords1.txt

This file was deleted.

1 change: 0 additions & 1 deletion Bot_tools/Usage/TOPIC/BUILD1/macros1.txt

This file was deleted.

Loading

0 comments on commit 7e82a7e

Please sign in to comment.