Remove debug and change version to release

This commit is contained in:
OleSTEEP 2024-03-09 01:16:17 +03:00
parent f9e80edb2a
commit 9b5d4caf05
9 changed files with 1 additions and 43 deletions

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?> <?xml version='1.0' encoding='utf-8'?>
<widget id="su.viende.omori" version="1.0.8-dev" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0" xmlns:android="http://schemas.android.com/apk/res/android"> <widget id="su.viende.omori" version="1.0.8.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
<preference name="orientation" value="sensorLandscape" /> <preference name="orientation" value="sensorLandscape" />
<preference name="Fullscreen" value="true" /> <preference name="Fullscreen" value="true" />

View file

@ -10,20 +10,17 @@ var currentBgs = null;
document.addEventListener("deviceready", onCordovaDeviceReady, false); document.addEventListener("deviceready", onCordovaDeviceReady, false);
function onCordovaDeviceReady() { function onCordovaDeviceReady() {
console.log("AudioManager - SETUP!!!"); //Remove in release
document.addEventListener("pause", onCordovaPause, false); document.addEventListener("pause", onCordovaPause, false);
document.addEventListener("resume", onCordovaResume, false); document.addEventListener("resume", onCordovaResume, false);
}; };
function onCordovaPause() { function onCordovaPause() {
console.log("AudioManager - HIDE!!!"); //Remove in release
currentBgm = AudioManager.saveBgm(); currentBgm = AudioManager.saveBgm();
currentBgs = AudioManager.saveBgs(); currentBgs = AudioManager.saveBgs();
AudioManager.stopAll(); AudioManager.stopAll();
}; };
function onCordovaResume() { function onCordovaResume() {
console.log("AudioManager - SHOW!!!"); //Remove in release
try { try {
AudioManager.replayBgm(currentBgm); AudioManager.replayBgm(currentBgm);
AudioManager.replayBgs(currentBgs); AudioManager.replayBgs(currentBgs);
@ -56,18 +53,15 @@ WebAudio.prototype._setupEventHandlers = function () {
}; };
WebAudio.prototype._onCordovaDeviceReady = function () { WebAudio.prototype._onCordovaDeviceReady = function () {
console.log("WebAudio - SETUP!!!"); //Remove in release
document.addEventListener("pause", this._onCordovaPause.bind(this), false); document.addEventListener("pause", this._onCordovaPause.bind(this), false);
document.addEventListener("resume", this._onCordovaResume.bind(this), false); document.addEventListener("resume", this._onCordovaResume.bind(this), false);
}; };
WebAudio.prototype._onCordovaPause = function () { WebAudio.prototype._onCordovaPause = function () {
console.log("WebAudio - HIDE!!!"); //Remove in release
this._onHide(); this._onHide();
}; };
WebAudio.prototype._onCordovaResume = function () { WebAudio.prototype._onCordovaResume = function () {
console.log("WebAudio - SHOW!!!"); //Remove in release
this._onShow(); this._onShow();
}; };
@ -81,18 +75,15 @@ Html5Audio.prototype._setupEventHandlers = function () {
}; };
Html5Audio.prototype._onCordovaDeviceReady = function () { Html5Audio.prototype._onCordovaDeviceReady = function () {
console.log("Html5Audio - SETUP!!!"); //Remove in release
this._audioElement.addEventListener("pause", this._onCordovaPause.bind(this), false); this._audioElement.addEventListener("pause", this._onCordovaPause.bind(this), false);
this._audioElement.addEventListener("resume", this._onCordovaResume.bind(this), false); this._audioElement.addEventListener("resume", this._onCordovaResume.bind(this), false);
}; };
Html5Audio.prototype._onCordovaPause = function () { Html5Audio.prototype._onCordovaPause = function () {
console.log("Html5Audio - HIDE!!!"); //Remove in release
this._onHide(); this._onHide();
}; };
Html5Audio.prototype._onCordovaResume = function () { Html5Audio.prototype._onCordovaResume = function () {
console.log("Html5Audio - SHOW!!!"); //Remove in release
this._onShow(); this._onShow();
}; };
@ -120,18 +111,15 @@ StreamWebAudio.prototype._setupEventHandlers = function() {
}; };
StreamWebAudio.prototype._onCordovaDeviceReady = function () { StreamWebAudio.prototype._onCordovaDeviceReady = function () {
console.log("StreamWebAudio - SETUP!!!"); //Remove in release
document.addEventListener("pause", this._onCordovaPause.bind(this), false); document.addEventListener("pause", this._onCordovaPause.bind(this), false);
document.addEventListener("resume", this._onCordovaResume.bind(this), false); document.addEventListener("resume", this._onCordovaResume.bind(this), false);
}; };
StreamWebAudio.prototype._onCordovaPause = function () { StreamWebAudio.prototype._onCordovaPause = function () {
console.log("StreamWebAudio - HIDE!!!"); //Remove in release
this._onHide(); this._onHide();
}; };
StreamWebAudio.prototype._onCordovaResume = function () { StreamWebAudio.prototype._onCordovaResume = function () {
console.log("StreamWebAudio - SHOW!!!"); //Remove in release
this._onShow(); this._onShow();
}; };

View file

@ -194,9 +194,6 @@ ONSControls.resetIdleAnimation = function() {
//============================================================================= //=============================================================================
ONSControls.sendEvent = function(event, button) { ONSControls.sendEvent = function(event, button) {
const key = VirtualGamepad.keys.find((element) => element.name == button); const key = VirtualGamepad.keys.find((element) => element.name == button);
if (event.type === "pointerdown") {
console.log(`ONSControls: Pointer down for ${button}`); // Remove in release
}
VirtualGamepad.gamepad.buttons[key.code].pressed = event.type === "pointerdown" ? true : false VirtualGamepad.gamepad.buttons[key.code].pressed = event.type === "pointerdown" ? true : false
} }
//============================================================================= //=============================================================================

View file

@ -241,13 +241,10 @@ require.libs.fs = {
for (const listingFile of listing) { for (const listingFile of listing) {
if (listingFile.toLowerCase() == basename.toLowerCase()) { if (listingFile.toLowerCase() == basename.toLowerCase()) {
const alt = require.libs.path.join(dirname, listingFile); const alt = require.libs.path.join(dirname, listingFile);
console.log(`tried to access ${path}: not found, found alternative: ${alt}`) //Remove in release
return alt; return alt;
} }
} }
console.log(`tried to access ${path}: not found, alternative name was not found too!`) //Remove in release
return null; return null;
}, },

View file

@ -8,17 +8,14 @@ window.PERSISTENT_IMPLEMENTATIONS = {
function localStorageImplementation() { function localStorageImplementation() {
return { return {
readSaveFileUTF8(path) { readSaveFileUTF8(path) {
console.log(`Failed to get externalStorage. Using localStorage to read save at ${path}`);
return localStorage.getItem(path); return localStorage.getItem(path);
}, },
saveFileExists(path) { saveFileExists(path) {
console.log(`Using localStorage while checking save file ${path} existence`);
return localStorage.getItem(path) != null; return localStorage.getItem(path) != null;
}, },
writeSaveFileUTF8(path, data) { writeSaveFileUTF8(path, data) {
console.log(`Failed to get externalStorage. Writing ${path} save file to the localStorage`);
localStorage.setItem(path, data); localStorage.setItem(path, data);
} }
}; };

View file

@ -10,20 +10,17 @@ var currentBgs = null;
document.addEventListener("deviceready", onCordovaDeviceReady, false); document.addEventListener("deviceready", onCordovaDeviceReady, false);
function onCordovaDeviceReady() { function onCordovaDeviceReady() {
console.log("AudioManager - SETUP!!!"); //Remove in release
document.addEventListener("pause", onCordovaPause, false); document.addEventListener("pause", onCordovaPause, false);
document.addEventListener("resume", onCordovaResume, false); document.addEventListener("resume", onCordovaResume, false);
}; };
function onCordovaPause() { function onCordovaPause() {
console.log("AudioManager - HIDE!!!"); //Remove in release
currentBgm = AudioManager.saveBgm(); currentBgm = AudioManager.saveBgm();
currentBgs = AudioManager.saveBgs(); currentBgs = AudioManager.saveBgs();
AudioManager.stopAll(); AudioManager.stopAll();
}; };
function onCordovaResume() { function onCordovaResume() {
console.log("AudioManager - SHOW!!!"); //Remove in release
try { try {
AudioManager.replayBgm(currentBgm); AudioManager.replayBgm(currentBgm);
AudioManager.replayBgs(currentBgs); AudioManager.replayBgs(currentBgs);
@ -56,18 +53,15 @@ WebAudio.prototype._setupEventHandlers = function () {
}; };
WebAudio.prototype._onCordovaDeviceReady = function () { WebAudio.prototype._onCordovaDeviceReady = function () {
console.log("WebAudio - SETUP!!!"); //Remove in release
document.addEventListener("pause", this._onCordovaPause.bind(this), false); document.addEventListener("pause", this._onCordovaPause.bind(this), false);
document.addEventListener("resume", this._onCordovaResume.bind(this), false); document.addEventListener("resume", this._onCordovaResume.bind(this), false);
}; };
WebAudio.prototype._onCordovaPause = function () { WebAudio.prototype._onCordovaPause = function () {
console.log("WebAudio - HIDE!!!"); //Remove in release
this._onHide(); this._onHide();
}; };
WebAudio.prototype._onCordovaResume = function () { WebAudio.prototype._onCordovaResume = function () {
console.log("WebAudio - SHOW!!!"); //Remove in release
this._onShow(); this._onShow();
}; };
@ -81,18 +75,15 @@ Html5Audio.prototype._setupEventHandlers = function () {
}; };
Html5Audio.prototype._onCordovaDeviceReady = function () { Html5Audio.prototype._onCordovaDeviceReady = function () {
console.log("Html5Audio - SETUP!!!"); //Remove in release
this._audioElement.addEventListener("pause", this._onCordovaPause.bind(this), false); this._audioElement.addEventListener("pause", this._onCordovaPause.bind(this), false);
this._audioElement.addEventListener("resume", this._onCordovaResume.bind(this), false); this._audioElement.addEventListener("resume", this._onCordovaResume.bind(this), false);
}; };
Html5Audio.prototype._onCordovaPause = function () { Html5Audio.prototype._onCordovaPause = function () {
console.log("Html5Audio - HIDE!!!"); //Remove in release
this._onHide(); this._onHide();
}; };
Html5Audio.prototype._onCordovaResume = function () { Html5Audio.prototype._onCordovaResume = function () {
console.log("Html5Audio - SHOW!!!"); //Remove in release
this._onShow(); this._onShow();
}; };
@ -120,18 +111,15 @@ StreamWebAudio.prototype._setupEventHandlers = function() {
}; };
StreamWebAudio.prototype._onCordovaDeviceReady = function () { StreamWebAudio.prototype._onCordovaDeviceReady = function () {
console.log("StreamWebAudio - SETUP!!!"); //Remove in release
document.addEventListener("pause", this._onCordovaPause.bind(this), false); document.addEventListener("pause", this._onCordovaPause.bind(this), false);
document.addEventListener("resume", this._onCordovaResume.bind(this), false); document.addEventListener("resume", this._onCordovaResume.bind(this), false);
}; };
StreamWebAudio.prototype._onCordovaPause = function () { StreamWebAudio.prototype._onCordovaPause = function () {
console.log("StreamWebAudio - HIDE!!!"); //Remove in release
this._onHide(); this._onHide();
}; };
StreamWebAudio.prototype._onCordovaResume = function () { StreamWebAudio.prototype._onCordovaResume = function () {
console.log("StreamWebAudio - SHOW!!!"); //Remove in release
this._onShow(); this._onShow();
}; };

View file

@ -194,9 +194,6 @@ ONSControls.resetIdleAnimation = function() {
//============================================================================= //=============================================================================
ONSControls.sendEvent = function(event, button) { ONSControls.sendEvent = function(event, button) {
const key = VirtualGamepad.keys.find((element) => element.name == button); const key = VirtualGamepad.keys.find((element) => element.name == button);
if (event.type === "pointerdown") {
console.log(`ONSControls: Pointer down for ${button}`); // Remove in release
}
VirtualGamepad.gamepad.buttons[key.code].pressed = event.type === "pointerdown" ? true : false VirtualGamepad.gamepad.buttons[key.code].pressed = event.type === "pointerdown" ? true : false
} }
//============================================================================= //=============================================================================

View file

@ -241,13 +241,10 @@ require.libs.fs = {
for (const listingFile of listing) { for (const listingFile of listing) {
if (listingFile.toLowerCase() == basename.toLowerCase()) { if (listingFile.toLowerCase() == basename.toLowerCase()) {
const alt = require.libs.path.join(dirname, listingFile); const alt = require.libs.path.join(dirname, listingFile);
console.log(`tried to access ${path}: not found, found alternative: ${alt}`) //Remove in release
return alt; return alt;
} }
} }
console.log(`tried to access ${path}: not found, alternative name was not found too!`) //Remove in release
return null; return null;
}, },

View file

@ -8,17 +8,14 @@ window.PERSISTENT_IMPLEMENTATIONS = {
function localStorageImplementation() { function localStorageImplementation() {
return { return {
readSaveFileUTF8(path) { readSaveFileUTF8(path) {
console.log(`Failed to get externalStorage. Using localStorage to read save at ${path}`);
return localStorage.getItem(path); return localStorage.getItem(path);
}, },
saveFileExists(path) { saveFileExists(path) {
console.log(`Using localStorage while checking save file ${path} existence`);
return localStorage.getItem(path) != null; return localStorage.getItem(path) != null;
}, },
writeSaveFileUTF8(path, data) { writeSaveFileUTF8(path, data) {
console.log(`Failed to get externalStorage. Writing ${path} save file to the localStorage`);
localStorage.setItem(path, data); localStorage.setItem(path, data);
} }
}; };