#W# Added: Added an Overworld dungeon region. Tweaked overworld animal spawn.

This commit is contained in:
WarrentyExpired 2026-10-01 20:37:16 -04:00
parent 6213604bb1
commit 292cd625c5
10 changed files with 435 additions and 322 deletions

View file

@ -3819,7 +3819,7 @@ namespace Server.Mobiles
{
var tc = Core.TickCount;
if (!Controlled && !Summoned && Region is Server.Regions.DungeonRegion)
if (!Controlled && !Summoned && Region is Server.Regions.GreetingDungeonRegion)
{
if (Combatant == null)
{

View file

@ -0,0 +1,41 @@
using ModernUO.Serialization;
using System.Collections.Generic;
using Server.Items;
namespace Server.Mobiles
{
[SerializationGenerator(0, false)]
public partial class Necromancer : BaseVendor
{
private readonly List<SBInfo> m_SBInfos = new();
[Constructible]
public Necromancer() : base("the necromancer")
{
SetSkill(SkillName.Necromancy, 65.0, 88.0);
SetSkill(SkillName.SpiritSpeak, 65.0, 88.0);
SetSkill(SkillName.Meditation, 60.0, 83.0);
SetSkill(SkillName.MagicResist, 65.0, 88.0);
SetSkill(SkillName.Wrestling, 36.0, 68.0);
}
protected override List<SBInfo> SBInfos => m_SBInfos;
public override NpcGuild NpcGuild => NpcGuild.MagesGuild;
public override VendorShoeType ShoeType => Utility.RandomBool() ? VendorShoeType.Shoes : VendorShoeType.Sandals;
public override void InitSBInfo()
{
m_SBInfos.Add(new SBMage());
}
public override void InitOutfit()
{
base.InitOutfit();
AddItem(new Robe(Utility.RandomGreenHue()));
AddItem(new WizardsHat(Utility.RandomGreenHue()));
}
}
}

View file

@ -0,0 +1,43 @@
using Server;
using Server.Mobiles;
namespace Server.Regions
{
public class GreetingOverworldSpawnRegion : DungeonRegion
{
public GreetingOverworldSpawnRegion(string name, Map map, int priority, params Rectangle3D[] area)
: base(name, map, priority, area)
{
}
public override bool MountsAllowed => false;
public override void OnEnter(Mobile m)
{
base.OnEnter(m);
if (m.Player)
{
m.SendMessage($"You entered <BASEFONT COLOR='#FF0000'>{this.Name}</BASEFONT>.");
}
if (m is PlayerMobile player && player.Mounted )
{
if ( player.Mount is BaseMount )
{
Server.Custom.AutoStable.StoreMount(player);
}
else
{
BaseMount.Dismount(player);
player.SendMessage("Mounts are not permitted in this area.");
}
}
}
public override void OnExit(Mobile m)
{
base.OnExit(m);
if ( m is PlayerMobile player )
{
Server.Custom.AutoStable.RestoreMount(player);
}
}
}
}

View file

@ -65,5 +65,6 @@ public static class RegionJsonRegistration
RegionJsonSerializer.Register<GreetingTownRegion>();
RegionJsonSerializer.Register<GreetingDungeonRegion>();
RegionJsonSerializer.Register<MountlessTownRegion>();
RegionJsonSerializer.Register<GreetingOverworldSpawnRegion>();
}
}