37 lines
690 B
Go
37 lines
690 B
Go
package main
|
|
|
|
import (
|
|
"server/conf"
|
|
"server/game"
|
|
"server/gate"
|
|
"server/pkg/github.com/name5566/leaf"
|
|
|
|
lconf "server/pkg/github.com/name5566/leaf/conf"
|
|
)
|
|
|
|
func main() {
|
|
lconf.LogLevel = conf.Server.LogLevel
|
|
lconf.LogPath = conf.Server.LogPath
|
|
lconf.LogFlag = conf.LogFlag
|
|
lconf.ConsolePort = conf.Server.ConsolePort
|
|
lconf.ProfilePath = conf.Server.ProfilePath
|
|
|
|
lconf.ListenAddr = conf.Server.ListenAddr
|
|
lconf.CenterAddr = conf.Server.CenterAddr
|
|
lconf.PendingWriteNum = conf.PendingWriteNum
|
|
|
|
// c := cron.New()
|
|
|
|
// c.AddFunc("@every 1s", func() {
|
|
// fmt.Println("tick every 1 second")
|
|
// })
|
|
|
|
// c.Start()
|
|
leaf.Run(
|
|
game.Module,
|
|
gate.Module,
|
|
// login.Module,
|
|
)
|
|
|
|
}
|