mirror of
https://github.com/Mezeporta/Erupe.git
synced 2026-03-24 00:23:39 +01:00
add ClientMode config option
This commit is contained in:
@@ -35,16 +35,16 @@ const (
|
||||
BroadcastTypeWorld = 0x0a
|
||||
)
|
||||
|
||||
var commands map[string]config.Command
|
||||
var commands map[string]_config.Command
|
||||
|
||||
func init() {
|
||||
commands = make(map[string]config.Command)
|
||||
commands = make(map[string]_config.Command)
|
||||
zapConfig := zap.NewDevelopmentConfig()
|
||||
zapConfig.DisableCaller = true
|
||||
zapLogger, _ := zapConfig.Build()
|
||||
defer zapLogger.Sync()
|
||||
logger := zapLogger.Named("commands")
|
||||
cmds := config.ErupeConfig.Commands
|
||||
cmds := _config.ErupeConfig.Commands
|
||||
for _, cmd := range cmds {
|
||||
commands[cmd.Name] = cmd
|
||||
if cmd.Enabled {
|
||||
@@ -55,7 +55,7 @@ func init() {
|
||||
}
|
||||
}
|
||||
|
||||
func sendDisabledCommandMessage(s *Session, cmd config.Command) {
|
||||
func sendDisabledCommandMessage(s *Session, cmd _config.Command) {
|
||||
sendServerChatMessage(s, fmt.Sprintf(s.server.dict["commandDisabled"], cmd.Name))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user