Skip to content

Commit

Permalink
Fix some naming and spacing uniformity issues
Browse files Browse the repository at this point in the history
  • Loading branch information
vaketola committed Jan 19, 2024
1 parent d526351 commit a538ff3
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 9 deletions.
9 changes: 5 additions & 4 deletions Content.Server/CosmaticDrift/CryoSleep/CryoSleepSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,11 @@
using Content.Shared.Roles.Jobs;
using Content.Shared.StationRecords;
using Content.Shared.Verbs;
using Robust.Server.Audio;
using Robust.Server.Containers;
using Robust.Shared.Audio;
using Robust.Shared.Audio.Systems;
using Robust.Shared.Containers;
using Robust.Shared.Enums;
using Robust.Shared.Physics;

namespace Content.Server.CryoSleep;

Expand All @@ -53,6 +51,7 @@ public override void Initialize()
base.Initialize();

SubscribeLocalEvent<CryoSleepComponent, ComponentInit>(ComponentInit);

SubscribeLocalEvent<CryoSleepComponent, GetVerbsEvent<AlternativeVerb>>(AddAlternativeVerbs);
SubscribeLocalEvent<CryoSleepComponent, DestructionEventArgs>((e, c, _) => EjectBody(e, c));
SubscribeLocalEvent<CryoSleepComponent, DragDropTargetEvent>(OnDragDrop);
Expand All @@ -63,6 +62,7 @@ private void ComponentInit(EntityUid uid, CryoSleepComponent component, Componen
component.BodyContainer = _container.EnsureContainer<ContainerSlot>(uid, "body_container");
}


private bool InsertBody(EntityUid uid, EntityUid? toInsert, CryoSleepComponent component)
{
if (toInsert == null || IsOccupied(component))
Expand All @@ -79,7 +79,7 @@ private bool InsertBody(EntityUid uid, EntityUid? toInsert, CryoSleepComponent c
public bool RespawnUser(EntityUid? toInsert, CryoSleepComponent component, bool force)
{
// Play the cryosleep pod opening sound effect.
_audioSystem.PlayPvs("/Audio/SimpleStation14/Effects/cryosleepopen.ogg", component.Owner, AudioParams.Default.WithVolume(5f));
_audioSystem.PlayPvs("/Audio/SimpleStation14/Effects/cryosleep_open.ogg", component.Owner, AudioParams.Default.WithVolume(6f));

if (toInsert == null)
return false;
Expand All @@ -106,6 +106,7 @@ public bool RespawnUser(EntityUid? toInsert, CryoSleepComponent component, bool

return success;
}

public void CryoStoreBody(EntityUid mindId)
{
if (!_sharedJobSystem.MindTryGetJob(mindId, out _, out var prototype))
Expand All @@ -123,7 +124,7 @@ public void CryoStoreBody(EntityUid mindId)
return;

// Play the cryostasis sound effect. Need to use coordinates since the body gets deleted.
_audioSystem.PlayPvs("/Audio/SimpleStation14/Effects/cryostasis.ogg", Transform(body.Value).Coordinates, AudioParams.Default.WithVolume(5f));
_audioSystem.PlayPvs("/Audio/SimpleStation14/Effects/cryostasis.ogg", Transform(body.Value).Coordinates, AudioParams.Default.WithVolume(6f));

// Remove the record. Hopefully.
foreach (var item in _inventory.GetHandOrInventoryEntities(body.Value))
Expand Down
5 changes: 3 additions & 2 deletions Resources/Audio/SimpleStation14/Effects/attributions.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
- files: ["cryostasis", "cryosleepopen"]
- files: ["cryostasis", "cryosleep_open"]
license: "CC-BY-SA-3.0"
copyright: "Created by Finket for SS14"
source: "https://github.com/Finket/"
source: "https://github.com/Finket/"

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## UI
accept-cryo-window-accept-button = Accept
accept-cryo-window-deny-button = Cancel
accept-cryo-window-prompt-text-part = Enter cryo sleep and finish your shift as this character?
accept-cryo-window-title = Cryo Sleep Chamber
accept-cryo-window-prompt-text-part = Enter cryosleep and end your shift as this character?
accept-cryo-window-title = Cryostasis Sleep Chamber
cryo-leave-announcement = {$character} ({$job}) is entering cryosleep.
cryo-leave-announcement = {$character} ({$job}) has gone into cryosleep.

0 comments on commit a538ff3

Please sign in to comment.