Skip to content
This repository has been archived by the owner on Nov 1, 2024. It is now read-only.

Fix artifact destroy walls #141

Merged
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
2 changes: 2 additions & 0 deletions Content.Shared/Maps/ContentTileDefinition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ public sealed partial class ContentTileDefinition : IPrototype, IInheritingProto
[DataField]
public PrototypeFlags<ToolQualityPrototype> DeconstructTools { get; set; } = new();

public bool CanCrowbar => DeconstructTools.Contains(PryingToolQuality);

// Delta V
[DataField("canShovel")] public bool CanShovel { get; private set; }
//Delta V
Expand Down
5 changes: 4 additions & 1 deletion Content.Shared/Maps/TileSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public bool PryTile(Vector2i indices, EntityUid gridId)
return PryTile(tileRef);
}

public bool PryTile(TileRef tileRef)
public bool PryTile(TileRef tileRef)
{
return PryTile(tileRef, false);
}
Expand All @@ -100,6 +100,9 @@ public bool PryTile(TileRef tileRef, bool pryPlating)

var tileDef = (ContentTileDefinition) _tileDefinitionManager[tile.TypeId];

if (!tileDef.CanCrowbar)
return false;

return DeconstructTile(tileRef);
}
// Delta V
Expand Down
Loading