Improved network code

This commit is contained in:
2024-01-15 17:08:26 +01:00
parent 9b47e374c7
commit b885d70625
17 changed files with 241 additions and 72 deletions

13
server/login.go Normal file
View File

@ -0,0 +1,13 @@
package main
import (
"fmt"
"server/core"
"server/packet"
)
// login checks the account credentials and gives a network peer access to an account.
func login(data []byte, client *core.Client) {
fmt.Println("2 - login!")
server.Send(packet.LOGIN, nil, client)
}