mirror of
https://gitgud.io/BondageProjects/Bondage-College.git
synced 2025-04-25 17:59:34 +00:00
Feature: Adds a chatroom message and audio cue when timer locks expire (#992)
* Adds chatroom message and audio cue when timer locks expire * Fixes some comment grammar
This commit is contained in:
parent
bd62c8ba5d
commit
934c798ce4
4 changed files with 14 additions and 0 deletions
BondageClub
BIN
BondageClub/Audio/UnlockSmall.mp3
Normal file
BIN
BondageClub/Audio/UnlockSmall.mp3
Normal file
Binary file not shown.
|
@ -351,6 +351,7 @@ RestartTimer,,,Restart Timer,,
|
|||
TimerAddTime,,,SourceCharacter adds TimerTime TimerUnit to the padlock on DestinationCharacter FocusAssetGroup.,,
|
||||
TimerRemoveTime,,,SourceCharacter removes TimerTime TimerUnit to the padlock on DestinationCharacter FocusAssetGroup.,,
|
||||
TimerAddRemoveUnknownTime,,,an unknown amount of time,,
|
||||
TimerRelease,,,The LockName on DestinationCharacterName FocusAssetGroup opens with a click,,
|
||||
CombinationFail,,,SourceCharacter tries the code CombinationNumber but fails to open the padlock on DestinationCharacter FocusAssetGroup.,,
|
||||
CombinationChangeSuccess,,,SourceCharacter changes the code of the padlock on DestinationCharacter FocusAssetGroup.,,
|
||||
CombinationChangeFail,,,SourceCharacter tries to change the code of the padlock on DestinationCharacter FocusAssetGroup but fails.,,
|
||||
|
|
Can't render this file because it has a wrong number of fields in line 58.
|
|
@ -36,6 +36,8 @@ function AudioPlayContent(data) {
|
|||
// Instant actions can trigger a sound depending on the asset
|
||||
if (data.Content == "ActionAddLock") {
|
||||
audioFile = "Audio/LockSmall.mp3";
|
||||
} else if (data.Content == "TimerRelease" || data.Content == "ActionUnlock" || data.Content == "ActionUnlockAndRemove") {
|
||||
audioFile = "Audio/UnlockSmall.mp3";
|
||||
} else if (data.Content == "ActionLock" || data.Content == "ActionUse" || data.Content == "ActionSwap" || data.Content == "SlaveCollarChangeType" || (data.Content.indexOf("ActionActivity") == 0)) {
|
||||
noiseLevelModifier += 3; //constant vibration volume level
|
||||
var NextAsset = data.Dictionary.find(function (el) {return el.Tag == "NextAsset";});
|
||||
|
|
|
@ -36,6 +36,7 @@ function TimerInventoryRemove() {
|
|||
for (var A = 0; A < Character[C].Appearance.length; A++)
|
||||
if ((Character[C].Appearance[A].Property != null) && (Character[C].Appearance[A].Property.RemoveTimer != null))
|
||||
if ((typeof Character[C].Appearance[A].Property.RemoveTimer == "number") && (Character[C].Appearance[A].Property.RemoveTimer <= CurrentTime)) {
|
||||
var LockName = Character[C].Appearance[A].Property.LockedBy;
|
||||
|
||||
// Remove any lock or timer
|
||||
delete Character[C].Appearance[A].Property.LockedBy;
|
||||
|
@ -50,6 +51,16 @@ function TimerInventoryRemove() {
|
|||
if (Character[C].Appearance[A].Property.Effect[E] == "Lock")
|
||||
Character[C].Appearance[A].Property.Effect.splice(E, 1);
|
||||
|
||||
// If we're removing a lock and we're in a chatroom, send a chatroom message
|
||||
if (LockName && CurrentScreen === "ChatRoom") {
|
||||
var Dictionary = [
|
||||
{Tag: "DestinationCharacterName", Text: Character[C].Name, MemberNumber: Character[C].MemberNumber},
|
||||
{Tag: "FocusAssetGroup", AssetGroupName: Character[C].Appearance[A].Asset.Group.Name},
|
||||
{Tag: "LockName", AssetName: LockName}
|
||||
];
|
||||
ServerSend("ChatRoomChat", {Content: "TimerRelease", Type: "Action", Dictionary});
|
||||
}
|
||||
|
||||
// If we must remove the linked item from the character or the facial expression
|
||||
if ((Character[C].Appearance[A].Property.RemoveItem != null) && Character[C].Appearance[A].Property.RemoveItem && (Character[C].Appearance[A].Asset.Group.Category != null) && (Character[C].Appearance[A].Asset.Group.Category == "Item"))
|
||||
InventoryRemove(Character[C], Character[C].Appearance[A].Asset.Group.Name);
|
||||
|
|
Loading…
Add table
Reference in a new issue