feat(go): Port full Ananta private server to Go architecture

This commit is contained in:
CAtlas0784 committed 2026-10-29 03:12:00 +07:00
1 parent ca2e80f9b7
commit c73d744649
28 files changed
+3585 -57

No files matched your search

+22
View File
@@ -0,0 +1,22 @@
package protocol
type RpcPacketKind byte
const (
PacketKindUnknown RpcPacketKind = 0x00
PacketKindInvoke RpcPacketKind = 0x01
PacketKindReturn RpcPacketKind = 0x02
PacketKindNotify RpcPacketKind = 0x03
)
type RpcPacket struct {
Kind RpcPacketKind
MethodID uint32
InvokeID int32
Error int32
Body []byte
}
func (p RpcPacket) IsInvoke() bool { return p.Kind == PacketKindInvoke }
func (p RpcPacket) IsNotify() bool { return p.Kind == PacketKindNotify }
func (p RpcPacket) IsReturn() bool { return p.Kind == PacketKindReturn }