mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-18 22:33:50 +02:00
Disable GameLog toggle
This commit is contained in:
@@ -1005,6 +1005,10 @@ speechSynthesis.getVoices();
|
||||
API.$on('USER:CURRENT', function (args) {
|
||||
var {json} = args;
|
||||
args.ref = this.applyCurrentUser(json);
|
||||
var location = $app.lastLocation.location;
|
||||
if ($app.gameLogDisabled) {
|
||||
location = json.location;
|
||||
}
|
||||
this.applyUser({
|
||||
id: json.id,
|
||||
username: json.username,
|
||||
@@ -1026,7 +1030,7 @@ speechSynthesis.getVoices();
|
||||
fallbackAvatar: json.fallbackAvatar,
|
||||
profilePicOverride: json.profilePicOverride,
|
||||
isFriend: false,
|
||||
location: $app.lastLocation.location
|
||||
location
|
||||
});
|
||||
});
|
||||
|
||||
@@ -1355,6 +1359,12 @@ speechSynthesis.getVoices();
|
||||
) {
|
||||
json.location = '';
|
||||
}
|
||||
if (
|
||||
typeof json.location === 'undefined' &&
|
||||
typeof ref !== 'undefined'
|
||||
) {
|
||||
json.location = ref.location;
|
||||
}
|
||||
if ($app.lastLocation.location) {
|
||||
json.location = $app.lastLocation.location;
|
||||
json.$location_at = $app.lastLocation.date;
|
||||
@@ -7950,6 +7960,9 @@ speechSynthesis.getVoices();
|
||||
$app.data.lastVideoUrl = '';
|
||||
|
||||
$app.methods.addGameLogEntry = function (gameLog, location) {
|
||||
if (this.gameLogDisabled) {
|
||||
return;
|
||||
}
|
||||
var userId = '';
|
||||
if (gameLog.userDisplayName) {
|
||||
for (var ref of API.cachedUsers.values()) {
|
||||
@@ -11498,6 +11511,9 @@ speechSynthesis.getVoices();
|
||||
$app.data.photonLoggingEnabled = configRepository.getBool(
|
||||
'VRCX_photonLoggingEnabled'
|
||||
);
|
||||
$app.data.gameLogDisabled = configRepository.getBool(
|
||||
'VRCX_gameLogDisabled'
|
||||
);
|
||||
$app.methods.saveEventOverlay = function () {
|
||||
configRepository.setBool(
|
||||
'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);
|
||||
window.$app = $app;
|
||||
})();
|
||||
|
||||
@@ -1217,6 +1217,10 @@ html
|
||||
span.name Avatar cache: #[span(v-text="API.cachedAvatars.size")]
|
||||
div.options-container-item
|
||||
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
|
||||
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
|
||||
|
||||
Reference in New Issue
Block a user