All checks were successful
Plugin Library CI / publish (00.BuildOriginality) (push) Successful in 13s
Plugin Library CI / publish (00.StaryEvo) (push) Successful in 17s
Plugin Library CI / publish (00.StaryEvoTools) (push) Successful in 35s
Plugin Library CI / publish (01.HybridCLR) (push) Successful in 15s
Plugin Library CI / publish (02.InformationSave) (push) Successful in 3s
Plugin Library CI / publish (03.YooAsset) (push) Successful in 33s
Plugin Library CI / publish (04.AudioCore) (push) Successful in 3s
Plugin Library CI / publish (05.TableTextConversion) (push) Successful in 5s
Plugin Library CI / publish (06.UIFarme) (push) Successful in 15s
Plugin Library CI / publish (07.RKTools) (push) Successful in 2s
Plugin Library CI / publish (08.UniTask) (push) Successful in 3s
Plugin Library CI / publish (09.CodeChecker) (push) Successful in 16s
Plugin Library CI / publish (10.StoryEditor) (push) Successful in 3s
Plugin Library CI / publish (10.XNode) (push) Successful in 3s
Plugin Library CI / publish (11.PointCloudTools) (push) Successful in 2s
Plugin Library CI / publish (12.WeixinMinigame) (push) Successful in 2m32s
23 lines
751 B
JavaScript
23 lines
751 B
JavaScript
import binaryen from "binaryen";
|
|
import process from "process";
|
|
import fs from "fs";
|
|
|
|
if (process.argv.length < 3) {
|
|
console.error("cannot find wasmcode, Usage: node dump_wasm_symbo.mjs <your_minigame_dir>");
|
|
process.exit(-1);
|
|
}
|
|
let dir = process.argv[2];
|
|
if (!dir.endsWith("/")) {
|
|
dir += "/";
|
|
}
|
|
let bin = fs.readFileSync(dir + "webgl/Build/webgl.wasm");
|
|
binaryen.then(function(binaryenOb){
|
|
let mod = binaryenOb.readBinary(bin);
|
|
let symbols = {};
|
|
for (let i = 0; i < mod.getNumFunctions(); ++i) {
|
|
let ref = mod.getFunctionByIndex(i);
|
|
let func = binaryenOb.getFunctionInfo(ref);
|
|
symbols[i] = func.name;
|
|
}
|
|
fs.writeFileSync(dir + "minigame/webgl.wasm.symbols.unityweb", JSON.stringify(symbols));
|
|
}) |