mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-05-07 14:56:06 +02:00
Disable GameLog toggle
This commit is contained in:
+42
-1
@@ -1005,6 +1005,10 @@ speechSynthesis.getVoices();
|
|||||||
API.$on('USER:CURRENT', function (args) {
|
API.$on('USER:CURRENT', function (args) {
|
||||||
var {json} = args;
|
var {json} = args;
|
||||||
args.ref = this.applyCurrentUser(json);
|
args.ref = this.applyCurrentUser(json);
|
||||||
|
var location = $app.lastLocation.location;
|
||||||
|
if ($app.gameLogDisabled) {
|
||||||
|
location = json.location;
|
||||||
|
}
|
||||||
this.applyUser({
|
this.applyUser({
|
||||||
id: json.id,
|
id: json.id,
|
||||||
username: json.username,
|
username: json.username,
|
||||||
@@ -1026,7 +1030,7 @@ speechSynthesis.getVoices();
|
|||||||
fallbackAvatar: json.fallbackAvatar,
|
fallbackAvatar: json.fallbackAvatar,
|
||||||
profilePicOverride: json.profilePicOverride,
|
profilePicOverride: json.profilePicOverride,
|
||||||
isFriend: false,
|
isFriend: false,
|
||||||
location: $app.lastLocation.location
|
location
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -1355,6 +1359,12 @@ speechSynthesis.getVoices();
|
|||||||
) {
|
) {
|
||||||
json.location = '';
|
json.location = '';
|
||||||
}
|
}
|
||||||
|
if (
|
||||||
|
typeof json.location === 'undefined' &&
|
||||||
|
typeof ref !== 'undefined'
|
||||||
|
) {
|
||||||
|
json.location = ref.location;
|
||||||
|
}
|
||||||
if ($app.lastLocation.location) {
|
if ($app.lastLocation.location) {
|
||||||
json.location = $app.lastLocation.location;
|
json.location = $app.lastLocation.location;
|
||||||
json.$location_at = $app.lastLocation.date;
|
json.$location_at = $app.lastLocation.date;
|
||||||
@@ -7950,6 +7960,9 @@ speechSynthesis.getVoices();
|
|||||||
$app.data.lastVideoUrl = '';
|
$app.data.lastVideoUrl = '';
|
||||||
|
|
||||||
$app.methods.addGameLogEntry = function (gameLog, location) {
|
$app.methods.addGameLogEntry = function (gameLog, location) {
|
||||||
|
if (this.gameLogDisabled) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
var userId = '';
|
var userId = '';
|
||||||
if (gameLog.userDisplayName) {
|
if (gameLog.userDisplayName) {
|
||||||
for (var ref of API.cachedUsers.values()) {
|
for (var ref of API.cachedUsers.values()) {
|
||||||
@@ -11498,6 +11511,9 @@ speechSynthesis.getVoices();
|
|||||||
$app.data.photonLoggingEnabled = configRepository.getBool(
|
$app.data.photonLoggingEnabled = configRepository.getBool(
|
||||||
'VRCX_photonLoggingEnabled'
|
'VRCX_photonLoggingEnabled'
|
||||||
);
|
);
|
||||||
|
$app.data.gameLogDisabled = configRepository.getBool(
|
||||||
|
'VRCX_gameLogDisabled'
|
||||||
|
);
|
||||||
$app.methods.saveEventOverlay = function () {
|
$app.methods.saveEventOverlay = function () {
|
||||||
configRepository.setBool(
|
configRepository.setBool(
|
||||||
'VRCX_PhotonEventOverlay',
|
'VRCX_PhotonEventOverlay',
|
||||||
@@ -19018,6 +19034,31 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
$app.methods.disableGameLogDialog = function () {
|
||||||
|
if (this.isGameRunning) {
|
||||||
|
this.$message({
|
||||||
|
message:
|
||||||
|
'VRChat needs to be closed before this option can be changed',
|
||||||
|
type: 'error'
|
||||||
|
});
|
||||||
|
this.gameLogDisabled = !this.gameLogDisabled;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (this.gameLogDisabled) {
|
||||||
|
this.$confirm('Continue? Disable GameLog', 'Confirm', {
|
||||||
|
confirmButtonText: 'Confirm',
|
||||||
|
cancelButtonText: 'Cancel',
|
||||||
|
type: 'info',
|
||||||
|
callback: (action) => {
|
||||||
|
if (action !== 'confirm') {
|
||||||
|
this.gameLogDisabled = !this.gameLogDisabled;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
configRepository.setBool('VRCX_gameLogDisabled', this.gameLogDisabled);
|
||||||
|
};
|
||||||
|
|
||||||
$app = new Vue($app);
|
$app = new Vue($app);
|
||||||
window.$app = $app;
|
window.$app = $app;
|
||||||
})();
|
})();
|
||||||
|
|||||||
@@ -1217,6 +1217,10 @@ html
|
|||||||
span.name Avatar cache: #[span(v-text="API.cachedAvatars.size")]
|
span.name Avatar cache: #[span(v-text="API.cachedAvatars.size")]
|
||||||
div.options-container-item
|
div.options-container-item
|
||||||
span.name Avatar Name cache: #[span(v-text="API.cachedAvatarNames.size")]
|
span.name Avatar Name cache: #[span(v-text="API.cachedAvatarNames.size")]
|
||||||
|
div.options-container-item
|
||||||
|
span.name Disable GameLog
|
||||||
|
el-switch(v-model="gameLogDisabled" @change="disableGameLogDialog")
|
||||||
|
span.name(style="margin-left:15px") (will likely break things)
|
||||||
div.options-container-item
|
div.options-container-item
|
||||||
el-button(size="small" icon="el-icon-delete-solid" @click="clearVRCXCache") Clear Cache
|
el-button(size="small" icon="el-icon-delete-solid" @click="clearVRCXCache") Clear Cache
|
||||||
el-button(size="small" icon="el-icon-time" @click="promptAutoClearVRCXCacheFrequency") Auto Clear Cache
|
el-button(size="small" icon="el-icon-time" @click="promptAutoClearVRCXCacheFrequency") Auto Clear Cache
|
||||||
|
|||||||
Reference in New Issue
Block a user