copyResource updates (fix error logs, disabled apData for now, added chat stamp copy, webpage update + added guides)
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
Message from repo fork:
|
||||
- I highly recommend using the stable version of the plugin.
|
||||
- This version is only properly usable in proper arcade data, meaning no mods.
|
||||
- This is very work-in-progress. Please **BACK UP YOUR DATA** to prevent unwanted data loss (just in case)
|
||||
- Please always remember to update datecode before using [WebUI Resource Update](/plugin/sdvx@asphyxia/WebUI%20resource%20update) feature (or this plugin in general).
|
||||
- I highly recommend using the official stable version of the plugin.
|
||||
- This is very work-in-progress, so expect things to break. Please **BACK UP YOUR DATA** to prevent unwanted data loss (just in case)
|
||||
- I won't update the text below lol
|
||||
|
||||
----------------------------
|
||||
|
||||
+156
-99
@@ -33,33 +33,40 @@ export function getRandomIntInclusive(min, max) {
|
||||
}
|
||||
|
||||
export const copyResourcesFromGame = async (data: {}) => {
|
||||
let mdbJson;
|
||||
let mdbJsonFix = [];
|
||||
let mdbJsonFixFinal;
|
||||
let mdb = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/others/music_db.xml")
|
||||
let prevAssetMdb = JSON.parse(U.DecodeString(await IO.ReadFile('webui/asset/json/music_db.json'), 'utf8'))
|
||||
let newJsonSongs = [];
|
||||
let newVersionSongs = [];
|
||||
|
||||
let resourceJsonData = JSON.parse(U.DecodeString(await IO.ReadFile('webui/asset/json/data.json'), 'utf8'))
|
||||
let newNemsysData = []
|
||||
let newAPCardData = []
|
||||
let newSubBGData = []
|
||||
let newBGMData = []
|
||||
let newChatStampData = []
|
||||
let runErrors = []
|
||||
let resourceJsonData = JSON.parse(U.DecodeString(await IO.ReadFile('webui/asset/json/data.json'), 'utf8'))
|
||||
|
||||
// Get new music data from music_db.xml
|
||||
let version = '';
|
||||
let ea3Config = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/prop/ea3-config.xml")
|
||||
let configJson = U.parseXML(U.DecodeString(ea3Config, "shift_jis"), false)
|
||||
version = configJson['ea3']['soft']['ext']['@content'];
|
||||
console.log('Getting new music_db info')
|
||||
if(IO.Exists(U.GetConfig('sdvx_eg_root_dir') + "/data/others/music_db.xml")) {
|
||||
let mdb = U.parseXML(U.DecodeString(await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/others/music_db.xml"), "shift_jis"), false)
|
||||
let ea3Config = U.parseXML(U.DecodeString(await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/prop/ea3-config.xml"), "shift_jis"), false)
|
||||
let version = ea3Config['ea3']['soft']['ext']['@content'];
|
||||
let prevAssetMdb = []
|
||||
if(IO.Exists('webui/asset/json/music_db.json')) {
|
||||
prevAssetMdb = JSON.parse(U.DecodeString(await IO.ReadFile('webui/asset/json/music_db.json'), 'utf8'))
|
||||
}
|
||||
|
||||
mdbJson = U.parseXML(U.DecodeString(mdb, "shift_jis"), false)
|
||||
try {
|
||||
mdbJson.mdb.music.forEach(musicValue => {
|
||||
if(prevAssetMdb['mdb']['music'].find(item => parseInt(item['@id']) == parseInt(musicValue.info.label['@content'])) == undefined) {
|
||||
mdb.mdb.music.forEach(musicValue => {
|
||||
if(Object.keys(prevAssetMdb).length > 0) {
|
||||
if(prevAssetMdb['mdb']['music'].find(item => parseInt(item['@id']) == parseInt(musicValue.info.label['@content'])) == undefined) {
|
||||
console.log("New song added to json: " + musicValue.info.title_name['@content'] + " (" + musicValue.info.distribution_date['@content'] + ")")
|
||||
newJsonSongs.push('[' + musicValue.info.distribution_date['@content'] + '] ' + musicValue.info.title_name['@content'])
|
||||
}
|
||||
} else {
|
||||
console.log("New song added to json: " + musicValue.info.title_name['@content'] + " (" + musicValue.info.distribution_date['@content'] + ")")
|
||||
newJsonSongs.push('[' + musicValue.info.distribution_date['@content'] + '] ' + musicValue.info.title_name['@content'])
|
||||
}
|
||||
|
||||
if(parseInt(musicValue.info.distribution_date['@content'][0]) >= parseInt(version.substring(0,8))) {
|
||||
console.log("Found new song for version " + version + ": " + musicValue.info.title_name['@content'] + " (" + musicValue.info.distribution_date['@content'] + ")");
|
||||
newVersionSongs.push('[' + musicValue.info.distribution_date['@content'] + '] ' + musicValue.info.title_name['@content'])
|
||||
@@ -114,11 +121,7 @@ export const copyResourcesFromGame = async (data: {}) => {
|
||||
}
|
||||
});
|
||||
})
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
}
|
||||
|
||||
try{
|
||||
mdbJsonFixFinal = {
|
||||
'mdb': {
|
||||
'version': version,
|
||||
@@ -129,94 +132,151 @@ export const copyResourcesFromGame = async (data: {}) => {
|
||||
if(!IO.Exists('webui/asset/json/music_db_' + version + '.json')){
|
||||
IO.WriteFile('webui/asset/json/music_db_' + version + '.json', JSON.stringify(mdbJsonFixFinal));
|
||||
}
|
||||
} catch(err) {
|
||||
console.log(err)
|
||||
|
||||
} else {
|
||||
console.log('Error reading music_db.xml. Check your "Exceed Gear Data Directory" config.')
|
||||
runErrors.push('[music_db] Error reading music_db.xml. Check your "Exceed Gear Data Directory" config.')
|
||||
}
|
||||
|
||||
// // Copying new nemsys files from gamedata
|
||||
// console.log("Copying new nemsys files from gamedata")
|
||||
// let nemsysFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/game_nemsys")
|
||||
// for await (const nemsys of nemsysFiles) {
|
||||
// let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/game_nemsys/" + nemsys.name)
|
||||
// if(!IO.Exists('webui/asset/nemsys/' + nemsys.name.substring(0, (nemsys.name.length - 4)) + ".png") && !IO.Exists('webui/asset/nemsys/' + nemsys.name.substring(0, (nemsys.name.length - 4)) + ".jpg")) {
|
||||
// IO.WriteFile('webui/asset/nemsys/' + nemsys.name, fileToWrite)
|
||||
// newNemsysData.push(nemsys.name)
|
||||
// } else {
|
||||
// console.log(nemsys.name + " exists")
|
||||
// }
|
||||
// }
|
||||
// Copying new nemsys files from gamedata
|
||||
console.log("Copying new nemsys files from gamedata")
|
||||
if(IO.Exists(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/game_nemsys")) {
|
||||
let nemsysFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/game_nemsys")
|
||||
for await (const nemsys of nemsysFiles) {
|
||||
let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/game_nemsys/" + nemsys.name)
|
||||
if(!IO.Exists('webui/asset/nemsys/' + nemsys.name.substring(0, (nemsys.name.length - 4)) + ".png") && !IO.Exists('webui/asset/nemsys/' + nemsys.name.substring(0, (nemsys.name.length - 4)) + ".jpg")) {
|
||||
IO.WriteFile('webui/asset/nemsys/' + nemsys.name, fileToWrite)
|
||||
newNemsysData.push(nemsys.name)
|
||||
} else {
|
||||
console.log(nemsys.name + " exists")
|
||||
}
|
||||
}
|
||||
|
||||
// newNemsysData.forEach(fileName => {
|
||||
// if(parseInt(fileName.substring(7, 11))) {
|
||||
// resourceJsonData.nemsys.push({"value": parseInt(fileName.substring(7, 11)), "name": fileName + " (please rename)"})
|
||||
// }
|
||||
// })
|
||||
newNemsysData.forEach(fileName => {
|
||||
if(parseInt(fileName.substring(7, 11))) {
|
||||
resourceJsonData.nemsys.push({"value": parseInt(fileName.substring(7, 11)), "name": fileName + " (please rename)"})
|
||||
}
|
||||
})
|
||||
} else {
|
||||
console.log('Error reading nemsys directory. Check your "Exceed Gear Data Directory" config.')
|
||||
runErrors.push('[nemsys] Error reading nemsys directory. Check your "Exceed Gear Data Directory" config.')
|
||||
}
|
||||
|
||||
// // Copying new appeal card files from gamedata
|
||||
// Copying new appeal card files from gamedata (disabled for now)
|
||||
// console.log("Copying new appeal card files from gamedata")
|
||||
// let apCardFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/ap_card")
|
||||
// for await (const apCard of apCardFiles) {
|
||||
// let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/ap_card/" + apCard.name)
|
||||
// if(!IO.Exists('webui/asset/ap_card/' + apCard.name.substring(0, (apCard.name.length - 4)) + ".png") && !IO.Exists('webui/asset/ap_card/' + apCard.name.substring(0, (apCard.name.length - 4)) + ".jpg")) {
|
||||
// IO.WriteFile('webui/asset/ap_card/' + apCard.name, fileToWrite)
|
||||
// newAPCardData.push(apCard.name)
|
||||
// } else {
|
||||
// console.log(apCard.name + " exists")
|
||||
// }
|
||||
// }
|
||||
|
||||
// // Appeal card data registration to data.json not properly implemented yet, I don't quite understand how their IDs work
|
||||
// // newAPCardData.forEach(fileName => {
|
||||
// // if(parseInt(fileName.substring(6, 10))) {
|
||||
// // resourceJsonData.apCard.push({"value": parseInt(fileName.substring(6, 10)), "name": fileName + " (please rename)"})
|
||||
// // }
|
||||
// // })
|
||||
|
||||
// // Copying new subbg files from gamedata
|
||||
// console.log("Copying new subbg files from gamedata")
|
||||
// let subBGFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/submonitor_bg")
|
||||
// for await (const subbg of subBGFiles) {
|
||||
// if (subbg.name.substring(subbg.name.length-4, subbg.name.length).match(/(\.png|\.jpg)/g)) {
|
||||
// let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/submonitor_bg/" + subbg.name)
|
||||
// if(!IO.Exists('webui/asset/submonitor_bg/' + subbg.name.substring(0, (subbg.name.length - 4)) + ".png") && !IO.Exists('webui/asset/submonitor_bg/' + subbg.name.substring(0, (subbg.name.length - 4)) + ".jpg")) {
|
||||
// IO.WriteFile('webui/asset/submonitor_bg/' + subbg.name, fileToWrite)
|
||||
// newSubBGData.push(subbg.name)
|
||||
// if(IO.Exists(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/game_nemsys")) {
|
||||
// let apCardFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/ap_card")
|
||||
// for await (const apCard of apCardFiles) {
|
||||
// let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/ap_card/" + apCard.name)
|
||||
// if(!IO.Exists('webui/asset/ap_card/' + apCard.name.substring(0, (apCard.name.length - 4)) + ".png") && !IO.Exists('webui/asset/ap_card/' + apCard.name.substring(0, (apCard.name.length - 4)) + ".jpg")) {
|
||||
// IO.WriteFile('webui/asset/ap_card/' + apCard.name, fileToWrite)
|
||||
// newAPCardData.push(apCard.name)
|
||||
// } else {
|
||||
// console.log(subbg.name + " exists")
|
||||
// console.log(apCard.name + " exists")
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
// newSubBGData.forEach(fileName => {
|
||||
// if(parseInt(fileName.substring(6, 10))) {
|
||||
// resourceJsonData.subbg.push({"value": parseInt(fileName.substring(6, 10)), "name": fileName + " (please rename)"})
|
||||
// }
|
||||
// })
|
||||
|
||||
// // Copying new bgm files from gamedata
|
||||
// console.log("Copying new bgm files from gamedata")
|
||||
// let bgmFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/sound/custom")
|
||||
// for await (const bgm of bgmFiles) {
|
||||
// if (bgm.name.substring(bgm.name.length-4, bgm.name.length) == '.s3p') {
|
||||
// let folderName = bgm.name.match(/(custom|special)_([0-9]*)/g)[0]
|
||||
// if(folderName != '') {
|
||||
// let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/sound/custom/" + bgm.name)
|
||||
// if(!IO.Exists('webui/asset/audio/' + folderName)) {
|
||||
// IO.WriteFile('webui/asset/audio/' + folderName + '/' + bgm.name, fileToWrite)
|
||||
// newBGMData.push(bgm.name)
|
||||
// } else {
|
||||
// console.log(bgm.name + " exists")
|
||||
// }
|
||||
// // Appeal card data registration to data.json not properly implemented yet, I don't quite understand how their IDs work yet
|
||||
// newAPCardData.forEach(fileName => {
|
||||
// if(parseInt(fileName.substring(6, 10))) {
|
||||
// resourceJsonData.apCard.push({"value": parseInt(fileName.substring(6, 10)), "name": fileName + " (please rename)"})
|
||||
// }
|
||||
// }
|
||||
// })
|
||||
// } else {
|
||||
// console.log('Error reading appeal card directory. Check your "Exceed Gear Data Directory" config.')
|
||||
// runErrors.push('[appeal_card] Error reading appeal card directory. Check your "Exceed Gear Data Directory" config.')
|
||||
// }
|
||||
|
||||
// newBGMData.forEach(fileName => {
|
||||
// let bgmId = fileName.match(/(?<=(custom|special)_)([0-9]*)/g)[0]
|
||||
// if(parseInt(bgmId)) {
|
||||
// resourceJsonData.bgm.push({"value": parseInt(bgmId), "name": fileName + " (please rename)"})
|
||||
// }
|
||||
// })
|
||||
// Copying new subbg files from gamedata
|
||||
console.log("Copying new subbg files from gamedata")
|
||||
if(IO.Exists(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/submonitor_bg")) {
|
||||
let subBGFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/submonitor_bg")
|
||||
for await (const subbg of subBGFiles) {
|
||||
if (subbg.name.substring(subbg.name.length-4, subbg.name.length).match(/(\.png|\.jpg)/g)) {
|
||||
let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/submonitor_bg/" + subbg.name)
|
||||
if(!IO.Exists('webui/asset/submonitor_bg/' + subbg.name.substring(0, (subbg.name.length - 4)) + ".png") && !IO.Exists('webui/asset/submonitor_bg/' + subbg.name.substring(0, (subbg.name.length - 4)) + ".jpg")) {
|
||||
IO.WriteFile('webui/asset/submonitor_bg/' + subbg.name, fileToWrite)
|
||||
newSubBGData.push(subbg.name)
|
||||
} else {
|
||||
console.log(subbg.name + " exists")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
newSubBGData.forEach(fileName => {
|
||||
if(parseInt(fileName.substring(6, 10))) {
|
||||
resourceJsonData.subbg.push({"value": parseInt(fileName.substring(6, 10)), "name": fileName + " (please rename)"})
|
||||
}
|
||||
})
|
||||
} else {
|
||||
console.log('Error reading submonitor_bg directory. Check your "Exceed Gear Data Directory" config.')
|
||||
runErrors.push('[submonitor_bg] Error reading submonitor_bg directory. Check your "Exceed Gear Data Directory" config.')
|
||||
}
|
||||
|
||||
// Copying new bgm files from gamedata
|
||||
console.log("Copying new bgm files from gamedata")
|
||||
if(IO.Exists(U.GetConfig('sdvx_eg_root_dir') + "/data/sound/custom")) {
|
||||
let bgmFiles = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/sound/custom")
|
||||
for await (const bgm of bgmFiles) {
|
||||
if (bgm.name.substring(bgm.name.length-4, bgm.name.length) == '.s3p') {
|
||||
let folderName = bgm.name.match(/(custom|special)_([0-9]*)/g)[0]
|
||||
if(folderName != '') {
|
||||
let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/sound/custom/" + bgm.name)
|
||||
if(!IO.Exists('webui/asset/audio/' + folderName)) {
|
||||
IO.WriteFile('webui/asset/audio/' + folderName + '/' + bgm.name, fileToWrite)
|
||||
newBGMData.push(bgm.name)
|
||||
} else {
|
||||
console.log(bgm.name + " exists")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
newBGMData.forEach(fileName => {
|
||||
let bgmId = fileName.match(/(?<=(custom|special)_)([0-9]*)/g)[0]
|
||||
if(parseInt(bgmId)) {
|
||||
resourceJsonData.bgm.push({"value": parseInt(bgmId), "name": fileName + " (please rename)"})
|
||||
}
|
||||
})
|
||||
} else {
|
||||
console.log('Error reading BGM directory. Check your "Exceed Gear Data Directory" config.')
|
||||
runErrors.push('[BGM] Error reading BGM directory. Check your "Exceed Gear Data Directory" config.')
|
||||
}
|
||||
|
||||
// Copying new chat_stamp files from gamedata
|
||||
console.log("Copying new chat stamp files from gamedata")
|
||||
if(IO.Exists(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/chat_stamp")) {
|
||||
let chat_stamps_folders = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/chat_stamp")
|
||||
for(const chat_stamp_folder of chat_stamps_folders) {
|
||||
let folderName = chat_stamp_folder.name.match(/stamp_([0-9]*)/g)[0]
|
||||
if(folderName != '') {
|
||||
if(!IO.Exists('webui/asset/chat_stamp/' + folderName)) {
|
||||
let chat_stamps = await IO.ReadDir(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/chat_stamp/" + folderName)
|
||||
for(const chat_stamp_ind in chat_stamps) {
|
||||
let fileToWrite = await IO.ReadFile(U.GetConfig('sdvx_eg_root_dir') + "/data/graphics/chat_stamp/" + folderName + '/' + chat_stamps[chat_stamp_ind].name)
|
||||
IO.WriteFile('webui/asset/chat_stamp/' + folderName + '/' + chat_stamps[chat_stamp_ind].name, fileToWrite)
|
||||
newChatStampData.push(chat_stamps[chat_stamp_ind].name)
|
||||
}
|
||||
} else {
|
||||
console.log(folderName + " exists")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
let stampIDCtr = 3;
|
||||
newChatStampData.forEach(fileName => {
|
||||
let stampId = fileName.match(/(?<=(stamp)_)([0-9]*)/g)[0]
|
||||
if(parseInt(stampId)) {
|
||||
let realStampID = (parseInt(stampId) * 4) - stampIDCtr;
|
||||
resourceJsonData.stamp.push({"value": realStampID, "name": fileName + " (please rename)"})
|
||||
}
|
||||
if(stampIDCtr == 0) stampIDCtr = 3;
|
||||
else stampIDCtr--;
|
||||
})
|
||||
} else {
|
||||
console.log('Error reading chat stamp directory. Check your "Exceed Gear Data Directory" config.')
|
||||
runErrors.push('[chat_stamp] Error reading chat stamp directory. Check your "Exceed Gear Data Directory" config.')
|
||||
}
|
||||
|
||||
await IO.WriteFile('webui/asset/json/data.json', JSON.stringify(resourceJsonData))
|
||||
await IO.WriteFile('webui/asset/logs/copyResourcesFromGame.json', JSON.stringify({
|
||||
@@ -224,12 +284,9 @@ export const copyResourcesFromGame = async (data: {}) => {
|
||||
apCard: newAPCardData,
|
||||
subbg: newSubBGData,
|
||||
bgm: newBGMData,
|
||||
chatStamp: newChatStampData,
|
||||
versionSongs: newVersionSongs,
|
||||
jsonSongs: newJsonSongs
|
||||
jsonSongs: newJsonSongs,
|
||||
errors: runErrors
|
||||
}))
|
||||
}
|
||||
|
||||
// export const generateLatestMusicDBFile = async (data: {}) => {
|
||||
|
||||
// return mdbJsonFixFinal;
|
||||
// }
|
||||
@@ -1,7 +1,22 @@
|
||||
//DATA//
|
||||
sdvx_dir: U.GetConfig('sdvx_eg_root_dir')
|
||||
-
|
||||
div
|
||||
.card
|
||||
button.collapse() Notes
|
||||
.card-info.collapsible-card
|
||||
p.card-header-info
|
||||
h5() Notes:
|
||||
ul
|
||||
li() For use with Exceed Gear arcade data.
|
||||
li() Use this if you have arcade data that can be used. It wouldn't work otherwise.
|
||||
li() Make sure you have your 'Exceed Gear Data Directory' in the plugin settings properly configured.
|
||||
li() Update your datacode in the ea3-config.xml file.
|
||||
br
|
||||
p.card-header-bgm-guide
|
||||
h5() BGM asset guide
|
||||
p() This feature pulls BGM files from the data, however they are in unplayable s3p format. For BGM preview to work, we need to extract the audio files from the s3p, and convert it to mp3.
|
||||
p() For Windows, there is a bgm_convert.bat script in the SDVX plugin root directory but it requires 2 things:
|
||||
ul
|
||||
li() <a href="https://github.com/mon/s3p_extract/releases/latest">s3p_extract</a> - download the .exe file from the latest release and put in the same directory as the bat script
|
||||
li() <a href="https://www.gyan.dev/ffmpeg/builds/">ffmpeg</a> - download and extract ffmpeg.exe and put it in the same directory as the bat script (or put ffmpeg.exe in PATH environment variable)
|
||||
.card
|
||||
.card-header
|
||||
p.card-header-title
|
||||
@@ -15,8 +30,36 @@ div
|
||||
i.mdi.mdi-check
|
||||
span Update
|
||||
.field
|
||||
textarea(style="width: 100%; height: 100%; background: #4a4a4a; color: #ffffff; border-radius: 6px; padding: 5px; font-size: 15px" rows="50" id="logtextarea" name="logtextarea")
|
||||
textarea.log-field(rows="50" id="logtextarea" name="logtextarea" disabled)
|
||||
|
||||
script(src="https://requirejs.org/docs/release/2.3.5/minified/require.js")
|
||||
script(type="text/javascript" src="static/asset/js/updateResources.js")
|
||||
div(hidden id='sdvx-dir') !{sdvx_dir}
|
||||
style(type='text/css').
|
||||
.collapse {
|
||||
background-color: #4a4a4a;
|
||||
color: white;
|
||||
padding: 18px;
|
||||
width: 100%;
|
||||
border: none;
|
||||
text-align: left;
|
||||
outline: none;
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
.collapse:hover {
|
||||
background-color: #777;
|
||||
}
|
||||
|
||||
.collapsible-card {
|
||||
padding:15px;
|
||||
}
|
||||
|
||||
.log-field {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #4a4a4a;
|
||||
color: #ffffff;
|
||||
border-radius: 6px;
|
||||
padding: 5px;
|
||||
font-size: 15px;
|
||||
}
|
||||
@@ -2,7 +2,12 @@
|
||||
// data\graphics\ap_card -- appeal card
|
||||
// data\graphics\submonitor_bg -- subbg
|
||||
$(document).ready(async function() {
|
||||
let sdvxDir = document.getElementById("sdvx-dir").innerText
|
||||
$('.collapse').click(function(){
|
||||
console.log($('.collapsible-card').css('display'))
|
||||
if($('.collapsible-card').css('display') == 'none') {
|
||||
$('.collapsible-card').css('display', 'block')
|
||||
} else $('.collapsible-card').css('display', 'none')
|
||||
})
|
||||
$( "#updateResources" ).click(async function() {
|
||||
answer = confirm("Clicking OK would mean that you have already updated the datacode in your ea3-config.xml file. Would you like to proceed?");
|
||||
if (answer == true) {
|
||||
@@ -10,7 +15,16 @@ $(document).ready(async function() {
|
||||
document.getElementById("logtextarea").textContent = 'Running....\n'
|
||||
await emit("copyResourcesFromGame").then(
|
||||
function(response){
|
||||
document.getElementById("logtextarea").textContent += 'Done.\n\n\n'
|
||||
$.getJSON( "static/asset/logs/copyResourcesFromGame.json", function( data ) {
|
||||
if(data['errors'].length > 0) {
|
||||
document.getElementById("logtextarea").textContent += 'Errors: \n'
|
||||
$.each(data['errors'], function(key, val) {
|
||||
document.getElementById("logtextarea").textContent += "- " + val + '\n'
|
||||
})
|
||||
document.getElementById("logtextarea").textContent += '\n\n'
|
||||
}
|
||||
|
||||
if(data['nemsys'].length > 0) {
|
||||
document.getElementById("logtextarea").textContent += 'New nemsys: \n'
|
||||
$.each(data['nemsys'], function(key, val) {
|
||||
@@ -43,6 +57,14 @@ $(document).ready(async function() {
|
||||
document.getElementById("logtextarea").textContent += '\n\n'
|
||||
}
|
||||
|
||||
if(data['chatStamp'].length > 0) {
|
||||
document.getElementById("logtextarea").textContent += 'New chat stamps: \n'
|
||||
$.each(data['chatStamp'], function(key, val) {
|
||||
document.getElementById("logtextarea").textContent += "- " + val + '\n'
|
||||
})
|
||||
document.getElementById("logtextarea").textContent += '\n\n'
|
||||
}
|
||||
|
||||
if(data['versionSongs'].length > 0) {
|
||||
document.getElementById("logtextarea").textContent += 'New songs in latest data: \n'
|
||||
$.each(data['versionSongs'], function(key, val) {
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user