1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-08-12 09:00:54 +00:00

Make client.messageChannel unexported

This commit is contained in:
Kane York 2017-10-27 13:14:29 -07:00
parent a900d1521e
commit 85a0fb7b79
3 changed files with 12 additions and 10 deletions

View file

@ -94,12 +94,6 @@ type AuthInfo struct {
UsernameValidated bool
}
type ClientVersion struct {
Major int
Minor int
Revision int
}
type ClientInfo struct {
// The client ID.
// This must be written once by the owning goroutine before the struct is passed off to any other goroutines.
@ -134,15 +128,21 @@ type ClientInfo struct {
ReadyComplete bool
// Server-initiated messages should be sent via the Send() method.
MessageChannel chan<- ClientMessage
messageChannel chan<- ClientMessage
// Closed when the client is shutting down.
MsgChannelIsDone <-chan struct{}
// Take out an Add() on this during a command if you need to use the MessageChannel later.
// Take out an Add() on this during a command if you need to call Send() later.
MsgChannelKeepalive sync.WaitGroup
}
type ClientVersion struct {
Major int
Minor int
Revision int
}
func VersionFromString(v string) ClientVersion {
var cv ClientVersion
fmt.Sscanf(v, "ffz_%d.%d.%d", &cv.Major, &cv.Minor, &cv.Revision)