diff --git a/src/rooms/commands/DiscardCommand.ts b/src/rooms/commands/DiscardCommand.ts index 3d44def..5938aeb 100644 --- a/src/rooms/commands/DiscardCommand.ts +++ b/src/rooms/commands/DiscardCommand.ts @@ -110,7 +110,7 @@ export class DiscardCommand extends Command= 0) { let maxTime = new GameEnv().maxDiscardTime * 1000 let count = elapsedTime - maxTime - let newCount = player.extraTime - Math.min(count, 0) + let newCount = player.extraTime - Math.max(count, 0) player.extraTime = Math.max(newCount, 0) } for (let card of tmpCards) { diff --git a/src/rooms/commands/SelectPetCommand.ts b/src/rooms/commands/SelectPetCommand.ts index a3b4975..e2d46e4 100644 --- a/src/rooms/commands/SelectPetCommand.ts +++ b/src/rooms/commands/SelectPetCommand.ts @@ -77,7 +77,7 @@ export class SelectPetCommand extends Command= 0) { let count = elapsedTime - new GameEnv().playerActTime * 1000 - let newCount = player.extraTime - Math.min(count, 0) + let newCount = player.extraTime - Math.max(count, 0) player.extraTime = Math.max(newCount, 0) }