fix(throwing): guard return-throw effect against deleted/unmapped thrower
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
ff84f140df
commit
b0ef0d55e1
1 changed files with 2 additions and 2 deletions
|
|
@ -132,12 +132,12 @@ public abstract partial class BaseThrown : BaseRanged
|
|||
|
||||
public virtual void Return(Mobile thrower, Mobile target, WorldLocation worldLocation)
|
||||
{
|
||||
if (thrower == null)
|
||||
if (thrower?.Deleted != false || thrower.Map == null || thrower.Map == Map.Internal)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (target != null)
|
||||
if (target?.Deleted == false)
|
||||
{
|
||||
target.MovingEffect(thrower, EffectID, 18, 1, false, false, Hue, 0);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue