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

Мини фикс #240

Merged
merged 7 commits into from
Aug 14, 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
Expand Up @@ -202,8 +202,8 @@ public override void Update(float frameTime)
_visibilitySystem.SetLayer((hallucination, visibility), (ushort)VisibilityFlags.BaseHallucination, false);
_visibilitySystem.RefreshVisibility(hallucination, visibilityComponent: visibility);

_visibilitySystem.SetLayer((hallucination, visibility), (ushort) stat.Layer, false);
_visibilitySystem.RefreshVisibility(hallucination, visibilityComponent: visibility);
//_visibilitySystem.SetLayer((hallucination, visibility), (ushort) stat.Layer, false);
//_visibilitySystem.RefreshVisibility(hallucination, visibilityComponent: visibility);
}

var uidnewCoords = Transform(uid).MapPosition.Offset(_random.NextVector2(stat.Range));
Expand All @@ -216,8 +216,8 @@ public override void Update(float frameTime)
_visibilitySystem.SetLayer((uidhallucination, uidvisibility), (ushort)VisibilityFlags.BaseHallucination, false);
_visibilitySystem.RefreshVisibility(uidhallucination, visibilityComponent: uidvisibility);

_visibilitySystem.SetLayer((uidhallucination, uidvisibility), (ushort) stat.Layer, false);
_visibilitySystem.RefreshVisibility(uidhallucination, visibilityComponent: uidvisibility);
//_visibilitySystem.SetLayer((uidhallucination, uidvisibility), (ushort) stat.Layer, false);
//_visibilitySystem.RefreshVisibility(uidhallucination, visibilityComponent: uidvisibility);

}

Expand Down Expand Up @@ -252,8 +252,8 @@ public override void Update(float frameTime)
_visibilitySystem.SetLayer((hallucination, visibility), (ushort)VisibilityFlags.BaseHallucination, false);
_visibilitySystem.RefreshVisibility(hallucination, visibilityComponent: visibility);

_visibilitySystem.SetLayer((hallucination, visibility), (ushort)stat.Layer, false);
_visibilitySystem.RefreshVisibility(hallucination, visibilityComponent: visibility);
//_visibilitySystem.SetLayer((hallucination, visibility), (ushort)stat.Layer, false);
//_visibilitySystem.RefreshVisibility(hallucination, visibilityComponent: visibility);
}

var uidnewCoords = Transform(uid).MapPosition.Offset(_random.NextVector2(stat.Range));
Expand All @@ -266,8 +266,8 @@ public override void Update(float frameTime)
_visibilitySystem.SetLayer((uidhallucination, uidvisibility), (ushort)VisibilityFlags.BaseHallucination, false);
_visibilitySystem.RefreshVisibility(uidhallucination, visibilityComponent: uidvisibility);

_visibilitySystem.SetLayer((uidhallucination, uidvisibility), (ushort) stat.Layer, false);
_visibilitySystem.RefreshVisibility(uidhallucination, visibilityComponent: uidvisibility);
//_visibilitySystem.SetLayer((uidhallucination, uidvisibility), (ushort) stat.Layer, false);
//_visibilitySystem.RefreshVisibility(uidhallucination, visibilityComponent: uidvisibility);

}
}
Expand Down
3 changes: 3 additions & 0 deletions Content.Server/ADT/Phantom/EntitySystems/PhantomSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1079,6 +1079,8 @@ private void OnPuppeter(EntityUid uid, PhantomComponent component, PuppeterActio
_popup.PopupEntity(selfMessage, uid, uid);
return;
}
if (HasComp<PhantomPuppetComponent>(target))
return;

args.Handled = true;
var makeVesselDoAfter = new DoAfterArgs(EntityManager, uid, component.MakeVesselDuration, new PuppeterDoAfterEvent(), uid, target: target)
Expand Down Expand Up @@ -1645,6 +1647,7 @@ private void OnTryMove(EntityUid uid, PhantomComponent component, UpdateCanMoveE
private void OnLevelChanged(EntityUid uid, PhantomComponent component, RefreshPhantomLevelEvent args)
{
SelectStyle(uid, component, component.CurrentStyle, true);
_alerts.ShowAlert(uid, _proto.Index(component.VesselCountAlert), (short) Math.Clamp(component.Vessels.Count, 0, 10));
}

private void MakeVesselDoAfter(EntityUid uid, PhantomComponent component, MakeVesselDoAfterEvent args)
Expand Down
2 changes: 2 additions & 0 deletions Content.Server/ADT/Quirks/QuirksSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ private void OnGetHideVerbs(EntityUid uid, EntityStorageComponent comp, GetVerbs
return;
if (TryComp<WeldableComponent>(uid, out var weldable) && weldable.IsWelded)
return;
if (comp.Contents.Contains(args.User))
return;

if (_whitelist.IsWhitelistFail(comp.Whitelist, args.User))
return;
Expand Down
3 changes: 2 additions & 1 deletion Content.Server/Prayer/PrayerSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
using Content.Shared.Verbs;
using Robust.Server.GameObjects;
using Robust.Shared.Player;
using Content.Shared.Bible.Components;

namespace Content.Server.Prayer;
/// <summary>
Expand Down Expand Up @@ -48,7 +49,7 @@ private void AddPrayVerb(EntityUid uid, PrayableComponent comp, GetVerbsEvent<Ac
Icon = comp.VerbImage,
Act = () =>
{
if (comp.BibleUserOnly && !EntityManager.TryGetComponent<BibleUserComponent>(args.User, out var bibleUser))
if (comp.BibleUserOnly && !EntityManager.TryGetComponent<ChaplainComponent>(args.User, out var bibleUser))
{
_popupSystem.PopupEntity(Loc.GetString("prayer-popup-notify-pray-locked"), uid, actor.PlayerSession, PopupType.Large);
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
ejectSound: /Audio/Weapons/Guns/MagOut/batrifle_magout.ogg
whitelist:
tags:
- PhantomEctoplasm
- PhantomEctoplasmBattery
- type: Appearance
- type: StaticPrice
price: 500
Expand Down
16 changes: 8 additions & 8 deletions Resources/Prototypes/ADT/Traits/quirks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@
modifier: 1.3
cost: 2

- type: trait
id: ADTPotentialPoltergeist
name: trait-poltergeist-name
description: trait-poltergeist-desc
category: Quirks
components:
- type: PotentialPoltergeist
cost: 4
# - type: trait
# id: ADTPotentialPoltergeist
# name: trait-poltergeist-name
# description: trait-poltergeist-desc
# category: Quirks
# components:
# - type: PotentialPoltergeist
# cost: 4

Loading