Fixes and additions for first chapter of bridal gears.

This commit is contained in:
fire bingo 2018-06-05 21:14:02 -07:00
parent e58002ce4c
commit e25cd1f929
6 changed files with 43 additions and 13 deletions

View File

@ -90,7 +90,7 @@ class audioController {
if(!this.loader.bufferList[sound]) { if(!this.loader.bufferList[sound]) {
return; return;
} }
let source = this.audioCtx.createBufferSource() let source = this.audioCtx.createBufferSource();
this.sources[sound] = source; this.sources[sound] = source;
source.buffer = this.loader.bufferList[sound]; source.buffer = this.loader.bufferList[sound];
source.loop = false; source.loop = false;

View File

@ -269,7 +269,10 @@ function languageChanged(event) {
if(currentMission) { if(currentMission) {
missionPath = `${utage.rootDirectory}Js/Translations/Missions/${currentMission.Path.replace('Asset/Utage/', '').replace('Scenario/', '').replace('.utage', '').replace('.tsv', `_translations_${selectedLang}.json`)}`; missionPath = `${utage.rootDirectory}Js/Translations/Missions/${currentMission.Path.replace('Asset/Utage/', '').replace('Scenario/', '').replace('.utage', '').replace('.tsv', `_translations_${selectedLang}.json`)}`;
} }
utage.setTranslationLanguage(selectedLang, missionPath); utage.setTranslationLanguage(selectedLang, missionPath)
.then((success) => {
buildMissionSelectList();
});
} }
function checkMissionList(missions, currentvalue) { function checkMissionList(missions, currentvalue) {

View File

@ -680,18 +680,31 @@ class Player {
this.checkPutCharacterScreen(cur, true); this.checkPutCharacterScreen(cur, true);
break; break;
case "attachit02": //103500221 case "attachit02": //103500221
this.waitTime = 300;
break; break;
case "attachit03": case "attachit03": //312000112
this.waitTime = 300;
break; break;
case "attacshot12": //103500231 case "attacshot12": //103500231
this.waitTime = 300;
break; break;
case "attacslash01": //103500642 case "attacslash01": //103500642
this.waitTime = 300;
break; break;
case "attacslash02": //103500231 case "attacslash02": //103500231
this.waitTime = 300;
break;
case "attacslash03": //312000112
this.waitTime = 300;
break;
case "attacslash04": //312000142
this.waitTime = 300;
break; break;
case "attacslash05": //103500552 case "attacslash05": //103500552
this.waitTime = 300;
break; break;
case "attacshot11": //103500251 case "attacshot11": //103500251
this.waitTime = 300;
break; break;
case "getitem01": //103400252 case "getitem01": //103400252
break; break;
@ -764,16 +777,26 @@ class Player {
this.waitTime = Number(cur.Arg1) * 1000; this.waitTime = Number(cur.Arg1) * 1000;
break; break;
case "enemy_disappearance01": //312000112 case "enemy_disappearance01": //312000112
processTryRemoveChar(cur.Arg1);
break;
case "enemy_disappearance02": //312000111 case "enemy_disappearance02": //312000111
processTryRemoveChar(cur.Arg1); case "enemy_disappearance03": //312000142
processTryRemoveChar(cur.Arg2); this.processTryRemoveChar(cur.Arg1);
if(cur.Arg2) {
this.processTryRemoveChar(cur.Arg2);
}
if(cur.Arg3) {
this.processTryRemoveChar(cur.Arg3);
}
break; break;
case "darkaura01": //312000111 case "darkaura01": //312000111
break; break;
case "somethingnew_appearance01": //312000111 case "somethingnew_appearance01": { //312000111
let c = this.currentCharacters['キャラ中央'];
this.waitTime = 1500;
this.lerpTargets.push({type: 'alpha', object: c.sprite, curTime: 0, time: 200, finalV: 0, initV: 1, post: "destroy" });
let customCommand = { Command: "", Arg1: cur.Arg1, Arg2: this.defaultCharPattern, Arg3: 'キャラ中央', Arg6: .200 };
this.checkPutCharacterScreen(customCommand, false);
break; break;
}
case "continue01": case "continue01":
break; break;
} }
@ -901,7 +924,7 @@ class Player {
sprite.alpha = 0; sprite.alpha = 0;
let fadeTime = 200; let fadeTime = 200;
//If the character is already on screen put the new sprite in the same position as the old one. //If the character is already on screen put the new sprite in the same position as the old one.
if(curChar) { if(curChar && curChar.layer.info.LayerName === cur.Arg3) {
sprite.position.x = curChar.sprite.position.x; sprite.position.x = curChar.sprite.position.x;
sprite.position.y = curChar.sprite.position.y; sprite.position.y = curChar.sprite.position.y;
//if the current character is doing a tween transfer the tween to the new one. //if the current character is doing a tween transfer the tween to the new one.
@ -967,9 +990,12 @@ class Player {
curChar = this.currentCharacters[c]; curChar = this.currentCharacters[c];
} }
} }
if(!curChar) if(!curChar) {
return; return;
} }
this.lerpTargets.push({type: 'alpha', object: curChar.sprite, curTime: 0, time: 500, finalV: 0, initV: 1, post: "destroy" });
this.currentCharacters[curChar.layer.info.LayerName] = undefined;
}
//Checks if the current command is trying to put text on the screen. //Checks if the current command is trying to put text on the screen.
checkPutText(cur) { checkPutText(cur) {

View File

@ -88,6 +88,7 @@ class TextFunctions {
if (this.dialogToDisplay.curPos === this.dialogToDisplay.text.length) { if (this.dialogToDisplay.curPos === this.dialogToDisplay.text.length) {
this.showNextIndicator(true); this.showNextIndicator(true);
this.scrollingText = false; this.scrollingText = false;
this.dialog.scrollTop = 0;
return; return;
} else { } else {
this.dialogToDisplay.curPos += 1; this.dialogToDisplay.curPos += 1;
@ -113,7 +114,7 @@ class TextFunctions {
this.dialogInner.innerHTML = this.dialogToDisplay.fullText; this.dialogInner.innerHTML = this.dialogToDisplay.fullText;
let lHeight = this.lineHeight * 2; let lHeight = this.lineHeight * 2;
if(this.dialogInner.offsetHeight > lHeight + 5) { if(this.dialogInner.offsetHeight > lHeight + 5) {
this.dialog.scrollTop = this.dialogInner.offsetHeight - lHeight; this.dialog.scrollTop = 0//this.dialogInner.offsetHeight - lHeight;
this.showScrollControls(true); this.showScrollControls(true);
} }
this.showNextIndicator(true); this.showNextIndicator(true);

@ -1 +1 @@
Subproject commit 5687378f81f332e32668763f04335f3883f35e4e Subproject commit 54cfee17b22e9dedf8d92409abd1b2bf4222ed82

View File

@ -183,7 +183,7 @@ class UtageInfo {
resolve(); resolve();
} else { } else {
var promises = [ var promises = [
commonFunctions.getFileJson(`${utage.rootDirectory}Js/Translations/XduMissionsNamesCustom_${this.currentTranslation}.json`), commonFunctions.getFileJson(`${utage.rootDirectory}Js/Translations/XduMissionsNames_${this.currentTranslation}.json`),
commonFunctions.getFileJson(`${utage.rootDirectory}Js/Translations/XduMissionsNamesCustom_${this.currentTranslation}.json`) commonFunctions.getFileJson(`${utage.rootDirectory}Js/Translations/XduMissionsNamesCustom_${this.currentTranslation}.json`)
]; ];
Promise.all(promises) Promise.all(promises)