禁用GM
This commit is contained in:
parent
04d3fc4952
commit
da8f73020f
@ -32,9 +32,6 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func ReqGmCommand(player *Player, buf []byte) error {
|
func ReqGmCommand(player *Player, buf []byte) error {
|
||||||
// if conf.Server.GameName != "pet_home" && conf.Server.GameName != "merge_pet_sdk" {
|
|
||||||
// return fmt.Errorf("Player %d ReqGmCommand not support in game %s", player.M_DwUin, conf.Server.GameName)
|
|
||||||
// }
|
|
||||||
detail := &msg.ReqGmCommand{}
|
detail := &msg.ReqGmCommand{}
|
||||||
proto.Unmarshal(buf, detail)
|
proto.Unmarshal(buf, detail)
|
||||||
return ReqGmCommand_(player, detail.Command)
|
return ReqGmCommand_(player, detail.Command)
|
||||||
@ -45,6 +42,9 @@ func ReqGmCommand_(player *Player, Command string) error {
|
|||||||
// log.Error("ReqGmCommand panic: %v", err)
|
// log.Error("ReqGmCommand panic: %v", err)
|
||||||
// }
|
// }
|
||||||
// }()
|
// }()
|
||||||
|
if conf.Server.GameName != "pet_home" && conf.Server.GameName != "merge_pet_sdk" {
|
||||||
|
return fmt.Errorf("Player %d ReqGmCommand not support in game %s, command %s", player.M_DwUin, conf.Server.GameName, Command)
|
||||||
|
}
|
||||||
player.TeLog("gm", map[string]interface{}{
|
player.TeLog("gm", map[string]interface{}{
|
||||||
"command": Command,
|
"command": Command,
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user