mirror of
https://github.com/unanmed/HumanBreak.git
synced 2025-10-29 10:22:59 +08:00
chore: 录像调试说明 & 打包调试
This commit is contained in:
parent
a521699094
commit
66e60f5f15
@ -3,12 +3,20 @@ import { create } from './create';
|
||||
import { patchAll } from '@user/data-fallback';
|
||||
import { loading } from '@user/data-base';
|
||||
import { Patch } from '@motajs/legacy-common';
|
||||
import { logger } from '@motajs/common';
|
||||
|
||||
export function createData() {
|
||||
createMota();
|
||||
patchAll();
|
||||
create();
|
||||
|
||||
if (main.replayChecking) {
|
||||
logger.log(
|
||||
`如果需要调试录像验证,请在 script/build-game.ts 中将 DEBUG_REPLAY 设为 true,` +
|
||||
`此时录像验证中可以看到完整正确的报错栈。调试完毕后,记得将它重新设为 false`
|
||||
);
|
||||
}
|
||||
|
||||
loading.once('coreInit', () => {
|
||||
Patch.patchAll();
|
||||
});
|
||||
|
||||
@ -13,6 +13,9 @@ import { RequiredData, RequiredIconsData, ResourceType } from './types';
|
||||
import { splitResource, SplittedResource } from './build-resource';
|
||||
import { formatSize } from './utils';
|
||||
|
||||
/** 打包调试 */
|
||||
const DEBUG_BUILD = false;
|
||||
/** 录像验证调试 */
|
||||
const DEBUG_REPLAY = false;
|
||||
|
||||
const ansi = {
|
||||
@ -52,6 +55,7 @@ async function buildClient(outDir: string) {
|
||||
build: {
|
||||
outDir,
|
||||
copyPublicDir: true,
|
||||
minify: !DEBUG_BUILD,
|
||||
rollupOptions: {
|
||||
external: ['@wasm-audio-decoders/opus-ml'],
|
||||
output: {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user