fix netentity
This commit is contained in:
@@ -274,9 +274,11 @@ public sealed partial class CultSystem : EntitySystem
|
|||||||
if (HasComp<CultBuffComponent>(user))
|
if (HasComp<CultBuffComponent>(user))
|
||||||
time /= 2;
|
time /= 2;
|
||||||
|
|
||||||
|
var netEntity = GetNetEntity(target);
|
||||||
|
|
||||||
var ev = new CultEraseEvent
|
var ev = new CultEraseEvent
|
||||||
{
|
{
|
||||||
TargetEntityId = target
|
TargetEntityId = netEntity
|
||||||
};
|
};
|
||||||
|
|
||||||
var argsDoAfterEvent = new DoAfterArgs(_entityManager, user, time, ev, target)
|
var argsDoAfterEvent = new DoAfterArgs(_entityManager, user, time, ev, target)
|
||||||
@@ -296,7 +298,9 @@ public sealed partial class CultSystem : EntitySystem
|
|||||||
if (args.Cancelled)
|
if (args.Cancelled)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
_entityManager.DeleteEntity(args.TargetEntityId);
|
var target = GetEntity(args.TargetEntityId);
|
||||||
|
|
||||||
|
_entityManager.DeleteEntity(target);
|
||||||
_popupSystem.PopupEntity(Loc.GetString("cult-erased-rune"), args.User);
|
_popupSystem.PopupEntity(Loc.GetString("cult-erased-rune"), args.User);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -6,5 +6,5 @@ namespace Content.Shared.White.Cult.Runes;
|
|||||||
[Serializable, NetSerializable]
|
[Serializable, NetSerializable]
|
||||||
public sealed partial class CultEraseEvent : SimpleDoAfterEvent
|
public sealed partial class CultEraseEvent : SimpleDoAfterEvent
|
||||||
{
|
{
|
||||||
public EntityUid TargetEntityId;
|
public NetEntity TargetEntityId;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user