Small fixes

This commit is contained in:
Natsumi
2023-04-22 00:51:03 +12:00
parent 5fc38f4e65
commit 2be1a75fcb
3 changed files with 18 additions and 7 deletions

View File

@@ -505,7 +505,13 @@ namespace VRCX
return Encoding.ASCII.GetString((byte[])data); return Encoding.ASCII.GetString((byte[])data);
case RegistryValueKind.DWord: case RegistryValueKind.DWord:
return data; if (data.GetType() != typeof(long))
return data;
long.TryParse(data.ToString(), out var longValue);
var bytes = BitConverter.GetBytes(longValue);
var doubleValue = BitConverter.ToDouble(bytes, 0);
return doubleValue;
} }
} }

View File

@@ -1932,7 +1932,10 @@ speechSynthesis.getVoices();
*/ */
API.getUserFeedback = function (params) { API.getUserFeedback = function (params) {
return this.call(`users/${params.userId}/feedback`, { return this.call(`users/${params.userId}/feedback`, {
method: 'GET' method: 'GET',
params: {
n: 100
}
}).then((json) => { }).then((json) => {
var args = { var args = {
json, json,
@@ -11468,7 +11471,6 @@ speechSynthesis.getVoices();
$app.methods.updateNowPlaying = function () { $app.methods.updateNowPlaying = function () {
var np = this.nowPlaying; var np = this.nowPlaying;
if (!this.nowPlaying.playing) { if (!this.nowPlaying.playing) {
this.nowPlaying.playing = false;
return; return;
} }
var now = Date.now() / 1000; var now = Date.now() / 1000;
@@ -15397,6 +15399,7 @@ speechSynthesis.getVoices();
users.push({ users.push({
ref, ref,
timer: ref.$location_at, timer: ref.$location_at,
$trustSortNum: ref.$trustSortNum ? ref.$trustSortNum : 0,
photonId, photonId,
isMaster, isMaster,
inVRMode, inVRMode,
@@ -17869,7 +17872,7 @@ speechSynthesis.getVoices();
)}`; )}`;
}; };
$app.methods.launchGame = function (location, shortName) { $app.methods.launchGame = function (location, shortName, desktopMode) {
var D = this.launchDialog; var D = this.launchDialog;
var args = []; var args = [];
if (shortName) { if (shortName) {
@@ -17881,7 +17884,7 @@ speechSynthesis.getVoices();
if (launchArguments) { if (launchArguments) {
args.push(launchArguments); args.push(launchArguments);
} }
if (D.desktop) { if (desktopMode) {
args.push('--no-vr'); args.push('--no-vr');
} }
if (vrcLaunchPathOverride) { if (vrcLaunchPathOverride) {
@@ -20861,6 +20864,7 @@ speechSynthesis.getVoices();
return; return;
} }
var lastLocation = this.lastLocation.location; var lastLocation = this.lastLocation.location;
var desktopMode = this.isGameNoVR;
AppApi.VrcClosedGracefully().then((result) => { AppApi.VrcClosedGracefully().then((result) => {
if (result || !this.isRealInstance(lastLocation)) { if (result || !this.isRealInstance(lastLocation)) {
return; return;
@@ -20879,7 +20883,7 @@ speechSynthesis.getVoices();
database.addGamelogEventToDatabase(entry); database.addGamelogEventToDatabase(entry);
this.queueGameLogNoty(entry); this.queueGameLogNoty(entry);
this.addGameLog(entry); this.addGameLog(entry);
this.launchGame(lastLocation); this.launchGame(lastLocation, '', desktopMode);
}); });
}; };

View File

@@ -2431,6 +2431,7 @@ html
template(v-for="(role, rIndex) in groupDialog.memberRoles" :key="rIndex") template(v-for="(role, rIndex) in groupDialog.memberRoles" :key="rIndex")
el-tooltip(placement="top") el-tooltip(placement="top")
template(#content) template(#content)
span {{ $t('dialog.group.info.role') }} {{ role.name }}
span {{ $t('dialog.group.info.role_description') }} {{ role.description }} span {{ $t('dialog.group.info.role_description') }} {{ role.description }}
br br
span(v-if="role.updatedAt") {{ $t('dialog.group.info.role_updated_at') }} {{ role.updatedAt | formatDate('long') }} span(v-if="role.updatedAt") {{ $t('dialog.group.info.role_updated_at') }} {{ role.updatedAt | formatDate('long') }}
@@ -2812,7 +2813,7 @@ html
el-checkbox(v-model="launchDialog.desktop" style="float:left;margin-top:5px") {{ $t('dialog.launch.start_as_desktop') }} el-checkbox(v-model="launchDialog.desktop" style="float:left;margin-top:5px") {{ $t('dialog.launch.start_as_desktop') }}
el-button(size="small" @click="showPreviousInstanceInfoDialog(launchDialog.location)") {{ $t('dialog.launch.info') }} el-button(size="small" @click="showPreviousInstanceInfoDialog(launchDialog.location)") {{ $t('dialog.launch.info') }}
el-button(size="small" @click="showInviteDialog(launchDialog.location)" :disabled="!checkCanInvite(launchDialog.location)") {{ $t('dialog.launch.invite') }} el-button(size="small" @click="showInviteDialog(launchDialog.location)" :disabled="!checkCanInvite(launchDialog.location)") {{ $t('dialog.launch.invite') }}
el-button(type="primary" size="small" @click="launchGame(launchDialog.location, launchDialog.secureOrShortName)" :disabled="!launchDialog.secureOrShortName") {{ $t('dialog.launch.launch') }} el-button(type="primary" size="small" @click="launchGame(launchDialog.location, launchDialog.secureOrShortName, launchDialog.desktop)" :disabled="!launchDialog.secureOrShortName") {{ $t('dialog.launch.launch') }}
//- dialog: export friends list //- dialog: export friends list
el-dialog.x-dialog(:before-close="beforeDialogClose" @mousedown.native="dialogMouseDown" @mouseup.native="dialogMouseUp" :visible.sync="exportFriendsListDialog" :title="$t('dialog.export_friends_list.header')" width="650px") el-dialog.x-dialog(:before-close="beforeDialogClose" @mousedown.native="dialogMouseDown" @mouseup.native="dialogMouseUp" :visible.sync="exportFriendsListDialog" :title="$t('dialog.export_friends_list.header')" width="650px")