Add world name to online event if instance isn't private

This commit is contained in:
Natsumi
2021-10-18 01:14:45 +13:00
parent 48ef9457a9
commit 5a7d02cc94
3 changed files with 42 additions and 10 deletions

View File

@@ -4883,7 +4883,14 @@ speechSynthesis.getVoices();
);
break;
case 'Online':
this.speak(`${noty.displayName} has logged in`);
var locationName = '';
if (noty.worldName) {
locationName = ` to ${this.displayLocation(
noty.location,
noty.worldName
)}`;
}
this.speak(`${noty.displayName} has logged in${locationName}`);
break;
case 'Offline':
this.speak(`${noty.displayName} has logged out`);
@@ -5016,9 +5023,16 @@ speechSynthesis.getVoices();
);
break;
case 'Online':
var locationName = '';
if (noty.worldName) {
locationName = ` to ${this.displayLocation(
noty.location,
noty.worldName
)}`;
}
AppApi.XSNotification(
'VRCX',
`${noty.displayName} has logged in`,
`${noty.displayName} has logged in${locationName}`,
timeout,
image
);
@@ -5215,9 +5229,16 @@ speechSynthesis.getVoices();
);
break;
case 'Online':
var locationName = '';
if (noty.worldName) {
locationName = ` to ${this.displayLocation(
noty.location,
noty.worldName
)}`;
}
AppApi.DesktopNotification(
noty.displayName,
'has logged in',
`has logged in${locationName}`,
image
);
break;