playroom bug修复

This commit is contained in:
hahwu 2025-02-08 10:30:47 +08:00
parent e52432ec1a
commit fe6cffa6e4
2 changed files with 4 additions and 2 deletions

View File

@ -197,12 +197,12 @@ func PlayroomTrigger(Id int, Time int64, Num int) (int64, int) {
if n > 100 {
return 0, 0
}
Num--
NeedDuration := playroomCfg.GetPhysiologyDuration(Id, Num)
Time += int64(NeedDuration)
if Time > Now {
return Time, Num
}
Num--
if Num == 0 {
return 0, 0
}

View File

@ -183,6 +183,8 @@ func UnitOrder2(p *Player, Lv, EnergyMul int) float64 {
func UnitPlayroom(p *Player) error {
PlayroomMod := p.PlayMod.getPlayroomMod()
PlayroomMod.CreateOrderReward(100, p.PlayMod.getItemMod())
PlayroomMod.Physiology[1].Num = 10
PlayroomMod.Physiology[1].Time = 1738978968
LimitedTimePlayroomTrigger(p)
return nil
}