diff --git a/logic/controller/action_egg.go b/logic/controller/action_egg.go index 71b9d550..8104ba80 100644 --- a/logic/controller/action_egg.go +++ b/logic/controller/action_egg.go @@ -20,6 +20,11 @@ func (h Controller) EggGamePlay(data1 *egg.C2S_EGG_GAME_PLAY, c *player.Player) case 3: data1.EggNum = 10 } + r := c.Service.Item.CheakItem(400501) + if r < data1.EggNum { + return nil, errorcode.ErrorCode(errorcode.ErrorCodes.ErrSystemError) + + } result = &egg.S2C_EGG_GAME_PLAY{ListInfo: []data.ItemInfo{}} if grand.Meet(int(data1.EggNum), 100) { r := service.NewPetRewardService().GetEgg() diff --git a/modules/config/service/shiny.go b/modules/config/service/shiny.go index 85aef956..82c9fe38 100644 --- a/modules/config/service/shiny.go +++ b/modules/config/service/shiny.go @@ -35,6 +35,9 @@ func NewShinyService() *ShinyService { func (s *ShinyService) ModifyBefore(ctx context.Context, method string, param g.MapStrAny) (err error) { var t data.GlowFilter + if method == "Delete" { + return nil + } r := json.Unmarshal([]byte(gconv.String(param["color"])), &t) if r != nil { return r