Compare commits
2 Commits
c1e7aba879
...
e34f92b0d8
Author | SHA1 | Date | |
---|---|---|---|
e34f92b0d8 | |||
6f773bcecf |
@ -56,7 +56,7 @@ extern "C" {
|
||||
#define WHY2_CHAT_COMMAND_EXIT "exit" //QUIT THE PROGRAM CMD
|
||||
#define WHY2_CHAT_COMMAND_HELP "help" //PRINT ALL COMMANDS
|
||||
#define WHY2_CHAT_COMMAND_LIST "list" //LIST ALL CONNECTIONS
|
||||
#define WHY2_CHAT_COMMAND_PM "pm" //PRIVATE MESSAGES
|
||||
#define WHY2_CHAT_COMMAND_DM "dm" //DIRECT (UNENCRYPTED) MESSAGES
|
||||
#define WHY2_CHAT_COMMAND_VERSION "version" //COMPARE CLIENT VERSION AND SERVER VERSION
|
||||
|
||||
//SHORTCUTS CAUSE I'M LAZY BITCH
|
||||
|
@ -98,7 +98,7 @@ int main(void)
|
||||
|
||||
why2_check_version(); //CHECK FOR UPDATES
|
||||
why2_chat_init_client_config(); //CREATE client.toml CONFIGURATION
|
||||
why2_chat_init_keys(); //CREATE RSA KEYS
|
||||
why2_chat_init_keys(); //CREATE ECC KEY
|
||||
|
||||
listen_socket = socket(AF_INET, SOCK_STREAM, 0); //CREATE SERVER SOCKET
|
||||
char *line = NULL;
|
||||
@ -188,14 +188,14 @@ int main(void)
|
||||
"\nCommands:\n---------\n%s\n\n>>> ",
|
||||
|
||||
WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_HELP "\t\tPrints out all the commands. :)\n"
|
||||
WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_PM " <ID> <MSG>\tSends private message to user.\n"
|
||||
WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_DM " <ID> <MSG>\tSends direct message to user.\n"
|
||||
WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_LIST "\t\tLists all users and their IDs.\n"
|
||||
WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_VERSION "\tCheck server version.\n"
|
||||
WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_EXIT "\t\tExits the program."
|
||||
);
|
||||
|
||||
fflush(stdout);
|
||||
} else if (command(line, WHY2_CHAT_COMMAND_PM, &cmd_arg))
|
||||
} else if (command(line, WHY2_CHAT_COMMAND_DM, &cmd_arg))
|
||||
{
|
||||
char *id; //PM RECEIVER
|
||||
char *msg; //something racial
|
||||
|
Loading…
x
Reference in New Issue
Block a user