Skip to content

Commit

Permalink
Mail Telepad resprite!
Browse files Browse the repository at this point in the history
  • Loading branch information
honeyed-lemons committed Jan 14, 2025
1 parent 833081e commit 14aca0d
Show file tree
Hide file tree
Showing 9 changed files with 67 additions and 30 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using Robust.Shared.Audio;
using Robust.Shared.Prototypes;

namespace Content.Server._DV.Mail.Components
{
Expand All @@ -22,7 +23,11 @@ public sealed partial class MailTeleporterComponent : Component
/// </summary>
[DataField]
public SoundSpecifier TeleportSound = new SoundPathSpecifier("/Audio/Effects/teleport_arrival.ogg");

/// <summary>
/// Imp : The SFX spawned when mail teleports in.
/// </summary>
[DataField]
public EntProtoId BeamInFx = "TelepadBeamInFX";
/// <summary>
/// The MailDeliveryPoolPrototype that's used to select what mail this
/// teleporter can deliver.
Expand Down
3 changes: 3 additions & 0 deletions Content.Server/_DV/Mail/EntitySystems/MailSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -719,6 +719,9 @@ private void SpawnMail(EntityUid uid, MailTeleporterComponent? component = null)
if (_containerSystem.TryGetContainer(uid, "queued", out var queued))
_containerSystem.EmptyContainer(queued);

// Spawn VFX
Spawn(component.BeamInFx, Transform(uid).Coordinates);

_audioSystem.PlayPvs(component.TeleportSound, uid);
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
- type: entity
id: MailTeleporter
parent: [ BaseMachinePowered, ConstructibleMachine ]
name: mail teleporter
name: mail telepad
description: Teleports mail addressed to the crew of this station.
components:
- type: MailTeleporter
Expand All @@ -10,39 +10,23 @@
fix1:
shape:
!type:PhysShapeAabb
bounds: "-0.45,-0.45,0.45,0.00"
bounds: "-0.45,-0.45,0.45,0.00"
density: 120
mask:
- HighImpassable
- type: Appearance
- type: Sprite
sprite: _Nyanotrasen/Structures/mailbox.rsi
scale: 0.5, 0.5
sprite: _Impstation/Structures/mailtelepad.rsi
layers:
- state: icon
- state: unlit
shader: unshaded
map: ["enum.PowerDeviceVisualLayers.Powered"]
- type: Damageable
damageContainer: Inorganic
damageModifierSet: Metallic
- type: Destructible
thresholds:
- trigger:
!type:DamageTrigger
damage: 75
behaviors:
- !type:PlaySoundBehavior
sound:
collection: MetalGlassBreak
- !type:ChangeConstructionNodeBehavior
node: machineFrame
- !type:DoActsBehavior
acts: ["Destruction"]
- state: base
- state: lit
shader: unshaded
map: ["enum.PowerDeviceVisualLayers.Powered"]
- type: ApcPowerReceiver
powerLoad: 1000
- type: GenericVisualizer
visuals:
enum.PowerDeviceVisuals.Powered:
enum.PowerDeviceVisualLayers.Powered:
True: {visible: true}
False: {visible: false}
True: { visible: true }
False: { visible: false }
- type: Machine
board: MailTeleporterMachineCircuitboard
12 changes: 12 additions & 0 deletions Resources/Prototypes/_Impstation/Entities/Effects/base.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
- type: entity
categories: [ HideSpawnMenu ]
id: BaseFXEntity
placement:
mode: SnapgridCenter
components:
- type: Transform
noRot: true
anchored: true
- type: Tag
tags:
- HideContextMenu
14 changes: 14 additions & 0 deletions Resources/Prototypes/_Impstation/Entities/Effects/teleportfx.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
- type: entity
parent: BaseFXEntity
categories: [ HideSpawnMenu ]
id: TelepadBeamInFX
components:
- type: TimedDespawn
lifetime: 0.5
- type: Sprite
layers:
- sprite: Structures\cargo_telepad.rsi
state: beam
shader: unshaded
netsync: false
drawdepth: Effects
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
- type: entity
id: MailTeleporterMachineCircuitboard
parent: [ BaseComputerCircuitboard, BaseCargoContraband ]
name: mail teleporter machine board
name: mail telepad machine board
components:
- type: Sprite
state: supply
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Textured by Kazne in the Impstation Discord",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "base",
"delays": [[ 1 ]]
},
{
"name": "lit",
"delays":[ [ 0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1 ] ]
}
]
}

0 comments on commit 14aca0d

Please sign in to comment.