mirror of https://github.com/deavminet/skippy.git
Added 'names' command
This commit is contained in:
parent
914d00935d
commit
b5091dbf3d
2
dub.json
2
dub.json
|
@ -4,7 +4,7 @@
|
|||
],
|
||||
"copyright": "Copyright © 2020, Tristan B. Kildaire",
|
||||
"dependencies": {
|
||||
"libdnet": "~>0.0.4",
|
||||
"libdnet": "~>0.0.5",
|
||||
"tristanable": "~>0.0.33"
|
||||
},
|
||||
"description": "dnet client",
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"fileVersion": 1,
|
||||
"versions": {
|
||||
"bformat": "1.0.8",
|
||||
"libdnet": "0.0.4",
|
||||
"libdnet": "0.0.5",
|
||||
"tristanable": "0.0.33"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -166,6 +166,12 @@ void commandLine()
|
|||
writeln(to!(string)(memberCount)~")");
|
||||
}
|
||||
}
|
||||
/* If the command is `names` */
|
||||
else if(cmp(command, "names") == 0)
|
||||
{
|
||||
string[] members = dclient.getMembers(currentChannel);
|
||||
writeln(members);
|
||||
}
|
||||
/* If the command is `join` */
|
||||
else if(cmp(command, "join") == 0)
|
||||
{
|
||||
|
|
|
@ -28,12 +28,12 @@ public class NotificationWatcher : Thread
|
|||
|
||||
if(notifications.length)
|
||||
{
|
||||
writeln(notifications);
|
||||
//writeln(notifications);
|
||||
foreach(NotificationReply notificationReply; notifications)
|
||||
{
|
||||
writeln(notificationReply.getData());
|
||||
//writeln(notificationReply.getData());
|
||||
string msg = cast(string)notificationReply.getData();
|
||||
writeln("!> "~msg);
|
||||
//writeln("!> "~msg);
|
||||
process(notificationReply.getData());
|
||||
}
|
||||
}
|
||||
|
@ -64,7 +64,7 @@ public class NotificationWatcher : Thread
|
|||
{
|
||||
/* TODO: Decode using tristanable */
|
||||
/* TODO: Get the username of the user that left */
|
||||
writeln("user left/join message");
|
||||
//writeln("user left/join message");
|
||||
|
||||
/* Get the sub-type */
|
||||
byte subType = data[1];
|
||||
|
|
Loading…
Reference in New Issue