xiongzhu 2 лет назад
Родитель
Сommit
34eb24fde7
1 измененных файлов с 5 добавлено и 5 удалено
  1. 5 5
      src/game/game.service.ts

+ 5 - 5
src/game/game.service.ts

@@ -740,7 +740,7 @@ export class GameService implements OnModuleInit {
                 }
             }
         } catch (error) {
-            this.logger.error(error.message, error.stack, 'RUN')
+            this.logger.error('runError: ' + error.message, error.stack, 'RUN')
         }
         this.logger.log('停止运行')
         if (resolve) resolve()
@@ -819,7 +819,7 @@ export class GameService implements OnModuleInit {
                     return i as PlotOption
                 })
             } catch (error) {
-                this.logger.error(error)
+                this.logger.error('createOptionsError: ' + error.message, error.stack, 'CREATE_OPTIONS')
             }
         }
     }
@@ -837,7 +837,7 @@ export class GameService implements OnModuleInit {
                 charactor.danmuUserId = c.danmuUserId
                 return charactor
             } catch (error) {
-                this.logger.error(error)
+                this.logger.error('createCharactorError: ' + error.message, error.stack, 'CREATE_CHARACTOR')
             }
         } else {
             this.logger.log(`没有找到弹幕`)
@@ -925,7 +925,7 @@ export class GameService implements OnModuleInit {
                 const output = await parser.parse(response.content.replace("'", '"'))
                 return output as Charactor
             } catch (error) {
-                this.logger.error(error)
+                this.logger.error('createNewCharactorError: ' + error.message, error.stack, 'CREATE_NEW_CHARACTOR')
             }
         }
         throw new InternalServerErrorException('无法生成新角色')
@@ -963,7 +963,7 @@ export class GameService implements OnModuleInit {
                 const output = await parser.parse(response.content)
                 return output
             } catch (error) {
-                this.logger.error(error)
+                this.logger.error('modifyHpError: ' + error.message, error.stack, 'MODIFY_HP')
             }
         }
         throw new InternalServerErrorException('无法生成HP调整值')