diff --git a/html/src/app.js b/html/src/app.js index a442b107..7ba6895b 100644 --- a/html/src/app.js +++ b/html/src/app.js @@ -4332,8 +4332,9 @@ speechSynthesis.getVoices(); return; } if (noty.type === 'VideoPlay') { - if (!noty.videoName) { - // skip videos without names + if (!noty.videoName || noty.videoUrl === this.nowPlaying.url) { + // skip video without name + // skip video already playing return; } noty.notyName = noty.videoName; @@ -7112,7 +7113,7 @@ speechSynthesis.getVoices(); userId: ref.userId, time }; - this.addGameLog(entry); + $app.addGameLog(entry); database.addGamelogJoinLeaveToDatabase(entry); } if (this.lastLocation.date !== 0) { @@ -7620,15 +7621,11 @@ speechSynthesis.getVoices(); }; $app.methods.setNowPlaying = function (ctx) { - var videoId = ''; var displayName = ''; - if (ctx.videoId) { - videoId = `${ctx.videoId} : `; - } if (ctx.displayName) { displayName = ` (${ctx.displayName})`; } - var name = `${videoId}${ctx.videoName}${displayName} ‎`; + var name = `${ctx.videoName}${displayName}`; this.nowPlaying = { url: ctx.videoUrl, name, @@ -7786,10 +7783,20 @@ speechSynthesis.getVoices(); } var appId = '883308884863901717'; var bigIcon = 'vrchat'; - if (L.worldId === 'wrld_f20326da-f1ac-45fc-a062-609723b097b1') { + if ( + L.worldId === 'wrld_f20326da-f1ac-45fc-a062-609723b097b1' || + L.worldId === 'wrld_42377cf1-c54f-45ed-8996-5875b0573a83' + ) { + if (L.worldId === 'wrld_f20326da-f1ac-45fc-a062-609723b097b1') { + appId = '784094509008551956'; + bigIcon = 'pypy'; + } else if ( + L.worldId === 'wrld_42377cf1-c54f-45ed-8996-5875b0573a83' + ) { + appId = '846232616054030376'; + bigIcon = 'vr_dancing'; + } L.worldName = this.nowPlaying.name; - appId = '784094509008551956'; - bigIcon = 'pypy'; Discord.SetTimestamps( Date.now(), (this.nowPlaying.startTime + this.nowPlaying.length) * 1000 @@ -9440,6 +9447,7 @@ speechSynthesis.getVoices(); $app.methods.vrInit = function () { this.updateVRConfigVars(); this.updateVRLastLocation(); + this.updateVrNowPlaying(); this.updateSharedFeed(true); }; diff --git a/html/src/index.pug b/html/src/index.pug index 1b723c79..deb376ce 100644 --- a/html/src/index.pug +++ b/html/src/index.pug @@ -173,6 +173,7 @@ html span(v-else-if="scope.row.status === 'busy'") Do Not Disturb span(v-else) Offline i.x-user-status(:class="statusClass(scope.row.status)") + span ‎ span(v-text="scope.row.statusDescription") template(v-else-if="scope.row.type === 'Avatar'") avatar-info(:imageurl="scope.row.currentAvatarImageUrl" :userid="scope.row.userId" :hintownerid="scope.row.ownerId" :hintavatarname="scope.row.avatarName") diff --git a/html/src/vr.pug b/html/src/vr.pug index 96bd5394..ee69bd60 100644 --- a/html/src/vr.pug +++ b/html/src/vr.pug @@ -349,9 +349,10 @@ html br span {{ device[2] }}% .x-containerbottom - span(style="float:right;padding-left:10px") {{ nowPlaying.remainingText }} - marquee-text {{ nowPlaying.name }} - div.np-progress-bar(:style="{ width: nowPlaying.percentage + '%' }") + template(v-if="nowPlaying.playing") + span(style="float:right;padding-left:10px") {{ nowPlaying.remainingText }} + marquee-text {{ nowPlaying.name }} ‎ + div.np-progress-bar(:style="{ width: nowPlaying.percentage + '%' }") template(v-if="config && config.minimalFeed") template(v-if="config.downloadProgress === 100") span(style="display:inline-block;margin-right:5px") #[i.el-icon-loading]