Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Diona Tags Fix #868

Merged
merged 5 commits into from
Jan 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
using Robust.Shared.GameStates;

namespace Content.Shared.StepTrigger.Components;

/// <summary>
/// Frontier - This is used for immunity to cancelling step trigger events if the user is wearing shoes, such as for glass shards.
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed partial class ShoesRequiredStepTriggerImmuneComponent : Component // Frontier
{
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Content.Shared.Examine;
using Content.Shared.Examine;
using Content.Shared.Inventory;
using Content.Shared.StepTrigger.Components;
using Content.Shared.Tag;
Expand All @@ -25,6 +25,12 @@ private void OnStepTriggerAttempt(EntityUid uid, ShoesRequiredStepTriggerCompone
return;
}

if (HasComp<ShoesRequiredStepTriggerImmuneComponent>(args.Tripper)) // Frontier
{
args.Cancelled = true;
return;
}

if (!TryComp<InventoryComponent>(args.Tripper, out var inventory))
return;

Expand Down
7 changes: 1 addition & 6 deletions Resources/Prototypes/Entities/Mobs/Species/diona.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,7 @@
- type: BodyEmotes
soundsId: DionaBodyEmotes
- type: IgnoreKudzu
- type: Tag
tags:
- ShoesRequiredStepTriggerImmune
- CanPilot
- FootstepSound
- DoorBumpOpener
- type: ShoesRequiredStepTriggerImmune # Frontier

- type: entity
parent: BaseSpeciesDummy
Expand Down
Loading