mirror of
https://gitgud.io/BondageProjects/Bondage-College.git
synced 2025-04-25 17:59:34 +00:00
Merge branch 'fix/player-not-online-update' into 'master'
HOTFIX: Fix a couple issues caused by IsOnline not working on players anymore See merge request BondageProjects/Bondage-College!5469
This commit is contained in:
commit
68763e99e8
3 changed files with 11 additions and 4 deletions
BondageClub
|
@ -297,7 +297,7 @@ function CharacterAppearanceNaked(C) {
|
|||
|
||||
// For each item group (non default items only show at a 20% rate)
|
||||
for (let A = C.Appearance.length - 1; A >= 0; A--)
|
||||
if (C.Appearance[A].Asset.Group.AllowNone && (C.Appearance[A].Asset.Group.Category == "Appearance") && (!C.IsOnline() || !(C.OnlineSharedSettings.BlockBodyCosplay && (C.Appearance[A].Asset != null) && (C.Appearance[A].Asset.Group != null) && C.Appearance[A].Asset.Group.BodyCosplay)))
|
||||
if (C.Appearance[A].Asset.Group.AllowNone && (C.Appearance[A].Asset.Group.Category == "Appearance") && (!(C.IsOnline() && C.IsPlayer()) || !(C.OnlineSharedSettings.BlockBodyCosplay && (C.Appearance[A].Asset != null) && (C.Appearance[A].Asset.Group != null) && C.Appearance[A].Asset.Group.BodyCosplay)))
|
||||
C.Appearance.splice(A, 1);
|
||||
|
||||
// Loads the new character canvas
|
||||
|
|
|
@ -809,8 +809,10 @@ function CharacterBuildDialog(C, CSV, functionPrefix, reload=true) {
|
|||
};
|
||||
|
||||
// Prefix with the current screen unless this is a Dialog function or an online character
|
||||
if (D.Function && D.Function !== "")
|
||||
D.Function = (D.Function.startsWith("Dialog") ? "" : C.IsOnline() ? "ChatRoom" : functionPrefix) + D.Function;
|
||||
if (D.Function && D.Function !== "") {
|
||||
// @ts-expect-error Not sure why the online || player check errors here
|
||||
D.Function = (D.Function.startsWith("Dialog") ? "" : (C.IsOnline() || C.IsPlayer()) ? "ChatRoom" : functionPrefix) + D.Function;
|
||||
}
|
||||
|
||||
C.Dialog.push(D);
|
||||
}
|
||||
|
@ -1797,7 +1799,8 @@ function CharacterSetFacialExpression(C, AssetGroup, Expression, Timer, Color, f
|
|||
const isTransient = Timer != null || fromQueue;
|
||||
|
||||
CharacterRefresh(C, !inChatRoom && !isTransient, false);
|
||||
if (inChatRoom && C.IsOnline()) {
|
||||
// @ts-expect-error Not sure why the online || player check errors here
|
||||
if (inChatRoom && (C.IsOnline() || C.IsPlayer())) {
|
||||
if (isTransient || C.IsPlayer()) {
|
||||
ChatRoomCharacterExpressionUpdate(C, AssetGroup);
|
||||
} else {
|
||||
|
|
|
@ -827,6 +827,9 @@ function DialogLeave() {
|
|||
|
||||
// Reset the state of the self menu
|
||||
DialogSelfMenuSelected = null;
|
||||
for (const preview of DialogSavedExpressionPreviews) {
|
||||
CharacterDelete(preview, false);
|
||||
}
|
||||
DialogSavedExpressionPreviews = [];
|
||||
DialogFacialExpressionsSelected = -1;
|
||||
DialogFacialExpressions = [];
|
||||
|
@ -1802,6 +1805,7 @@ function DialogBuildSavedExpressionsMenu() {
|
|||
for (let x = 0; x < expression.length; x++) {
|
||||
CharacterSetFacialExpression(PreviewCharacter, expression[x].Group, expression[x].CurrentExpression);
|
||||
}
|
||||
CharacterRefresh(PreviewCharacter);
|
||||
|
||||
DialogSavedExpressionPreviews[i] = PreviewCharacter;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue