Overwrite
Complete Overwrite of the Folder with the free shard. ServUO 57.3 has been added.
This commit is contained in:
41
Scripts/Items/Quest/AbscessTail.cs
Normal file
41
Scripts/Items/Quest/AbscessTail.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class AbscessTail : Item
|
||||
{
|
||||
[Constructable]
|
||||
public AbscessTail()
|
||||
: base(0x1A9D)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Hue = 0x51D; // TODO check
|
||||
}
|
||||
|
||||
public AbscessTail(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074231;
|
||||
}
|
||||
}// Abscess' Tail
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
126
Scripts/Items/Quest/AbyssKey.cs
Normal file
126
Scripts/Items/Quest/AbyssKey.cs
Normal file
@@ -0,0 +1,126 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class AbyssKey : Item
|
||||
{
|
||||
private int m_Lifespan;
|
||||
private Timer m_Timer;
|
||||
[Constructable]
|
||||
public AbyssKey(int itemID)
|
||||
: base(itemID)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
|
||||
if (this.Lifespan > 0)
|
||||
{
|
||||
this.m_Lifespan = this.Lifespan;
|
||||
this.StartTimer();
|
||||
}
|
||||
}
|
||||
|
||||
public AbyssKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public virtual int Lifespan
|
||||
{
|
||||
get
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public int TimeLeft
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Lifespan;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.m_Lifespan = value;
|
||||
this.InvalidateProperties();
|
||||
}
|
||||
}
|
||||
public override void GetProperties(ObjectPropertyList list)
|
||||
{
|
||||
base.GetProperties(list);
|
||||
|
||||
if (this.Lifespan > 0)
|
||||
list.Add(1072517, this.m_Lifespan.ToString()); // Lifespan: ~1_val~ seconds
|
||||
}
|
||||
|
||||
public virtual void StartTimer()
|
||||
{
|
||||
if (this.m_Timer != null)
|
||||
return;
|
||||
|
||||
this.m_Timer = Timer.DelayCall(TimeSpan.FromSeconds(10), TimeSpan.FromSeconds(10), new TimerCallback(Slice));
|
||||
this.m_Timer.Priority = TimerPriority.OneSecond;
|
||||
}
|
||||
|
||||
public virtual void StopTimer()
|
||||
{
|
||||
if (this.m_Timer != null)
|
||||
this.m_Timer.Stop();
|
||||
|
||||
this.m_Timer = null;
|
||||
}
|
||||
|
||||
public virtual void Slice()
|
||||
{
|
||||
this.m_Lifespan -= 10;
|
||||
|
||||
this.InvalidateProperties();
|
||||
|
||||
if (this.m_Lifespan <= 0)
|
||||
this.Decay();
|
||||
}
|
||||
|
||||
public virtual void Decay()
|
||||
{
|
||||
if (this.RootParent is Mobile)
|
||||
{
|
||||
Mobile parent = (Mobile)this.RootParent;
|
||||
|
||||
if (this.Name == null)
|
||||
parent.SendLocalizedMessage(1072515, "#" + this.LabelNumber); // The ~1_name~ expired...
|
||||
else
|
||||
parent.SendLocalizedMessage(1072515, this.Name); // The ~1_name~ expired...
|
||||
|
||||
Effects.SendLocationParticles(EffectItem.Create(parent.Location, parent.Map, EffectItem.DefaultDuration), 0x3728, 8, 20, 5042);
|
||||
Effects.PlaySound(parent.Location, parent.Map, 0x201);
|
||||
}
|
||||
else
|
||||
{
|
||||
Effects.SendLocationParticles(EffectItem.Create(this.Location, this.Map, EffectItem.DefaultDuration), 0x3728, 8, 20, 5042);
|
||||
Effects.PlaySound(this.Location, this.Map, 0x201);
|
||||
}
|
||||
|
||||
this.StopTimer();
|
||||
this.Delete();
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.Write((int)this.m_Lifespan);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
this.m_Lifespan = reader.ReadInt();
|
||||
|
||||
this.StartTimer();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/AcidProofRope.cs
Normal file
40
Scripts/Items/Quest/AcidProofRope.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class AcidProofRope : Item
|
||||
{
|
||||
[Constructable]
|
||||
public AcidProofRope()
|
||||
: base(0x20D)
|
||||
{
|
||||
this.Hue = 0x3D1; // TODO check
|
||||
}
|
||||
|
||||
public AcidProofRope(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074886;
|
||||
}
|
||||
}// Acid Proof Rope
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
95
Scripts/Items/Quest/AlbinoSquirrelImprisonedInCrystal.cs
Normal file
95
Scripts/Items/Quest/AlbinoSquirrelImprisonedInCrystal.cs
Normal file
@@ -0,0 +1,95 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class AlbinoSquirrelImprisonedInCrystal : BaseImprisonedMobile
|
||||
{
|
||||
[Constructable]
|
||||
public AlbinoSquirrelImprisonedInCrystal()
|
||||
: base(0x1F1C)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x482;
|
||||
}
|
||||
|
||||
public AlbinoSquirrelImprisonedInCrystal(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075004;
|
||||
}
|
||||
}// An Albino Squirrel Imprisoned in a Crystal
|
||||
public override BaseCreature Summon
|
||||
{
|
||||
get
|
||||
{
|
||||
return new AlbinoSquirrel();
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
namespace Server.Mobiles
|
||||
{
|
||||
public class AlbinoSquirrel : Squirrel
|
||||
{
|
||||
[Constructable]
|
||||
public AlbinoSquirrel()
|
||||
: base()
|
||||
{
|
||||
this.Hue = 0x482;
|
||||
}
|
||||
|
||||
public AlbinoSquirrel(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool DeleteOnRelease
|
||||
{
|
||||
get
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
public override void GetProperties(ObjectPropertyList list)
|
||||
{
|
||||
base.GetProperties(list);
|
||||
|
||||
list.Add(1049646); // (summoned)
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/AlchemistsBandage.cs
Normal file
42
Scripts/Items/Quest/AlchemistsBandage.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class AlchemistsBandage : Item
|
||||
{
|
||||
[Constructable]
|
||||
public AlchemistsBandage()
|
||||
: base(0xE21)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x482;
|
||||
}
|
||||
|
||||
public AlchemistsBandage(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075452;
|
||||
}
|
||||
}// Alchemist's Bandage
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/AndrosGratitude.cs
Normal file
40
Scripts/Items/Quest/AndrosGratitude.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class AndrosGratitude : SmithHammer
|
||||
{
|
||||
[Constructable]
|
||||
public AndrosGratitude()
|
||||
: base(10)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public AndrosGratitude(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075345;
|
||||
}
|
||||
}// Andros<6F> Gratitude
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
39
Scripts/Items/Quest/ArielHavenWritofMembership.cs
Normal file
39
Scripts/Items/Quest/ArielHavenWritofMembership.cs
Normal file
@@ -0,0 +1,39 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class ArielHavenWritofMembership : Item
|
||||
{
|
||||
[Constructable]
|
||||
public ArielHavenWritofMembership()
|
||||
: base(0x2831)
|
||||
{
|
||||
}
|
||||
|
||||
public ArielHavenWritofMembership(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1094998;
|
||||
}
|
||||
}//Ariel Haven Writ of Membership
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
44
Scripts/Items/Quest/BagOfJewels.cs
Normal file
44
Scripts/Items/Quest/BagOfJewels.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BagOfJewels : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1075307; } } // Bag of Jewels
|
||||
public override bool HiddenQuestItemHue { get { return true; } }
|
||||
|
||||
[Constructable]
|
||||
public BagOfJewels()
|
||||
: base(0xE76)
|
||||
{
|
||||
LootType = LootType.Blessed;
|
||||
Weight = 2.0;
|
||||
Hue = 155;
|
||||
}
|
||||
|
||||
public override void GetProperties(ObjectPropertyList list)
|
||||
{
|
||||
base.GetProperties(list);
|
||||
|
||||
list.Add(1075453); // Contents: 30 jewels
|
||||
}
|
||||
|
||||
public BagOfJewels(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/BasinOfCrystalClearWater.cs
Normal file
41
Scripts/Items/Quest/BasinOfCrystalClearWater.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BasinOfCrystalClearWater : Item
|
||||
{
|
||||
[Constructable]
|
||||
public BasinOfCrystalClearWater()
|
||||
: base(0x1008)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 5.0;
|
||||
}
|
||||
|
||||
public BasinOfCrystalClearWater(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075303;
|
||||
}
|
||||
}// Basin of Crystal-Clear Water
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
46
Scripts/Items/Quest/BedlamKey.cs
Normal file
46
Scripts/Items/Quest/BedlamKey.cs
Normal file
@@ -0,0 +1,46 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BedlamKey : MasterKey
|
||||
{
|
||||
public BedlamKey()
|
||||
: base(0xFF3)
|
||||
{
|
||||
}
|
||||
|
||||
public BedlamKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int Lifespan
|
||||
{
|
||||
get
|
||||
{
|
||||
return 600;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override bool CanOfferConfirmation(Mobile from)
|
||||
{
|
||||
if (from.Region != null && from.Region.IsPartOf("Bedlam"))
|
||||
return base.CanOfferConfirmation(from);
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
184
Scripts/Items/Quest/BellOfTheDead.cs
Normal file
184
Scripts/Items/Quest/BellOfTheDead.cs
Normal file
@@ -0,0 +1,184 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Quests.Doom
|
||||
{
|
||||
public class BellOfTheDead : Item
|
||||
{
|
||||
private Chyloth m_Chyloth;
|
||||
private SkeletalDragon m_Dragon;
|
||||
private bool m_Summoning;
|
||||
|
||||
public static List<BellOfTheDead> Instances { get; set; } // Just incase someone has more than 1
|
||||
|
||||
[Constructable]
|
||||
public BellOfTheDead()
|
||||
: base(0x91A)
|
||||
{
|
||||
Hue = 0x835;
|
||||
Movable = false;
|
||||
|
||||
if (Instances == null)
|
||||
Instances = new List<BellOfTheDead>();
|
||||
|
||||
Instances.Add(this);
|
||||
}
|
||||
|
||||
public BellOfTheDead(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1050018;
|
||||
}
|
||||
}// bell of the dead
|
||||
[CommandProperty(AccessLevel.GameMaster, AccessLevel.Administrator)]
|
||||
public Chyloth Chyloth
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Chyloth;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Chyloth = value;
|
||||
}
|
||||
}
|
||||
[CommandProperty(AccessLevel.GameMaster, AccessLevel.Administrator)]
|
||||
public SkeletalDragon Dragon
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Dragon;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Dragon = value;
|
||||
}
|
||||
}
|
||||
[CommandProperty(AccessLevel.GameMaster, AccessLevel.Administrator)]
|
||||
public bool Summoning
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Summoning;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Summoning = value;
|
||||
}
|
||||
}
|
||||
|
||||
public static void TryRemoveDragon(SkeletalDragon dragon)
|
||||
{
|
||||
if (Instances == null)
|
||||
return;
|
||||
|
||||
var bell = Instances.FirstOrDefault(x => x.Dragon == dragon);
|
||||
|
||||
if (bell != null)
|
||||
{
|
||||
bell.Dragon = null;
|
||||
}
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (from.InRange(GetWorldLocation(), 2))
|
||||
BeginSummon(from);
|
||||
else
|
||||
from.LocalOverheadMessage(MessageType.Regular, 0x3B2, 1019045); // I can't reach that.
|
||||
}
|
||||
|
||||
public virtual void BeginSummon(Mobile from)
|
||||
{
|
||||
if (m_Chyloth != null && !m_Chyloth.Deleted)
|
||||
{
|
||||
from.SendLocalizedMessage(1050010); // The ferry man has already been summoned. There is no need to ring for him again.
|
||||
}
|
||||
else if (m_Dragon != null && !m_Dragon.Deleted && !m_Dragon.Controlled)
|
||||
{
|
||||
from.SendLocalizedMessage(1050017); // The ferryman has recently been summoned already. You decide against ringing the bell again so soon.
|
||||
}
|
||||
else if (!m_Summoning)
|
||||
{
|
||||
m_Summoning = true;
|
||||
|
||||
Effects.PlaySound(GetWorldLocation(), Map, 0x100);
|
||||
|
||||
Timer.DelayCall(TimeSpan.FromSeconds(8.0), new TimerStateCallback(EndSummon), from);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void EndSummon(object state)
|
||||
{
|
||||
Mobile from = (Mobile)state;
|
||||
|
||||
if (m_Chyloth != null && !m_Chyloth.Deleted)
|
||||
{
|
||||
from.SendLocalizedMessage(1050010); // The ferry man has already been summoned. There is no need to ring for him again.
|
||||
}
|
||||
else if (m_Dragon != null && !m_Dragon.Deleted && !m_Dragon.Controlled)
|
||||
{
|
||||
from.SendLocalizedMessage(1050017); // The ferryman has recently been summoned already. You decide against ringing the bell again so soon.
|
||||
}
|
||||
else if (m_Summoning)
|
||||
{
|
||||
m_Summoning = false;
|
||||
|
||||
Point3D loc = GetWorldLocation();
|
||||
|
||||
loc.Z -= 16;
|
||||
|
||||
Effects.SendLocationParticles(EffectItem.Create(loc, Map, EffectItem.DefaultDuration), 0x3728, 10, 10, 0, 0, 2023, 0);
|
||||
Effects.PlaySound(loc, Map, 0x1FE);
|
||||
|
||||
m_Chyloth = new Chyloth();
|
||||
|
||||
m_Chyloth.Direction = (Direction)(7 & (4 + (int)from.GetDirectionTo(loc)));
|
||||
m_Chyloth.MoveToWorld(loc, Map);
|
||||
|
||||
m_Chyloth.Bell = this;
|
||||
m_Chyloth.AngryAt = from;
|
||||
m_Chyloth.BeginGiveWarning();
|
||||
m_Chyloth.BeginRemove(TimeSpan.FromSeconds(40.0));
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.Write((Mobile)m_Chyloth);
|
||||
writer.Write((Mobile)m_Dragon);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
if (Instances == null)
|
||||
Instances = new List<BellOfTheDead>();
|
||||
|
||||
Instances.Add(this);
|
||||
|
||||
m_Chyloth = reader.ReadMobile() as Chyloth;
|
||||
m_Dragon = reader.ReadMobile() as SkeletalDragon;
|
||||
|
||||
if (m_Chyloth != null)
|
||||
m_Chyloth.Delete();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/BlightedCotton.cs
Normal file
42
Scripts/Items/Quest/BlightedCotton.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BlightedCotton : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public BlightedCotton()
|
||||
: base(0x2DB)
|
||||
{
|
||||
Weight = 1;
|
||||
Hue = 0x35; // TODO check
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public BlightedCotton(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074331;
|
||||
}
|
||||
}// blighted cotton
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
76
Scripts/Items/Quest/BlightedGroveKey.cs
Normal file
76
Scripts/Items/Quest/BlightedGroveKey.cs
Normal file
@@ -0,0 +1,76 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BlightedGroveKey : MasterKey
|
||||
{
|
||||
public BlightedGroveKey()
|
||||
: base(0x21C)
|
||||
{
|
||||
}
|
||||
|
||||
public BlightedGroveKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074346;
|
||||
}
|
||||
}// dryad's curse
|
||||
public override int Lifespan
|
||||
{
|
||||
get
|
||||
{
|
||||
return 600;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override bool CanOfferConfirmation(Mobile from)
|
||||
{
|
||||
if (from.Region != null && from.Region.IsPartOf("Blighted Grove"))
|
||||
{
|
||||
return base.CanOfferConfirmation(from);
|
||||
}
|
||||
|
||||
if (Altar == null)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
Map map = Altar.Map;
|
||||
|
||||
foreach (var rect in _EntryLocs)
|
||||
{
|
||||
if (rect.Contains(from.Location))
|
||||
{
|
||||
return base.CanOfferConfirmation(from);
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
private Rectangle2D[] _EntryLocs =
|
||||
{
|
||||
new Rectangle2D(574, 1630, 20, 15),
|
||||
new Rectangle2D(579, 1645, 12, 4)
|
||||
};
|
||||
}
|
||||
}
|
||||
67
Scripts/Items/Quest/BlueKey1.cs
Normal file
67
Scripts/Items/Quest/BlueKey1.cs
Normal file
@@ -0,0 +1,67 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BlueKey1 : AbyssKey
|
||||
{
|
||||
[Constructable]
|
||||
public BlueKey1()
|
||||
: base(0x1012)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x5D; // TODO check
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Movable = false;
|
||||
}
|
||||
|
||||
public BlueKey1(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1111646;
|
||||
}
|
||||
}// Blue Key Fragment
|
||||
public override int Lifespan
|
||||
{
|
||||
get
|
||||
{
|
||||
return 21600;
|
||||
}
|
||||
}
|
||||
public override void OnDoubleClick(Mobile m)
|
||||
{
|
||||
Item a = m.Backpack.FindItemByType(typeof(RedKey1));
|
||||
if (a != null)
|
||||
{
|
||||
Item b = m.Backpack.FindItemByType(typeof(YellowKey1));
|
||||
if (b != null)
|
||||
{
|
||||
m.AddToBackpack(new TripartiteKey());
|
||||
a.Delete();
|
||||
b.Delete();
|
||||
this.Delete();
|
||||
m.SendLocalizedMessage(1111649);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
48
Scripts/Items/Quest/Bluekeyfragment.cs
Normal file
48
Scripts/Items/Quest/Bluekeyfragment.cs
Normal file
@@ -0,0 +1,48 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class Bluekeyfragment : Item
|
||||
{
|
||||
[Constructable]
|
||||
public Bluekeyfragment()
|
||||
: base(0x1012)
|
||||
{
|
||||
this.Movable = false;
|
||||
this.Hue = 0x5D;
|
||||
}
|
||||
|
||||
public Bluekeyfragment(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1111646;
|
||||
}
|
||||
}
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
from.SendMessage("You make a copy of the key in your pack");
|
||||
|
||||
BlueKey1 bluekey = new BlueKey1();
|
||||
if (!from.AddToBackpack(bluekey))
|
||||
bluekey.Delete();
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
35
Scripts/Items/Quest/BouraSkin.cs
Normal file
35
Scripts/Items/Quest/BouraSkin.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BouraSkin : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1112900; } }// Boura Skin
|
||||
|
||||
[Constructable]
|
||||
public BouraSkin()
|
||||
: base(0x11F4)
|
||||
{
|
||||
LootType = LootType.Blessed;
|
||||
Weight = 1.0;
|
||||
Hue = 0x292;
|
||||
}
|
||||
|
||||
public BouraSkin(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/BridesLetter.cs
Normal file
41
Scripts/Items/Quest/BridesLetter.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BridesLetter : Item
|
||||
{
|
||||
[Constructable]
|
||||
public BridesLetter()
|
||||
: base(0x14ED)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public BridesLetter(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075301;
|
||||
}
|
||||
}// Bride's Letter
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/BritannianWool.cs
Normal file
41
Scripts/Items/Quest/BritannianWool.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Targeting;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BritannianWool : Wool
|
||||
{
|
||||
public override int LabelNumber { get { return 1113242; } } // Britannian wool
|
||||
|
||||
[Constructable]
|
||||
public BritannianWool() : this(1)
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BritannianWool(int amount) : base(0x101F)
|
||||
{
|
||||
Stackable = true;
|
||||
Hue = 992;
|
||||
Weight = 4.0;
|
||||
Amount = amount;
|
||||
}
|
||||
|
||||
public BritannianWool(Serial serial) : base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/BrokenCrystals.cs
Normal file
41
Scripts/Items/Quest/BrokenCrystals.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BrokenCrystals : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public BrokenCrystals()
|
||||
: base(0x2247)
|
||||
{
|
||||
this.Weight = 1;
|
||||
this.Hue = 0x2B2;
|
||||
}
|
||||
|
||||
public BrokenCrystals(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074261;
|
||||
}
|
||||
}// broken crystal
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
33
Scripts/Items/Quest/Cauldron.cs
Normal file
33
Scripts/Items/Quest/Cauldron.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class Cauldron : Item
|
||||
{
|
||||
public override int LabelNumber {get {return 1153777;} } // a cauldron
|
||||
|
||||
[Constructable]
|
||||
public Cauldron()
|
||||
: base(0x9ED)
|
||||
{
|
||||
Weight = 1.0;
|
||||
}
|
||||
|
||||
public Cauldron(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
34
Scripts/Items/Quest/ChylothShroud.cs
Normal file
34
Scripts/Items/Quest/ChylothShroud.cs
Normal file
@@ -0,0 +1,34 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Engines.Quests.Doom
|
||||
{
|
||||
public class ChylothShroud : Item
|
||||
{
|
||||
[Constructable]
|
||||
public ChylothShroud()
|
||||
: base(0x204E)
|
||||
{
|
||||
this.Hue = 0x846;
|
||||
this.Layer = Layer.OuterTorso;
|
||||
}
|
||||
|
||||
public ChylothShroud(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/ChylothStaff.cs
Normal file
40
Scripts/Items/Quest/ChylothStaff.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
|
||||
namespace Server.Engines.Quests.Doom
|
||||
{
|
||||
public class ChylothStaff : BlackStaff
|
||||
{
|
||||
[Constructable]
|
||||
public ChylothStaff()
|
||||
{
|
||||
this.Hue = 0x482;
|
||||
}
|
||||
|
||||
public ChylothStaff(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1041111;
|
||||
}
|
||||
}// a magic staff
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
54
Scripts/Items/Quest/CitadelKey.cs
Normal file
54
Scripts/Items/Quest/CitadelKey.cs
Normal file
@@ -0,0 +1,54 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CitadelKey : MasterKey
|
||||
{
|
||||
public CitadelKey()
|
||||
: base(0x1012)
|
||||
{
|
||||
this.Hue = 0x489;
|
||||
}
|
||||
|
||||
public CitadelKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074344;
|
||||
}
|
||||
}// black order key
|
||||
public override int Lifespan
|
||||
{
|
||||
get
|
||||
{
|
||||
return 600;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override bool CanOfferConfirmation(Mobile from)
|
||||
{
|
||||
if (from.Region != null && from.Region.IsPartOf("TheCitadel"))
|
||||
return base.CanOfferConfirmation(from);
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/CoagulatedLegs.cs
Normal file
40
Scripts/Items/Quest/CoagulatedLegs.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CoagulatedLegs : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public CoagulatedLegs()
|
||||
: base(0x1CDF)
|
||||
{
|
||||
this.Weight = 1;
|
||||
}
|
||||
|
||||
public CoagulatedLegs(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074327;
|
||||
}
|
||||
}// coagulated legs
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/CoilsFang.cs
Normal file
41
Scripts/Items/Quest/CoilsFang.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CoilsFang : Item
|
||||
{
|
||||
[Constructable]
|
||||
public CoilsFang()
|
||||
: base(0x10E8)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Hue = 0x487;
|
||||
}
|
||||
|
||||
public CoilsFang(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074229;
|
||||
}
|
||||
}// Coil's Fang
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/CompletedTuitionReimbursementForm.cs
Normal file
41
Scripts/Items/Quest/CompletedTuitionReimbursementForm.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CompletedTuitionReimbursementForm : Item
|
||||
{
|
||||
[Constructable]
|
||||
public CompletedTuitionReimbursementForm()
|
||||
: base(0x14F0)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1;
|
||||
}
|
||||
|
||||
public CompletedTuitionReimbursementForm(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074625;
|
||||
}
|
||||
}// Completed Tuition Reimbursement Form
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
106
Scripts/Items/Quest/CreepyWeeds.cs
Normal file
106
Scripts/Items/Quest/CreepyWeeds.cs
Normal file
@@ -0,0 +1,106 @@
|
||||
using System;
|
||||
using Server;
|
||||
using Server.Network;
|
||||
using Server.Regions;
|
||||
using Server.Mobiles;
|
||||
using Server.Items;
|
||||
using Server.Targeting;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CreepyWeeds : Item
|
||||
{
|
||||
[Constructable]
|
||||
public CreepyWeeds()
|
||||
: base(0x0CB8)
|
||||
{
|
||||
Name = "Creepy Weeds";
|
||||
Weight = 1;
|
||||
Movable = false;
|
||||
|
||||
Timer.DelayCall(TimeSpan.FromMinutes(10.0), delegate()
|
||||
{
|
||||
Delete();
|
||||
});
|
||||
}
|
||||
|
||||
public CreepyWeeds(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (!CheckUse(from))
|
||||
return;
|
||||
|
||||
Map map = Map;
|
||||
Point3D loc = Location;
|
||||
|
||||
if (map != null && map != Map.Internal && from.InRange(loc, 1) && from.InLOS(this))
|
||||
{
|
||||
Delete();
|
||||
|
||||
switch (Utility.Random(18))
|
||||
{
|
||||
case 0:
|
||||
new Snake().MoveToWorld(loc, map);
|
||||
break;
|
||||
case 1:
|
||||
new Mongbat().MoveToWorld(loc, map);
|
||||
break;
|
||||
case 2:
|
||||
new SilverSerpent().MoveToWorld(loc, map);
|
||||
break;
|
||||
case 3:
|
||||
new Raptor().MoveToWorld(loc, map);
|
||||
break;
|
||||
case 4:
|
||||
new Ballem().MoveToWorld(loc, map);
|
||||
break;
|
||||
case 5: case 10: case 15:
|
||||
if (Utility.RandomDouble() < 0.20)
|
||||
{
|
||||
from.AddToBackpack(new FNPitchfork());
|
||||
|
||||
from.SendMessage("You find Farmer Nash's pitchfork under one of the brambles of weeds. You pick up the pitchfork and put it in your backpack.");
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
|
||||
protected virtual bool CheckUse(Mobile from)
|
||||
{
|
||||
PlayerMobile pm = from as PlayerMobile;
|
||||
|
||||
if (Deleted || !IsAccessibleTo(from))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else if (from.Map != Map || !from.InRange(GetWorldLocation(), 1))
|
||||
{
|
||||
from.LocalOverheadMessage(MessageType.Regular, 0x3B2, 1019045); // I can't reach that.
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/CrushedCrystals.cs
Normal file
41
Scripts/Items/Quest/CrushedCrystals.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CrushedCrystals : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public CrushedCrystals()
|
||||
: base(0x223C)
|
||||
{
|
||||
this.Weight = 1;
|
||||
this.Hue = 0x47E;
|
||||
}
|
||||
|
||||
public CrushedCrystals(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074262;
|
||||
}
|
||||
}// crushed crystal pieces
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
208
Scripts/Items/Quest/CrystalBallOfKnowledge.cs
Normal file
208
Scripts/Items/Quest/CrystalBallOfKnowledge.cs
Normal file
@@ -0,0 +1,208 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Server;
|
||||
using Server.Gumps;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CrystalBallOfKnowledge : Item
|
||||
{
|
||||
private static SkillName[] _ExcludedSkills =
|
||||
{
|
||||
SkillName.Meditation, SkillName.Focus
|
||||
};
|
||||
|
||||
public override int LabelNumber { get { return 1112568; } } // Crystal Ball of Knowledge
|
||||
|
||||
private bool m_Active;
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public bool Active
|
||||
{
|
||||
get { return m_Active; }
|
||||
set
|
||||
{
|
||||
if (m_Active != value)
|
||||
{
|
||||
m_Active = value;
|
||||
InvalidateProperties();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public CrystalBallOfKnowledge()
|
||||
: base(0xE2E)
|
||||
{
|
||||
Weight = 10.0;
|
||||
Light = LightType.Circle150;
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public CrystalBallOfKnowledge(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (!IsChildOf(from.Backpack))
|
||||
{
|
||||
// You must have the object in your backpack to use it.
|
||||
from.SendLocalizedMessage(1042010);
|
||||
}
|
||||
/*else if ( ??? ) // TODO (SA)
|
||||
{
|
||||
// You cannot use the Crystal Ball of Knowledge right now.
|
||||
from.SendLocalizedMessage( 1112569 );
|
||||
}*/
|
||||
else if (!from.HasGump(typeof(ToggleActivationGump)))
|
||||
{
|
||||
from.SendGump(new ToggleActivationGump(this));
|
||||
}
|
||||
}
|
||||
|
||||
public static bool IsAllowed(SkillName skill)
|
||||
{
|
||||
return !_ExcludedSkills.Any(sk => sk == skill);
|
||||
}
|
||||
|
||||
public static bool HasActiveBall(Mobile from)
|
||||
{
|
||||
if (from.Backpack == null)
|
||||
return false;
|
||||
|
||||
CrystalBallOfKnowledge[] balls = from.Backpack.FindItemsByType<CrystalBallOfKnowledge>().ToArray();
|
||||
|
||||
for (int i = 0; i < balls.Length; i++)
|
||||
if (balls[i].Active)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public static void TellSkillDifficultyActive(Mobile from, SkillName skill, double chance)
|
||||
{
|
||||
if (HasActiveBall(from))
|
||||
{
|
||||
GiveSkillDifficulty(from, skill, chance);
|
||||
}
|
||||
}
|
||||
|
||||
public static void TellSkillDifficulty(Mobile from, SkillName skill, double chance)
|
||||
{
|
||||
if (HasActiveBall(from) && IsAllowed(skill))
|
||||
{
|
||||
GiveSkillDifficulty(from, skill, chance);
|
||||
}
|
||||
}
|
||||
|
||||
public static void GiveSkillDifficulty(Mobile from, SkillName skill, double chance)
|
||||
{
|
||||
Utility.FixMinMax(ref chance, 0.0, 1.0);
|
||||
|
||||
int number;
|
||||
|
||||
if (chance == 0.0)
|
||||
number = 1078457; // ~1_skillname~ Difficulty: Too Challenging
|
||||
else if (chance <= 0.1)
|
||||
number = 1078458; // ~1_skillname~ Difficulty: Very Challenging
|
||||
else if (chance <= 0.25)
|
||||
number = 1078459; // ~1_skillname~ Difficulty: Challenging
|
||||
else if (chance <= 0.75)
|
||||
number = 1078460; // ~1_skillname~ Difficulty: Optimal
|
||||
else if (chance <= 0.9)
|
||||
number = 1078461; // ~1_skillname~ Difficulty: Easy
|
||||
else if (chance <= 1.0)
|
||||
number = 1078462; // ~1_skillname~ Difficulty: Very Easy
|
||||
else
|
||||
number = 1078463; // ~1_skillname~ Difficulty: Too Easy
|
||||
|
||||
from.SendLocalizedMessage(number, SkillInfo.Table[(int)skill].Name);
|
||||
}
|
||||
|
||||
public override void GetProperties(ObjectPropertyList list)
|
||||
{
|
||||
base.GetProperties(list);
|
||||
|
||||
if (m_Active)
|
||||
list.Add(502695); // turned on
|
||||
else
|
||||
list.Add(502696); // turned off
|
||||
}
|
||||
|
||||
public override bool OnDragLift(Mobile from)
|
||||
{
|
||||
if (!base.OnDragLift(from))
|
||||
return false;
|
||||
|
||||
Active = false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.Write((bool)m_Active);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
m_Active = reader.ReadBool();
|
||||
}
|
||||
|
||||
public class ToggleActivationGump : Gump
|
||||
{
|
||||
private CrystalBallOfKnowledge m_Ball;
|
||||
|
||||
public ToggleActivationGump(CrystalBallOfKnowledge ball)
|
||||
: base(150, 200)
|
||||
{
|
||||
m_Ball = ball;
|
||||
|
||||
AddPage(0);
|
||||
|
||||
AddBackground(0, 0, 300, 150, 0xA28);
|
||||
|
||||
if (m_Ball.Active)
|
||||
AddHtmlLocalized(45, 20, 300, 35, 1011035, false, false); // Deactivate this item
|
||||
else
|
||||
AddHtmlLocalized(45, 20, 300, 35, 1011034, false, false); // Activate this item
|
||||
|
||||
AddButton(40, 53, 0xFA5, 0xFA7, 2, GumpButtonType.Reply, 0);
|
||||
AddHtmlLocalized(80, 55, 65, 35, 1011036, false, false); // OKAY
|
||||
|
||||
AddButton(150, 53, 0xFA5, 0xFA7, 1, GumpButtonType.Reply, 0);
|
||||
AddHtmlLocalized(190, 55, 100, 35, 1011012, false, false); // CANCEL
|
||||
}
|
||||
|
||||
public override void OnResponse(NetState sender, RelayInfo info)
|
||||
{
|
||||
Mobile from = sender.Mobile;
|
||||
|
||||
if (info.ButtonID == 2)
|
||||
{
|
||||
if (!m_Ball.Deleted && m_Ball.IsChildOf(from.Backpack))
|
||||
{
|
||||
m_Ball.Active = !m_Ball.Active;
|
||||
|
||||
if (m_Ball.Active)
|
||||
from.SendLocalizedMessage(1078486); // I will now tell you skill difficulty.
|
||||
else
|
||||
from.SendLocalizedMessage(1078485); // I will no longer tell you skill difficulty.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
70
Scripts/Items/Quest/CrystalCaveBarrier.cs
Normal file
70
Scripts/Items/Quest/CrystalCaveBarrier.cs
Normal file
@@ -0,0 +1,70 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Necro
|
||||
{
|
||||
public class CrystalCaveBarrier : Item
|
||||
{
|
||||
[Constructable]
|
||||
public CrystalCaveBarrier()
|
||||
: base(0x3967)
|
||||
{
|
||||
this.Movable = false;
|
||||
}
|
||||
|
||||
public CrystalCaveBarrier(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool OnMoveOver(Mobile m)
|
||||
{
|
||||
if (m.IsStaff())
|
||||
return true;
|
||||
|
||||
bool sendMessage = m.Player;
|
||||
|
||||
if (m is BaseCreature)
|
||||
m = ((BaseCreature)m).ControlMaster;
|
||||
|
||||
PlayerMobile pm = m as PlayerMobile;
|
||||
|
||||
if (pm != null)
|
||||
{
|
||||
QuestSystem qs = pm.Quest;
|
||||
|
||||
if (qs is DarkTidesQuest)
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(SpeakCavePasswordObjective));
|
||||
|
||||
if (obj != null && obj.Completed)
|
||||
{
|
||||
if (sendMessage)
|
||||
m.SendLocalizedMessage(1060648); // With Horus' permission, you are able to pass through the barrier.
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (sendMessage)
|
||||
m.SendLocalizedMessage(1060649, "", 0x66D); // Without the permission of the guardian Horus, the magic of the barrier prevents your passage.
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/CrystallineFragments.cs
Normal file
41
Scripts/Items/Quest/CrystallineFragments.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class CrystallineFragments : Item
|
||||
{
|
||||
[Constructable]
|
||||
public CrystallineFragments()
|
||||
: base(0x223B)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Hue = 0x47E;
|
||||
}
|
||||
|
||||
public CrystallineFragments(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073160;
|
||||
}
|
||||
}// Crystalline Fragments
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
71
Scripts/Items/Quest/DaemonBloodChest.cs
Normal file
71
Scripts/Items/Quest/DaemonBloodChest.cs
Normal file
@@ -0,0 +1,71 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Haven
|
||||
{
|
||||
public class DaemonBloodChest : MetalChest
|
||||
{
|
||||
[Constructable]
|
||||
public DaemonBloodChest()
|
||||
{
|
||||
this.Movable = false;
|
||||
}
|
||||
|
||||
public DaemonBloodChest(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null && player.InRange(this.GetWorldLocation(), 2))
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is UzeraanTurmoilQuest)
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(GetDaemonBloodObjective));
|
||||
|
||||
if ((obj != null && !obj.Completed) || UzeraanTurmoilQuest.HasLostDaemonBlood(player))
|
||||
{
|
||||
Item vial = new QuestDaemonBlood();
|
||||
|
||||
if (player.PlaceInBackpack(vial))
|
||||
{
|
||||
player.SendLocalizedMessage(1049331, "", 0x22); // You take a vial of blood from the chest and put it in your pack.
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
obj.Complete();
|
||||
}
|
||||
else
|
||||
{
|
||||
player.SendLocalizedMessage(1049338, "", 0x22); // You find a vial of blood, but can't pick it up because your pack is too full. Come back when you have more room in your pack.
|
||||
vial.Delete();
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
base.OnDoubleClick(from);
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/DarkTidesHorn.cs
Normal file
41
Scripts/Items/Quest/DarkTidesHorn.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Necro
|
||||
{
|
||||
public class DarkTidesHorn : HornOfRetreat
|
||||
{
|
||||
[Constructable]
|
||||
public DarkTidesHorn()
|
||||
{
|
||||
this.DestLoc = new Point3D(2103, 1319, -68);
|
||||
this.DestMap = Map.Malas;
|
||||
}
|
||||
|
||||
public DarkTidesHorn(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool ValidateUse(Mobile from)
|
||||
{
|
||||
PlayerMobile pm = from as PlayerMobile;
|
||||
|
||||
return (pm != null && pm.Quest is DarkTidesQuest);
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
74
Scripts/Items/Quest/DarkTidesTeleporter.cs
Normal file
74
Scripts/Items/Quest/DarkTidesTeleporter.cs
Normal file
@@ -0,0 +1,74 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Necro
|
||||
{
|
||||
public class DarkTidesTeleporter : DynamicTeleporter
|
||||
{
|
||||
[Constructable]
|
||||
public DarkTidesTeleporter()
|
||||
{
|
||||
}
|
||||
|
||||
public DarkTidesTeleporter(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool GetDestination(PlayerMobile player, ref Point3D loc, ref Map map)
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is DarkTidesQuest)
|
||||
{
|
||||
if (qs.IsObjectiveInProgress(typeof(FindMaabusTombObjective)))
|
||||
{
|
||||
loc = new Point3D(2038, 1263, -90);
|
||||
map = Map.Malas;
|
||||
qs.AddConversation(new RadarConversation());
|
||||
return true;
|
||||
}
|
||||
else if (qs.IsObjectiveInProgress(typeof(FindCrystalCaveObjective)))
|
||||
{
|
||||
loc = new Point3D(1194, 521, -90);
|
||||
map = Map.Malas;
|
||||
return true;
|
||||
}
|
||||
else if (qs.IsObjectiveInProgress(typeof(FindCityOfLightObjective)))
|
||||
{
|
||||
loc = new Point3D(1091, 519, -90);
|
||||
map = Map.Malas;
|
||||
return true;
|
||||
}
|
||||
else if (qs.IsObjectiveInProgress(typeof(ReturnToCrystalCaveObjective)))
|
||||
{
|
||||
loc = new Point3D(1194, 521, -90);
|
||||
map = Map.Malas;
|
||||
return true;
|
||||
}
|
||||
else if (DarkTidesQuest.HasLostCallingScroll(player))
|
||||
{
|
||||
loc = new Point3D(1194, 521, -90);
|
||||
map = Map.Malas;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
33
Scripts/Items/Quest/DeBoorShield.cs
Normal file
33
Scripts/Items/Quest/DeBoorShield.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DeBoorShield : MetalKiteShield
|
||||
{
|
||||
public override int LabelNumber { get { return 1075308; } } // Ancestral Shield
|
||||
public override bool HiddenQuestItemHue { get { return true; } }
|
||||
|
||||
[Constructable]
|
||||
public DeBoorShield()
|
||||
{
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public DeBoorShield(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0);//version
|
||||
}
|
||||
}
|
||||
}
|
||||
43
Scripts/Items/Quest/DisintegratingThesisNotes.cs
Normal file
43
Scripts/Items/Quest/DisintegratingThesisNotes.cs
Normal file
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DisintegratingThesisNotes : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public DisintegratingThesisNotes()
|
||||
: base(0xE36)
|
||||
{
|
||||
Weight = 1.0;
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public DisintegratingThesisNotes(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber { get {return 1074440;} } // Disintegrating Thesis Notes
|
||||
|
||||
public override DeathMoveResult OnInventoryDeath(Mobile parent)
|
||||
{
|
||||
if (!parent.Player && !parent.IsDeadBondedPet)
|
||||
return DeathMoveResult.MoveToCorpse;
|
||||
|
||||
return base.OnInventoryDeath(parent);
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/DragonFlameKey.cs
Normal file
42
Scripts/Items/Quest/DragonFlameKey.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DragonFlameKey : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public DragonFlameKey()
|
||||
: base(0x2002)
|
||||
{
|
||||
Weight = 2.0;
|
||||
Hue = 42;
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public DragonFlameKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074343;
|
||||
}
|
||||
}// dragon flame key
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/DragonFlameSectBadge.cs
Normal file
40
Scripts/Items/Quest/DragonFlameSectBadge.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DragonFlameSectBadge : Item
|
||||
{
|
||||
[Constructable]
|
||||
public DragonFlameSectBadge()
|
||||
: base(0x23E)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public DragonFlameSectBadge(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073141;
|
||||
}
|
||||
}// A Dragon Flame Sect Badge
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/DreadSpiderSilk.cs
Normal file
42
Scripts/Items/Quest/DreadSpiderSilk.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DreadSpiderSilk : Item
|
||||
{
|
||||
[Constructable]
|
||||
public DreadSpiderSilk()
|
||||
: base(0xDF8)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 4.0;
|
||||
this.Hue = 0x481;
|
||||
}
|
||||
|
||||
public DreadSpiderSilk(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075319;
|
||||
}
|
||||
}// Dread Spider Silk
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
34
Scripts/Items/Quest/DryadsBlessing.cs
Normal file
34
Scripts/Items/Quest/DryadsBlessing.cs
Normal file
@@ -0,0 +1,34 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DryadsBlessing : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public DryadsBlessing()
|
||||
: base(0x21C)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x488; // TOOD check
|
||||
}
|
||||
|
||||
public DryadsBlessing(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
54
Scripts/Items/Quest/EminosKatana.cs
Normal file
54
Scripts/Items/Quest/EminosKatana.cs
Normal file
@@ -0,0 +1,54 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Ninja
|
||||
{
|
||||
public class EminosKatana : QuestItem
|
||||
{
|
||||
[Constructable]
|
||||
public EminosKatana()
|
||||
: base(0x13FF)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public EminosKatana(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1063214;
|
||||
}
|
||||
}// Daimyo Emino's Katana
|
||||
public override bool CanDrop(PlayerMobile player)
|
||||
{
|
||||
EminosUndertakingQuest qs = player.Quest as EminosUndertakingQuest;
|
||||
|
||||
if (qs == null)
|
||||
return true;
|
||||
|
||||
/*return !qs.IsObjectiveInProgress( typeof( ReturnSwordObjective ) )
|
||||
&& !qs.IsObjectiveInProgress( typeof( SlayHenchmenObjective ) )
|
||||
&& !qs.IsObjectiveInProgress( typeof( GiveEminoSwordObjective ) );*/
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
159
Scripts/Items/Quest/EminosKatanaChest.cs
Normal file
159
Scripts/Items/Quest/EminosKatanaChest.cs
Normal file
@@ -0,0 +1,159 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Quests.Ninja
|
||||
{
|
||||
public class EminosKatanaChest : WoodenChest
|
||||
{
|
||||
[Constructable]
|
||||
public EminosKatanaChest()
|
||||
{
|
||||
this.Movable = false;
|
||||
this.ItemID = 0xE42;
|
||||
|
||||
this.GenerateTreasure();
|
||||
}
|
||||
|
||||
public EminosKatanaChest(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool IsDecoContainer
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null && player.InRange(this.GetWorldLocation(), 2))
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is EminosUndertakingQuest)
|
||||
{
|
||||
if (EminosUndertakingQuest.HasLostEminosKatana(from))
|
||||
{
|
||||
Item katana = new EminosKatana();
|
||||
|
||||
if (!player.PlaceInBackpack(katana))
|
||||
{
|
||||
katana.Delete();
|
||||
player.SendLocalizedMessage(1046260); // You need to clear some space in your inventory to continue with the quest. Come back here when you have more space in your inventory.
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(HallwayWalkObjective));
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
{
|
||||
Item katana = new EminosKatana();
|
||||
|
||||
if (player.PlaceInBackpack(katana))
|
||||
{
|
||||
this.GenerateTreasure();
|
||||
obj.Complete();
|
||||
}
|
||||
else
|
||||
{
|
||||
katana.Delete();
|
||||
player.SendLocalizedMessage(1046260); // You need to clear some space in your inventory to continue with the quest. Come back here when you have more space in your inventory.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
base.OnDoubleClick(from);
|
||||
}
|
||||
|
||||
public override bool CheckHold(Mobile m, Item item, bool message, bool checkItems, int plusItems, int plusWeight)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool CheckItemUse(Mobile from, Item item)
|
||||
{
|
||||
return item == this;
|
||||
}
|
||||
|
||||
public override bool CheckLift(Mobile from, Item item, ref LRReason reject)
|
||||
{
|
||||
if (from.AccessLevel >= AccessLevel.GameMaster)
|
||||
return true;
|
||||
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null && player.Quest is EminosUndertakingQuest)
|
||||
{
|
||||
HallwayWalkObjective obj = player.Quest.FindObjective(typeof(HallwayWalkObjective)) as HallwayWalkObjective;
|
||||
|
||||
if (obj != null)
|
||||
{
|
||||
if (obj.StolenTreasure)
|
||||
from.SendLocalizedMessage(1063247); // The guard is watching you carefully! It would be unwise to remove another item from here.
|
||||
else
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void OnItemLifted(Mobile from, Item item)
|
||||
{
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null && player.Quest is EminosUndertakingQuest)
|
||||
{
|
||||
HallwayWalkObjective obj = player.Quest.FindObjective(typeof(HallwayWalkObjective)) as HallwayWalkObjective;
|
||||
|
||||
if (obj != null)
|
||||
obj.StolenTreasure = true;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
|
||||
private void GenerateTreasure()
|
||||
{
|
||||
for (int i = this.Items.Count - 1; i >= 0; i--)
|
||||
this.Items[i].Delete();
|
||||
|
||||
for (int i = 0; i < 75; i++)
|
||||
{
|
||||
switch ( Utility.Random(3) )
|
||||
{
|
||||
case 0:
|
||||
this.DropItem(new GoldBracelet());
|
||||
break;
|
||||
case 1:
|
||||
this.DropItem(new GoldRing());
|
||||
break;
|
||||
case 2:
|
||||
this.DropItem(Loot.RandomGem());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
141
Scripts/Items/Quest/EnchantedPaints.cs
Normal file
141
Scripts/Items/Quest/EnchantedPaints.cs
Normal file
@@ -0,0 +1,141 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
using Server.Targeting;
|
||||
|
||||
namespace Server.Engines.Quests.Collector
|
||||
{
|
||||
public class EnchantedPaints : QuestItem
|
||||
{
|
||||
[Constructable]
|
||||
public EnchantedPaints()
|
||||
: base(0xFC1)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public EnchantedPaints(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool CanDrop(PlayerMobile player)
|
||||
{
|
||||
CollectorQuest qs = player.Quest as CollectorQuest;
|
||||
|
||||
if (qs == null)
|
||||
return true;
|
||||
|
||||
/*return !( qs.IsObjectiveInProgress( typeof( CaptureImagesObjective ) )
|
||||
|| qs.IsObjectiveInProgress( typeof( ReturnImagesObjective ) ) );*/
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null)
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is CollectorQuest)
|
||||
{
|
||||
if (qs.IsObjectiveInProgress(typeof(CaptureImagesObjective)))
|
||||
{
|
||||
player.SendAsciiMessage(0x59, "Target the creature whose image you wish to create.");
|
||||
player.Target = new InternalTarget(this);
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
from.SendLocalizedMessage(1010085); // You cannot use this.
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
private class InternalTarget : Target
|
||||
{
|
||||
private readonly EnchantedPaints m_Paints;
|
||||
public InternalTarget(EnchantedPaints paints)
|
||||
: base(-1, false, TargetFlags.None)
|
||||
{
|
||||
this.CheckLOS = false;
|
||||
this.m_Paints = paints;
|
||||
}
|
||||
|
||||
protected override void OnTarget(Mobile from, object targeted)
|
||||
{
|
||||
if (this.m_Paints.Deleted || !this.m_Paints.IsChildOf(from.Backpack))
|
||||
return;
|
||||
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null)
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is CollectorQuest)
|
||||
{
|
||||
CaptureImagesObjective obj = qs.FindObjective(typeof(CaptureImagesObjective)) as CaptureImagesObjective;
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
{
|
||||
if (targeted is Mobile)
|
||||
{
|
||||
ImageType image;
|
||||
CaptureResponse response = obj.CaptureImage((targeted.GetType().Name == "GreaterMongbat" ? new Mongbat().GetType() : targeted.GetType()), out image);
|
||||
|
||||
switch ( response )
|
||||
{
|
||||
case CaptureResponse.Valid:
|
||||
{
|
||||
player.SendLocalizedMessage(1055125); // The enchanted paints swirl for a moment then an image begins to take shape. *Click*
|
||||
player.AddToBackpack(new PaintedImage(image));
|
||||
|
||||
break;
|
||||
}
|
||||
case CaptureResponse.AlreadyDone:
|
||||
{
|
||||
player.SendAsciiMessage(0x2C, "You have already captured the image of this creature");
|
||||
|
||||
break;
|
||||
}
|
||||
case CaptureResponse.Invalid:
|
||||
{
|
||||
player.SendLocalizedMessage(1055124); // You have no interest in capturing the image of this creature.
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
player.SendAsciiMessage(0x35, "You have no interest in that.");
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
from.SendLocalizedMessage(1010085); // You cannot use this.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
85
Scripts/Items/Quest/FoolishGold.cs
Normal file
85
Scripts/Items/Quest/FoolishGold.cs
Normal file
@@ -0,0 +1,85 @@
|
||||
using System;
|
||||
using Server;
|
||||
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class NiporailemsTreasure : Item
|
||||
{
|
||||
public override int LabelNumber { get { return ItemID == 0x11EA ? 1112115 : 1112113; } } // Niporailem's Treasure : Treasure Sand
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public override bool Decays { get { return Link != null && !Link.Deleted ? base.Decays : true; } }
|
||||
|
||||
[CommandProperty(AccessLevel.Decorator)]
|
||||
public override TimeSpan DecayTime { get { return TimeSpan.FromMinutes(15); } }
|
||||
|
||||
[CommandProperty(AccessLevel.Decorator)]
|
||||
public Mobile Link { get; set; }
|
||||
|
||||
public NiporailemsTreasure(Mobile link)
|
||||
: base(0xEEF)
|
||||
{
|
||||
Link = link;
|
||||
Weight = 100.0;
|
||||
}
|
||||
|
||||
public NiporailemsTreasure(Serial serial) : base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool DropToWorld(Mobile from, Point3D p)
|
||||
{
|
||||
bool convert = base.DropToWorld(from, p);
|
||||
|
||||
if (convert)
|
||||
ConvertItem(from);
|
||||
|
||||
return convert;
|
||||
}
|
||||
|
||||
public override bool DropToMobile(Mobile from, Mobile target, Point3D p)
|
||||
{
|
||||
bool convert = base.DropToMobile(from, target, p);
|
||||
|
||||
if (convert)
|
||||
ConvertItem(from);
|
||||
|
||||
return convert;
|
||||
}
|
||||
|
||||
public override bool DropToItem(Mobile from, Item target, Point3D p)
|
||||
{
|
||||
bool convert = base.DropToItem(from, target, p);
|
||||
|
||||
if (convert && Parent != from.Backpack)
|
||||
ConvertItem(from);
|
||||
|
||||
return convert;
|
||||
}
|
||||
|
||||
public virtual void ConvertItem(Mobile from)
|
||||
{
|
||||
from.SendLocalizedMessage(1112112); // To carry the burden of greed!
|
||||
|
||||
ItemID = 0x11EA;
|
||||
Weight = 25.0;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)1); // version
|
||||
|
||||
writer.Write(Link);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
|
||||
Link = reader.ReadMobile();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/FriendOfTheLibraryToken.cs
Normal file
41
Scripts/Items/Quest/FriendOfTheLibraryToken.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class FriendOfTheLibraryToken : BaseTalisman
|
||||
{
|
||||
[Constructable]
|
||||
public FriendOfTheLibraryToken()
|
||||
: base(0x2F58)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x28A;
|
||||
}
|
||||
|
||||
public FriendOfTheLibraryToken(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073136;
|
||||
}
|
||||
}// Friend of the Library Token (allows donations to be made)
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
50
Scripts/Items/Quest/GamanHorn.cs
Normal file
50
Scripts/Items/Quest/GamanHorn.cs
Normal file
@@ -0,0 +1,50 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GamanHorns : Item
|
||||
{
|
||||
[Constructable]
|
||||
public GamanHorns()
|
||||
: this(1)
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public GamanHorns(int amount)
|
||||
: base(0x1084)
|
||||
{
|
||||
LootType = LootType.Blessed;
|
||||
Stackable = true;
|
||||
Amount = amount;
|
||||
Weight = 1;
|
||||
Hue = 0x395;
|
||||
}
|
||||
|
||||
public GamanHorns(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074557;
|
||||
}
|
||||
}// Gaman Horns
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
79
Scripts/Items/Quest/GaramonsBook.cs
Normal file
79
Scripts/Items/Quest/GaramonsBook.cs
Normal file
@@ -0,0 +1,79 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GaramonsBook : RedBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent(
|
||||
"A Journal", "Garamon",
|
||||
new BookPageInfo(
|
||||
"Today I have hope again.",
|
||||
"It has been too many",
|
||||
"days since my brother",
|
||||
"Tyball and I inadvertent",
|
||||
"ly released the Slasher",
|
||||
"of Veils in this world.",
|
||||
"How could we have known",
|
||||
"our research in planar",
|
||||
"travel would have such",
|
||||
"dire consequences?"),
|
||||
new BookPageInfo(
|
||||
"But we have devised a",
|
||||
"plan. We completed the",
|
||||
"construction of a cham",
|
||||
"ber of virtue. Tonight,",
|
||||
"I will lure the Slasher",
|
||||
"of Veils inside it so",
|
||||
"it's virtuous energies",
|
||||
"may weaken the beast!"),
|
||||
new BookPageInfo(
|
||||
"Tyball will lock us in",
|
||||
"while I open a rip back",
|
||||
"to the Slasher's own",
|
||||
"plane, and lead him",
|
||||
"through. A portal already",
|
||||
"awaits me in that foul",
|
||||
"place, which will lead me",
|
||||
"back here to safety."),
|
||||
new BookPageInfo(
|
||||
"If all goes according to",
|
||||
"plan, we will have undone",
|
||||
"the wrong we brought onto",
|
||||
"Britannia."),
|
||||
new BookPageInfo(
|
||||
"We will have redeemed",
|
||||
"ourselves. May the Virtues",
|
||||
"give us strength..."));
|
||||
[Constructable]
|
||||
public GaramonsBook()
|
||||
: base(false)
|
||||
{
|
||||
}
|
||||
|
||||
public GaramonsBook(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override BookContent DefaultContent
|
||||
{
|
||||
get
|
||||
{
|
||||
return Content;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
74
Scripts/Items/Quest/GaramonsBook1.cs
Normal file
74
Scripts/Items/Quest/GaramonsBook1.cs
Normal file
@@ -0,0 +1,74 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GaramonsBook1 : BrownBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent(
|
||||
"A Journal", "Tyball",
|
||||
new BookPageInfo(
|
||||
"He speaks to me...",
|
||||
"I can hear him. The",
|
||||
"beast... He knows of",
|
||||
"our plan. But how?",
|
||||
"Such wonders, such",
|
||||
"powers and such wealth",
|
||||
"he promises. But at what"),
|
||||
new BookPageInfo(
|
||||
"cost? That it could ask",
|
||||
"me to sacrifice my",
|
||||
"brother I cannot. I will",
|
||||
"not. No knowledge, no",
|
||||
"greatness could warrant",
|
||||
"such infamy.",
|
||||
"But the seed of a doubt"),
|
||||
new BookPageInfo(
|
||||
"is gnawing at me. Did",
|
||||
"the Slasher make the",
|
||||
"same offer to my",
|
||||
"brother? Is he playing",
|
||||
"us against the other?",
|
||||
"Would Garamon even enter",
|
||||
"tain the thought? No, not",
|
||||
"my virtuous brother if he"),
|
||||
new BookPageInfo(
|
||||
"did, I would need to",
|
||||
"strike first, only to",
|
||||
"protect myself of course.",
|
||||
"I must banish the doubts",
|
||||
"from my mind. They are",
|
||||
"like poison. We cannot let",
|
||||
"this fiend divide us."));
|
||||
[Constructable]
|
||||
public GaramonsBook1()
|
||||
: base(false)
|
||||
{
|
||||
}
|
||||
|
||||
public GaramonsBook1(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override BookContent DefaultContent
|
||||
{
|
||||
get
|
||||
{
|
||||
return Content;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/GelatanousSkull.cs
Normal file
40
Scripts/Items/Quest/GelatanousSkull.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GelatanousSkull : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public GelatanousSkull()
|
||||
: base(0x1AE0)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public GelatanousSkull(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074328;
|
||||
}
|
||||
}// gelatanous skull
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/GiftForArielle.cs
Normal file
42
Scripts/Items/Quest/GiftForArielle.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GiftForArielle : Item
|
||||
{
|
||||
[Constructable]
|
||||
public GiftForArielle()
|
||||
: base(0x1882)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1;
|
||||
this.Hue = 0x2C4;
|
||||
}
|
||||
|
||||
public GiftForArielle(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074356;
|
||||
}
|
||||
}// gift for arielle
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/GnawsFang.cs
Normal file
42
Scripts/Items/Quest/GnawsFang.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GnawsFang : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public GnawsFang()
|
||||
: base(0x10E8)
|
||||
{
|
||||
Weight = 1;
|
||||
Hue = 0x174; // TODO check
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public GnawsFang(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074332;
|
||||
}
|
||||
}// gnaw's fang
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
35
Scripts/Items/Quest/GoldenSkull.cs
Normal file
35
Scripts/Items/Quest/GoldenSkull.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Engines.Quests.Doom
|
||||
{
|
||||
public class GoldenSkull : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1061619; } }// a golden skull
|
||||
|
||||
[Constructable]
|
||||
public GoldenSkull()
|
||||
: base(Utility.Random(0x1AE2, 3))
|
||||
{
|
||||
Weight = 1.0;
|
||||
Hue = 0x8A5;
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public GoldenSkull(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
43
Scripts/Items/Quest/GrandGrimoire.cs
Normal file
43
Scripts/Items/Quest/GrandGrimoire.cs
Normal file
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Engines.Quests.Doom
|
||||
{
|
||||
public class GrandGrimoire : Item
|
||||
{
|
||||
[Constructable]
|
||||
public GrandGrimoire()
|
||||
: base(0xEFA)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x835;
|
||||
this.Layer = Layer.OneHanded;
|
||||
this.LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public GrandGrimoire(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1060801;
|
||||
}
|
||||
}// The Grand Grimoire
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/GrobusFur.cs
Normal file
41
Scripts/Items/Quest/GrobusFur.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class GrobusFur : Item
|
||||
{
|
||||
[Constructable]
|
||||
public GrobusFur()
|
||||
: base(0x11F4)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Hue = 0x455;
|
||||
}
|
||||
|
||||
public GrobusFur(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074676;
|
||||
}
|
||||
}// Grobu's Fur
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
82
Scripts/Items/Quest/GuardianBarrier.cs
Normal file
82
Scripts/Items/Quest/GuardianBarrier.cs
Normal file
@@ -0,0 +1,82 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Ninja
|
||||
{
|
||||
public class GuardianBarrier : Item
|
||||
{
|
||||
[Constructable]
|
||||
public GuardianBarrier()
|
||||
: base(0x3967)
|
||||
{
|
||||
this.Movable = false;
|
||||
this.Visible = false;
|
||||
}
|
||||
|
||||
public GuardianBarrier(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool OnMoveOver(Mobile m)
|
||||
{
|
||||
if (m.IsStaff())
|
||||
return true;
|
||||
|
||||
// If the mobile is to the north of the barrier, allow him to pass
|
||||
if (this.Y >= m.Y)
|
||||
return true;
|
||||
|
||||
if (m is BaseCreature)
|
||||
{
|
||||
Mobile master = ((BaseCreature)m).GetMaster();
|
||||
|
||||
// Allow creatures to cross from the south to the north only if their master is near to the north
|
||||
if (master != null && this.Y >= master.Y && master.InRange(this, 4))
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
PlayerMobile pm = m as PlayerMobile;
|
||||
|
||||
if (pm != null)
|
||||
{
|
||||
EminosUndertakingQuest qs = pm.Quest as EminosUndertakingQuest;
|
||||
|
||||
if (qs != null)
|
||||
{
|
||||
SneakPastGuardiansObjective obj = qs.FindObjective(typeof(SneakPastGuardiansObjective)) as SneakPastGuardiansObjective;
|
||||
|
||||
if (obj != null)
|
||||
{
|
||||
if (m.Hidden)
|
||||
return true; // Hidden ninjas can pass
|
||||
|
||||
if (!obj.TaughtHowToUseSkills)
|
||||
{
|
||||
obj.TaughtHowToUseSkills = true;
|
||||
qs.AddConversation(new NeedToHideConversation());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
108
Scripts/Items/Quest/HagApprenticeCorpse.cs
Normal file
108
Scripts/Items/Quest/HagApprenticeCorpse.cs
Normal file
@@ -0,0 +1,108 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Server.Items;
|
||||
using Server.Misc;
|
||||
using Server.Mobiles;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Quests.Hag
|
||||
{
|
||||
public class HagApprenticeCorpse : Corpse
|
||||
{
|
||||
[Constructable]
|
||||
public HagApprenticeCorpse()
|
||||
: base(GetOwner(), GetEquipment())
|
||||
{
|
||||
this.Direction = Direction.South;
|
||||
|
||||
foreach (Item item in this.EquipItems)
|
||||
{
|
||||
this.DropItem(item);
|
||||
}
|
||||
}
|
||||
|
||||
public HagApprenticeCorpse(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void AddNameProperty(ObjectPropertyList list)
|
||||
{
|
||||
list.Add("a charred corpse");
|
||||
}
|
||||
|
||||
public override void OnSingleClick(Mobile from)
|
||||
{
|
||||
int hue = Notoriety.GetHue(NotorietyHandlers.CorpseNotoriety(from, this));
|
||||
|
||||
from.Send(new AsciiMessage(this.Serial, this.ItemID, MessageType.Label, hue, 3, "", "a charred corpse"));
|
||||
}
|
||||
|
||||
public override void Open(Mobile from, bool checkSelfLoot)
|
||||
{
|
||||
if (!from.InRange(this.GetWorldLocation(), 2))
|
||||
return;
|
||||
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null)
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is WitchApprenticeQuest)
|
||||
{
|
||||
FindApprenticeObjective obj = qs.FindObjective(typeof(FindApprenticeObjective)) as FindApprenticeObjective;
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
{
|
||||
if (obj.Corpse == this)
|
||||
{
|
||||
obj.Complete();
|
||||
this.Delete();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.SendLocalizedMessageTo(from, 1055047); // You examine the corpse, but it doesn't fit the description of the particular apprentice the Hag tasked you with finding.
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this.SendLocalizedMessageTo(from, 1055048); // You examine the corpse, but find nothing of interest.
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
private static Mobile GetOwner()
|
||||
{
|
||||
Mobile apprentice = new Mobile();
|
||||
|
||||
apprentice.Hue = Utility.RandomSkinHue();
|
||||
apprentice.Female = false;
|
||||
apprentice.Body = 0x190;
|
||||
|
||||
apprentice.Delete();
|
||||
|
||||
return apprentice;
|
||||
}
|
||||
|
||||
private static List<Item> GetEquipment()
|
||||
{
|
||||
return new List<Item>();
|
||||
}
|
||||
}
|
||||
}
|
||||
44
Scripts/Items/Quest/HaochisKatana.cs
Normal file
44
Scripts/Items/Quest/HaochisKatana.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Samurai
|
||||
{
|
||||
public class HaochisKatana : QuestItem
|
||||
{
|
||||
public override int LabelNumber { get { return 1063165; } }// Daimyo Haochi's Katana
|
||||
|
||||
[Constructable]
|
||||
public HaochisKatana()
|
||||
: base(0x13FF)
|
||||
{
|
||||
Weight = 1.0;
|
||||
}
|
||||
|
||||
public HaochisKatana(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool CanDrop(PlayerMobile player)
|
||||
{
|
||||
HaochisTrialsQuest qs = player.Quest as HaochisTrialsQuest;
|
||||
|
||||
if (qs == null)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
81
Scripts/Items/Quest/HaochisKatanaGenerator.cs
Normal file
81
Scripts/Items/Quest/HaochisKatanaGenerator.cs
Normal file
@@ -0,0 +1,81 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Samurai
|
||||
{
|
||||
public class HaochisKatanaGenerator : Item
|
||||
{
|
||||
[Constructable]
|
||||
public HaochisKatanaGenerator()
|
||||
: base(0x1B7B)
|
||||
{
|
||||
this.Visible = false;
|
||||
this.Name = "Haochi's katana generator";
|
||||
this.Movable = false;
|
||||
}
|
||||
|
||||
public HaochisKatanaGenerator(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool OnMoveOver(Mobile m)
|
||||
{
|
||||
PlayerMobile player = m as PlayerMobile;
|
||||
|
||||
if (player != null)
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is HaochisTrialsQuest)
|
||||
{
|
||||
if (HaochisTrialsQuest.HasLostHaochisKatana(player))
|
||||
{
|
||||
Item katana = new HaochisKatana();
|
||||
|
||||
if (!player.PlaceInBackpack(katana))
|
||||
{
|
||||
katana.Delete();
|
||||
player.SendLocalizedMessage(1046260); // You need to clear some space in your inventory to continue with the quest. Come back here when you have more space in your inventory.
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(FifthTrialIntroObjective));
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
{
|
||||
Item katana = new HaochisKatana();
|
||||
|
||||
if (player.PlaceInBackpack(katana))
|
||||
{
|
||||
obj.Complete();
|
||||
}
|
||||
else
|
||||
{
|
||||
katana.Delete();
|
||||
player.SendLocalizedMessage(1046260); // You need to clear some space in your inventory to continue with the quest. Come back here when you have more space in your inventory.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return base.OnMoveOver(m);
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
116
Scripts/Items/Quest/HaochisTreasureChest.cs
Normal file
116
Scripts/Items/Quest/HaochisTreasureChest.cs
Normal file
@@ -0,0 +1,116 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Quests.Samurai
|
||||
{
|
||||
public class HaochisTreasureChest : WoodenFootLocker
|
||||
{
|
||||
[Constructable]
|
||||
public HaochisTreasureChest()
|
||||
{
|
||||
this.Movable = false;
|
||||
|
||||
this.GenerateTreasure();
|
||||
}
|
||||
|
||||
public HaochisTreasureChest(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool IsDecoContainer
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
public override bool CheckHold(Mobile m, Item item, bool message, bool checkItems, int plusItems, int plusWeight)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool CheckItemUse(Mobile from, Item item)
|
||||
{
|
||||
return item == this;
|
||||
}
|
||||
|
||||
public override bool CheckLift(Mobile from, Item item, ref LRReason reject)
|
||||
{
|
||||
if (from.AccessLevel >= AccessLevel.GameMaster)
|
||||
return true;
|
||||
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null && player.Quest is HaochisTrialsQuest)
|
||||
{
|
||||
FifthTrialIntroObjective obj = player.Quest.FindObjective(typeof(FifthTrialIntroObjective)) as FifthTrialIntroObjective;
|
||||
|
||||
if (obj != null)
|
||||
{
|
||||
if (obj.StolenTreasure)
|
||||
from.SendLocalizedMessage(1063247); // The guard is watching you carefully! It would be unwise to remove another item from here.
|
||||
else
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void OnItemLifted(Mobile from, Item item)
|
||||
{
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null && player.Quest is HaochisTrialsQuest)
|
||||
{
|
||||
FifthTrialIntroObjective obj = player.Quest.FindObjective(typeof(FifthTrialIntroObjective)) as FifthTrialIntroObjective;
|
||||
|
||||
if (obj != null)
|
||||
obj.StolenTreasure = true;
|
||||
}
|
||||
|
||||
Timer.DelayCall(TimeSpan.FromMinutes(2.0), new TimerCallback(GenerateTreasure));
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
|
||||
Timer.DelayCall(TimeSpan.Zero, new TimerCallback(GenerateTreasure));
|
||||
}
|
||||
|
||||
private void GenerateTreasure()
|
||||
{
|
||||
for (int i = this.Items.Count - 1; i >= 0; i--)
|
||||
this.Items[i].Delete();
|
||||
|
||||
for (int i = 0; i < 75; i++)
|
||||
{
|
||||
switch ( Utility.Random(3) )
|
||||
{
|
||||
case 0:
|
||||
this.DropItem(new GoldBracelet());
|
||||
break;
|
||||
case 1:
|
||||
this.DropItem(new GoldRing());
|
||||
break;
|
||||
case 2:
|
||||
this.DropItem(Loot.RandomGem());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
89
Scripts/Items/Quest/HonorCandle.cs
Normal file
89
Scripts/Items/Quest/HonorCandle.cs
Normal file
@@ -0,0 +1,89 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Samurai
|
||||
{
|
||||
public class HonorCandle : CandleLong
|
||||
{
|
||||
private static readonly TimeSpan LitDuration = TimeSpan.FromSeconds(20.0);
|
||||
[Constructable]
|
||||
public HonorCandle()
|
||||
{
|
||||
this.Movable = false;
|
||||
this.Duration = LitDuration;
|
||||
}
|
||||
|
||||
public HonorCandle(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LitSound
|
||||
{
|
||||
get
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
public override int UnlitSound
|
||||
{
|
||||
get
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
bool wasBurning = this.Burning;
|
||||
|
||||
base.OnDoubleClick(from);
|
||||
|
||||
if (!wasBurning && this.Burning)
|
||||
{
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player == null)
|
||||
return;
|
||||
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs != null && qs is HaochisTrialsQuest)
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(SixthTrialIntroObjective));
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
obj.Complete();
|
||||
|
||||
this.SendLocalizedMessageTo(from, 1063251); // You light a candle in honor.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Burn()
|
||||
{
|
||||
this.Douse();
|
||||
}
|
||||
|
||||
public override void Douse()
|
||||
{
|
||||
base.Douse();
|
||||
|
||||
this.Duration = LitDuration;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.WriteEncodedInt(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/HornOfTheDreadhorn.cs
Normal file
40
Scripts/Items/Quest/HornOfTheDreadhorn.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
[Flipable(0x315C, 0x315D)]
|
||||
public class HornOfTheDreadhorn : Item
|
||||
{
|
||||
[Constructable]
|
||||
public HornOfTheDreadhorn()
|
||||
: base(0x315C)
|
||||
{
|
||||
}
|
||||
|
||||
public HornOfTheDreadhorn(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1072089;
|
||||
}
|
||||
}// Horn of the Dread
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/HydraScale.cs
Normal file
40
Scripts/Items/Quest/HydraScale.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class HydraScale : Item
|
||||
{
|
||||
[Constructable]
|
||||
public HydraScale()
|
||||
: base(0x26B4)
|
||||
{
|
||||
this.Hue = 0xC2; // TODO check
|
||||
}
|
||||
|
||||
public HydraScale(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074760;
|
||||
}
|
||||
}// A hydra scale.
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
39
Scripts/Items/Quest/IcyHeart.cs
Normal file
39
Scripts/Items/Quest/IcyHeart.cs
Normal file
@@ -0,0 +1,39 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class IcyHeart : Item
|
||||
{
|
||||
[Constructable]
|
||||
public IcyHeart()
|
||||
: base(0x24B)
|
||||
{
|
||||
}
|
||||
|
||||
public IcyHeart(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073162;
|
||||
}
|
||||
}// Icy Heart
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
133
Scripts/Items/Quest/ImageType.cs
Normal file
133
Scripts/Items/Quest/ImageType.cs
Normal file
@@ -0,0 +1,133 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Collector
|
||||
{
|
||||
public enum ImageType
|
||||
{
|
||||
Betrayer,
|
||||
Bogling,
|
||||
BogThing,
|
||||
Gazer,
|
||||
Beetle,
|
||||
GiantBlackWidow,
|
||||
Scorpion,
|
||||
JukaMage,
|
||||
JukaWarrior,
|
||||
Lich,
|
||||
MeerMage,
|
||||
MeerWarrior,
|
||||
Mongbat,
|
||||
Mummy,
|
||||
Pixie,
|
||||
PlagueBeast,
|
||||
SandVortex,
|
||||
StoneGargoyle,
|
||||
SwampDragon,
|
||||
Wisp,
|
||||
Juggernaut
|
||||
}
|
||||
|
||||
public class ImageTypeInfo
|
||||
{
|
||||
private static readonly ImageTypeInfo[] m_Table = new ImageTypeInfo[]
|
||||
{
|
||||
new ImageTypeInfo(9734, typeof(Betrayer), 75, 45),
|
||||
new ImageTypeInfo(9735, typeof(Bogling), 75, 45),
|
||||
new ImageTypeInfo(9736, typeof(BogThing), 60, 47),
|
||||
new ImageTypeInfo(9615, typeof(Gazer), 75, 45),
|
||||
new ImageTypeInfo(9743, typeof(Beetle), 60, 55),
|
||||
new ImageTypeInfo(9667, typeof(GiantBlackWidow), 55, 52),
|
||||
new ImageTypeInfo(9657, typeof(Scorpion), 65, 47),
|
||||
new ImageTypeInfo(9758, typeof(JukaMage), 75, 45),
|
||||
new ImageTypeInfo(9759, typeof(JukaWarrior), 75, 45),
|
||||
new ImageTypeInfo(9636, typeof(Lich), 75, 45),
|
||||
new ImageTypeInfo(9756, typeof(MeerMage), 75, 45),
|
||||
new ImageTypeInfo(9757, typeof(MeerWarrior), 75, 45),
|
||||
new ImageTypeInfo(9638, typeof(Mongbat), 70, 50),
|
||||
new ImageTypeInfo(9639, typeof(Mummy), 75, 45),
|
||||
new ImageTypeInfo(9654, typeof(Pixie), 75, 45),
|
||||
new ImageTypeInfo(9747, typeof(PlagueBeast), 60, 45),
|
||||
new ImageTypeInfo(9750, typeof(SandVortex), 60, 43),
|
||||
new ImageTypeInfo(9614, typeof(StoneGargoyle), 75, 45),
|
||||
new ImageTypeInfo(9753, typeof(SwampDragon), 50, 55),
|
||||
new ImageTypeInfo(8448, typeof(Wisp), 75, 45),
|
||||
new ImageTypeInfo(9746, typeof(Juggernaut), 55, 38)
|
||||
};
|
||||
private readonly int m_Figurine;
|
||||
private readonly Type m_Type;
|
||||
private readonly int m_X;
|
||||
private readonly int m_Y;
|
||||
public ImageTypeInfo(int figurine, Type type, int x, int y)
|
||||
{
|
||||
this.m_Figurine = figurine;
|
||||
this.m_Type = type;
|
||||
this.m_X = x;
|
||||
this.m_Y = y;
|
||||
}
|
||||
|
||||
public int Figurine
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Figurine;
|
||||
}
|
||||
}
|
||||
public Type Type
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Type;
|
||||
}
|
||||
}
|
||||
public int Name
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Figurine < 0x4000 ? 1020000 + this.m_Figurine : 1078872 + this.m_Figurine;
|
||||
}
|
||||
}
|
||||
public int X
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_X;
|
||||
}
|
||||
}
|
||||
public int Y
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Y;
|
||||
}
|
||||
}
|
||||
public static ImageTypeInfo Get(ImageType image)
|
||||
{
|
||||
int index = (int)image;
|
||||
if (index >= 0 && index < m_Table.Length)
|
||||
return m_Table[index];
|
||||
else
|
||||
return m_Table[0];
|
||||
}
|
||||
|
||||
public static ImageType[] RandomList(int count)
|
||||
{
|
||||
ArrayList list = new ArrayList(m_Table.Length);
|
||||
for (int i = 0; i < m_Table.Length; i++)
|
||||
list.Add((ImageType)i);
|
||||
|
||||
ImageType[] images = new ImageType[count];
|
||||
|
||||
for (int i = 0; i < images.Length; i++)
|
||||
{
|
||||
int index = Utility.Random(list.Count);
|
||||
images[i] = (ImageType)list[index];
|
||||
|
||||
list.RemoveAt(index);
|
||||
}
|
||||
|
||||
return images;
|
||||
}
|
||||
}
|
||||
}
|
||||
35
Scripts/Items/Quest/InspectedKegofGreaterPoison.cs
Normal file
35
Scripts/Items/Quest/InspectedKegofGreaterPoison.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class InspectedKegofGreaterPoison : Item
|
||||
{
|
||||
[Constructable]
|
||||
public InspectedKegofGreaterPoison()
|
||||
: base(0x1940)
|
||||
{
|
||||
this.Name = "Inspected Keg of Greater Poison";
|
||||
|
||||
this.Hue = 2425;
|
||||
}
|
||||
|
||||
public InspectedKegofGreaterPoison(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
35
Scripts/Items/Quest/InspectedKegofTotalRefreshment.cs
Normal file
35
Scripts/Items/Quest/InspectedKegofTotalRefreshment.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class InspectedKegofTotalRefreshment : Item
|
||||
{
|
||||
[Constructable]
|
||||
public InspectedKegofTotalRefreshment()
|
||||
: base(0x1940)
|
||||
{
|
||||
this.Name = "Inspected Keg of Total Refreshment";
|
||||
|
||||
this.Hue = 2418;
|
||||
}
|
||||
|
||||
public InspectedKegofTotalRefreshment(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/IrksBrain.cs
Normal file
42
Scripts/Items/Quest/IrksBrain.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class IrksBrain : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public IrksBrain()
|
||||
: base(0x1CF0)
|
||||
{
|
||||
Weight = 1;
|
||||
Hue = 0x453; // TODO check
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public IrksBrain(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074335;
|
||||
}
|
||||
}// irk's brain
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/JaggedCrystals.cs
Normal file
41
Scripts/Items/Quest/JaggedCrystals.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class JaggedCrystals : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public JaggedCrystals()
|
||||
: base(0x223E)
|
||||
{
|
||||
this.Weight = 1;
|
||||
this.Hue = 0x2B2;
|
||||
}
|
||||
|
||||
public JaggedCrystals(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074265;
|
||||
}
|
||||
}// jagged crystal shards
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/KirinBrains.cs
Normal file
42
Scripts/Items/Quest/KirinBrains.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class KirinBrains : Item
|
||||
{
|
||||
[Constructable]
|
||||
public KirinBrains()
|
||||
: base(0x1CF0)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1;
|
||||
this.Hue = 0xD7;
|
||||
}
|
||||
|
||||
public KirinBrains(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074612;
|
||||
}
|
||||
}// Ki-Rin Brains
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
165
Scripts/Items/Quest/KronusScroll.cs
Normal file
165
Scripts/Items/Quest/KronusScroll.cs
Normal file
@@ -0,0 +1,165 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Quests.Necro
|
||||
{
|
||||
public class KronusScroll : QuestItem
|
||||
{
|
||||
private static readonly Rectangle2D m_WellOfTearsArea = new Rectangle2D(2080, 1346, 10, 10);
|
||||
private static readonly Map m_WellOfTearsMap = Map.Malas;
|
||||
[Constructable]
|
||||
public KronusScroll()
|
||||
: base(0x227A)
|
||||
{
|
||||
Weight = 1.0;
|
||||
Hue = 0x44E;
|
||||
}
|
||||
|
||||
public KronusScroll(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1060149;
|
||||
}
|
||||
}// Calling of Kronus
|
||||
public override bool CanDrop(PlayerMobile player)
|
||||
{
|
||||
DarkTidesQuest qs = player.Quest as DarkTidesQuest;
|
||||
|
||||
if (qs == null)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (!this.IsChildOf(from))
|
||||
return;
|
||||
|
||||
PlayerMobile pm = from as PlayerMobile;
|
||||
|
||||
if (pm != null)
|
||||
{
|
||||
QuestSystem qs = pm.Quest;
|
||||
|
||||
if (qs is DarkTidesQuest)
|
||||
{
|
||||
if (qs.IsObjectiveInProgress(typeof(FindMardothAboutKronusObjective)))
|
||||
{
|
||||
pm.SendLocalizedMessage(1060151, "", 0x41); // You read the scroll, but decide against performing the calling until you are instructed to do so by Mardoth.
|
||||
}
|
||||
else if (qs.IsObjectiveInProgress(typeof(FindWellOfTearsObjective)))
|
||||
{
|
||||
pm.SendLocalizedMessage(1060152, "", 0x41); // You must be at the Well of Tears in the city of Necromancers to use this scroll.
|
||||
}
|
||||
else if (qs.IsObjectiveInProgress(typeof(UseCallingScrollObjective)))
|
||||
{
|
||||
if (pm.Map == m_WellOfTearsMap && m_WellOfTearsArea.Contains(pm))
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(UseCallingScrollObjective));
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
obj.Complete();
|
||||
|
||||
this.Delete();
|
||||
new CallingTimer(pm).Start();
|
||||
}
|
||||
else
|
||||
{
|
||||
pm.SendLocalizedMessage(1060152, "", 0x41); // You must be at the Well of Tears in the city of Necromancers to use this scroll.
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
pm.SendLocalizedMessage(1060150, "", 0x41); // A strange terror grips your heart as you attempt to read the scroll. You decide it would be a bad idea to read it out loud.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
private class CallingTimer : Timer
|
||||
{
|
||||
private readonly PlayerMobile m_Player;
|
||||
private int m_Step;
|
||||
public CallingTimer(PlayerMobile player)
|
||||
: base(TimeSpan.Zero, TimeSpan.FromSeconds(1.0), 6)
|
||||
{
|
||||
this.Priority = TimerPriority.TwentyFiveMS;
|
||||
|
||||
this.m_Player = player;
|
||||
this.m_Step = 0;
|
||||
}
|
||||
|
||||
protected override void OnTick()
|
||||
{
|
||||
if (this.m_Player.Deleted)
|
||||
{
|
||||
this.Stop();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!this.m_Player.Mounted)
|
||||
this.m_Player.Animate(Utility.RandomBool() ? 16 : 17, 7, 1, true, false, 0);
|
||||
|
||||
if (this.m_Step == 4)
|
||||
{
|
||||
int baseX = KronusScroll.m_WellOfTearsArea.X;
|
||||
int baseY = KronusScroll.m_WellOfTearsArea.Y;
|
||||
int width = KronusScroll.m_WellOfTearsArea.Width;
|
||||
int height = KronusScroll.m_WellOfTearsArea.Height;
|
||||
Map map = KronusScroll.m_WellOfTearsMap;
|
||||
|
||||
Effects.SendLocationParticles(EffectItem.Create(this.m_Player.Location, this.m_Player.Map, TimeSpan.FromSeconds(1.0)), 0, 0, 0, 0x13C4);
|
||||
Effects.PlaySound(this.m_Player.Location, this.m_Player.Map, 0x243);
|
||||
|
||||
for (int i = 0; i < 15; i++)
|
||||
{
|
||||
int x = baseX + Utility.Random(width);
|
||||
int y = baseY + Utility.Random(height);
|
||||
int z = map.GetAverageZ(x, y);
|
||||
|
||||
Point3D from = new Point3D(x, y, z + Utility.RandomMinMax(5, 20));
|
||||
Point3D to = new Point3D(x, y, z);
|
||||
|
||||
int hue = Utility.RandomList(0x481, 0x482, 0x489, 0x497, 0x66D);
|
||||
|
||||
Effects.SendPacket(from, map, new HuedEffect(EffectType.Moving, Serial.Zero, Serial.Zero, 0x36D4, from, to, 0, 0, false, true, hue, 0));
|
||||
}
|
||||
}
|
||||
|
||||
if (this.m_Step < 5)
|
||||
{
|
||||
this.m_Player.Frozen = true;
|
||||
}
|
||||
else // Cast completed
|
||||
{
|
||||
this.m_Player.Frozen = false;
|
||||
|
||||
SummonedPaladin.BeginSummon(this.m_Player);
|
||||
}
|
||||
|
||||
this.m_Step++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
77
Scripts/Items/Quest/KronusScrollBox.cs
Normal file
77
Scripts/Items/Quest/KronusScrollBox.cs
Normal file
@@ -0,0 +1,77 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Necro
|
||||
{
|
||||
public class KronusScrollBox : MetalBox
|
||||
{
|
||||
[Constructable]
|
||||
public KronusScrollBox()
|
||||
{
|
||||
this.ItemID = 0xE80;
|
||||
this.Movable = false;
|
||||
|
||||
for (int i = 0; i < 40; i++)
|
||||
{
|
||||
Item scroll = Loot.RandomScroll(0, 15, SpellbookType.Necromancer);
|
||||
scroll.Movable = false;
|
||||
this.DropItem(scroll);
|
||||
}
|
||||
}
|
||||
|
||||
public KronusScrollBox(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
PlayerMobile pm = from as PlayerMobile;
|
||||
|
||||
if (pm != null && pm.InRange(this.GetWorldLocation(), 2))
|
||||
{
|
||||
QuestSystem qs = pm.Quest;
|
||||
|
||||
if (qs is DarkTidesQuest)
|
||||
{
|
||||
QuestObjective obj = qs.FindObjective(typeof(FindCallingScrollObjective));
|
||||
|
||||
if ((obj != null && !obj.Completed) || DarkTidesQuest.HasLostCallingScroll(from))
|
||||
{
|
||||
Item scroll = new KronusScroll();
|
||||
|
||||
if (pm.PlaceInBackpack(scroll))
|
||||
{
|
||||
pm.SendLocalizedMessage(1060120, "", 0x41); // You rummage through the scrolls until you find the Scroll of Calling. You quickly put it in your pack.
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
obj.Complete();
|
||||
}
|
||||
else
|
||||
{
|
||||
pm.SendLocalizedMessage(1060148, "", 0x41); // You were unable to take the scroll.
|
||||
scroll.Delete();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
base.OnDoubleClick(from);
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
66
Scripts/Items/Quest/LaifemItems.cs
Normal file
66
Scripts/Items/Quest/LaifemItems.cs
Normal file
@@ -0,0 +1,66 @@
|
||||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class LetterOfIntroduction : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1113243; } } // Laifem's Letter of Introduction
|
||||
|
||||
[Constructable]
|
||||
public LetterOfIntroduction()
|
||||
: base(0x1F23)
|
||||
{
|
||||
Hue = 1167;
|
||||
Weight = 2.0;
|
||||
QuestItem = true;
|
||||
}
|
||||
|
||||
public LetterOfIntroduction( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
writer.Write( (int) 0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
|
||||
public class MasteringWeaving : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1113244; } } // Mastering the Art of Weaving
|
||||
|
||||
[Constructable]
|
||||
public MasteringWeaving()
|
||||
: base(0x1E20)
|
||||
{
|
||||
Hue = 744;
|
||||
Weight = 2.0;
|
||||
QuestItem = true;
|
||||
}
|
||||
|
||||
public MasteringWeaving(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/LibrariansKey.cs
Normal file
41
Scripts/Items/Quest/LibrariansKey.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class LibrariansKey : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public LibrariansKey()
|
||||
: base(0xFF3)
|
||||
{
|
||||
Weight = 1.0;
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public LibrariansKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074347;
|
||||
}
|
||||
}// librarian's key
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/LibraryApplication.cs
Normal file
41
Scripts/Items/Quest/LibraryApplication.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class LibraryApplication : Item
|
||||
{
|
||||
[Constructable]
|
||||
public LibraryApplication()
|
||||
: base(0xEC0)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public LibraryApplication(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073131;
|
||||
}
|
||||
}// Friends of the Library Application
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/LissithsSilk.cs
Normal file
42
Scripts/Items/Quest/LissithsSilk.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class LissithsSilk : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public LissithsSilk()
|
||||
: base(0x2001)
|
||||
{
|
||||
Weight = 1;
|
||||
Hue = 0x4FB; // TODO check
|
||||
LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public LissithsSilk(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074333;
|
||||
}
|
||||
}// lissith's silk
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
33
Scripts/Items/Quest/LuckyDagger.cs
Normal file
33
Scripts/Items/Quest/LuckyDagger.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class LuckyDagger : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1151983; } } // Lucky Dagger
|
||||
|
||||
[Constructable]
|
||||
public LuckyDagger()
|
||||
: base(0xF52)
|
||||
{
|
||||
Hue = 0x8A5;
|
||||
}
|
||||
|
||||
public LuckyDagger(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
179
Scripts/Items/Quest/MaabusCoffin.cs
Normal file
179
Scripts/Items/Quest/MaabusCoffin.cs
Normal file
@@ -0,0 +1,179 @@
|
||||
using System;
|
||||
using Server.Items;
|
||||
|
||||
namespace Server.Engines.Quests.Necro
|
||||
{
|
||||
public class MaabusCoffin : BaseAddon
|
||||
{
|
||||
private Maabus m_Maabus;
|
||||
private Point3D m_SpawnLocation;
|
||||
[Constructable]
|
||||
public MaabusCoffin()
|
||||
{
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1C2B, 0x1C2B), -1, -1, 0);
|
||||
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1D16, 0x1C2C), 0, -1, 0);
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1D17, 0x1C2D), 1, -1, 0);
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1D51, 0x1C2E), 2, -1, 0);
|
||||
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1D4E, 0x1C2A), 0, 0, 0);
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1D4D, 0x1C29), 1, 0, 0);
|
||||
this.AddComponent(new MaabusCoffinComponent(0x1D4C, 0x1C28), 2, 0, 0);
|
||||
}
|
||||
|
||||
public MaabusCoffin(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public Maabus Maabus
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Maabus;
|
||||
}
|
||||
}
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public Point3D SpawnLocation
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_SpawnLocation;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.m_SpawnLocation = value;
|
||||
}
|
||||
}
|
||||
public void Awake(Mobile caller)
|
||||
{
|
||||
if (this.m_Maabus != null || this.m_SpawnLocation == Point3D.Zero)
|
||||
return;
|
||||
|
||||
foreach (MaabusCoffinComponent c in this.Components)
|
||||
c.TurnToEmpty();
|
||||
|
||||
this.m_Maabus = new Maabus();
|
||||
|
||||
this.m_Maabus.Location = this.m_SpawnLocation;
|
||||
this.m_Maabus.Map = this.Map;
|
||||
|
||||
this.m_Maabus.Direction = this.m_Maabus.GetDirectionTo(caller);
|
||||
|
||||
Timer.DelayCall(TimeSpan.FromSeconds(7.5), new TimerCallback(BeginSleep));
|
||||
}
|
||||
|
||||
public void BeginSleep()
|
||||
{
|
||||
if (this.m_Maabus == null)
|
||||
return;
|
||||
|
||||
Effects.PlaySound(this.m_Maabus.Location, this.m_Maabus.Map, 0x48E);
|
||||
|
||||
Timer.DelayCall(TimeSpan.FromSeconds(2.5), new TimerCallback(Sleep));
|
||||
}
|
||||
|
||||
public void Sleep()
|
||||
{
|
||||
if (this.m_Maabus == null)
|
||||
return;
|
||||
|
||||
Effects.SendLocationParticles(EffectItem.Create(this.m_Maabus.Location, this.m_Maabus.Map, EffectItem.DefaultDuration), 0x3728, 10, 10, 0x7E7);
|
||||
Effects.PlaySound(this.m_Maabus.Location, this.m_Maabus.Map, 0x1FE);
|
||||
|
||||
this.m_Maabus.Delete();
|
||||
this.m_Maabus = null;
|
||||
|
||||
foreach (MaabusCoffinComponent c in this.Components)
|
||||
c.TurnToFull();
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.Write((Mobile)this.m_Maabus);
|
||||
writer.Write((Point3D)this.m_SpawnLocation);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
this.m_Maabus = reader.ReadMobile() as Maabus;
|
||||
this.m_SpawnLocation = reader.ReadPoint3D();
|
||||
|
||||
this.Sleep();
|
||||
}
|
||||
}
|
||||
|
||||
public class MaabusCoffinComponent : AddonComponent
|
||||
{
|
||||
private int m_FullItemID;
|
||||
private int m_EmptyItemID;
|
||||
public MaabusCoffinComponent(int itemID)
|
||||
: this(itemID, itemID)
|
||||
{
|
||||
}
|
||||
|
||||
public MaabusCoffinComponent(int fullItemID, int emptyItemID)
|
||||
: base(fullItemID)
|
||||
{
|
||||
this.m_FullItemID = fullItemID;
|
||||
this.m_EmptyItemID = emptyItemID;
|
||||
}
|
||||
|
||||
public MaabusCoffinComponent(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public Point3D SpawnLocation
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Addon is MaabusCoffin ? ((MaabusCoffin)this.Addon).SpawnLocation : Point3D.Zero;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (this.Addon is MaabusCoffin)
|
||||
((MaabusCoffin)this.Addon).SpawnLocation = value;
|
||||
}
|
||||
}
|
||||
public void TurnToEmpty()
|
||||
{
|
||||
this.ItemID = this.m_EmptyItemID;
|
||||
}
|
||||
|
||||
public void TurnToFull()
|
||||
{
|
||||
this.ItemID = this.m_FullItemID;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.Write((int)this.m_FullItemID);
|
||||
writer.Write((int)this.m_EmptyItemID);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
this.m_FullItemID = reader.ReadInt();
|
||||
this.m_EmptyItemID = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
82
Scripts/Items/Quest/MagicFlute.cs
Normal file
82
Scripts/Items/Quest/MagicFlute.cs
Normal file
@@ -0,0 +1,82 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Hag
|
||||
{
|
||||
public class MagicFlute : Item
|
||||
{
|
||||
[Constructable]
|
||||
public MagicFlute()
|
||||
: base(0x1421)
|
||||
{
|
||||
this.Hue = 0x8AB;
|
||||
}
|
||||
|
||||
public MagicFlute(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1055051;
|
||||
}
|
||||
}// magic flute
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (!this.IsChildOf(from.Backpack))
|
||||
{
|
||||
this.SendLocalizedMessageTo(from, 1042292); // You must have the object in your backpack to use it.
|
||||
return;
|
||||
}
|
||||
|
||||
from.PlaySound(0x3D);
|
||||
|
||||
PlayerMobile player = from as PlayerMobile;
|
||||
|
||||
if (player != null)
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
if (qs is WitchApprenticeQuest)
|
||||
{
|
||||
FindZeefzorpulObjective obj = qs.FindObjective(typeof(FindZeefzorpulObjective)) as FindZeefzorpulObjective;
|
||||
|
||||
if (obj != null && !obj.Completed)
|
||||
{
|
||||
if ((player.Map != Map.Trammel && player.Map != Map.Felucca) || !player.InRange(obj.ImpLocation, 8))
|
||||
{
|
||||
player.SendLocalizedMessage(1055053); // Nothing happens. Zeefzorpul must not be hiding in this area.
|
||||
}
|
||||
else if (player.InRange(obj.ImpLocation, 4))
|
||||
{
|
||||
this.Delete();
|
||||
|
||||
obj.Complete();
|
||||
}
|
||||
else
|
||||
{
|
||||
player.SendLocalizedMessage(1055052); // The flute sparkles. Zeefzorpul must be in a good hiding place nearby.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
48
Scripts/Items/Quest/MagicalRope.cs
Normal file
48
Scripts/Items/Quest/MagicalRope.cs
Normal file
@@ -0,0 +1,48 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MagicalRope : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public MagicalRope()
|
||||
: base(0x20D)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 5.0;
|
||||
}
|
||||
|
||||
public MagicalRope(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074338;
|
||||
}
|
||||
}// Magical Rope
|
||||
public override int Lifespan
|
||||
{
|
||||
get
|
||||
{
|
||||
return 600;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/MapFragment.cs
Normal file
42
Scripts/Items/Quest/MapFragment.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
using Server.Engines.Quests;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MapFragment : BaseQuestItem
|
||||
{
|
||||
[Constructable]
|
||||
public MapFragment()
|
||||
: base(0x14ED)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1;
|
||||
}
|
||||
|
||||
public MapFragment(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074533;
|
||||
}
|
||||
}// Fragment of a Map
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/MedusaLairMasterKey.cs
Normal file
41
Scripts/Items/Quest/MedusaLairMasterKey.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MedusaKey : MasterKey
|
||||
{
|
||||
public override int Lifespan { get { return 600; } }
|
||||
public override int LabelNumber { get { return 1112303; } } // Medusa's Lair
|
||||
|
||||
public MedusaKey()
|
||||
: base(0x1012)
|
||||
{
|
||||
Hue = 0x481;
|
||||
}
|
||||
|
||||
public MedusaKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override bool CanOfferConfirmation(Mobile from)
|
||||
{
|
||||
if (from.Region != null && from.Region.IsPartOf("MedusasLair"))
|
||||
return base.CanOfferConfirmation(from);
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/MiniatureMushroom.cs
Normal file
41
Scripts/Items/Quest/MiniatureMushroom.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MiniatureMushroom : Food
|
||||
{
|
||||
[Constructable]
|
||||
public MiniatureMushroom()
|
||||
: base(0xD16)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1;
|
||||
}
|
||||
|
||||
public MiniatureMushroom(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073138;
|
||||
}
|
||||
}// Miniature mushroom
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
51
Scripts/Items/Quest/MinotaurArtifact.cs
Normal file
51
Scripts/Items/Quest/MinotaurArtifact.cs
Normal file
@@ -0,0 +1,51 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MinotaurArtifact : Item
|
||||
{
|
||||
[Constructable]
|
||||
public MinotaurArtifact()
|
||||
: base(Utility.RandomList(0xB46, 0xB48, 0x9ED))
|
||||
{
|
||||
if (this.ItemID == 0x9ED)
|
||||
this.Weight = 30;
|
||||
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Hue = 0x100;
|
||||
}
|
||||
|
||||
public MinotaurArtifact(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074826;
|
||||
}
|
||||
}// Minotaur Artifact
|
||||
public override double DefaultWeight
|
||||
{
|
||||
get
|
||||
{
|
||||
return 5.0;
|
||||
}
|
||||
}
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/MirrorOfPurification.cs
Normal file
42
Scripts/Items/Quest/MirrorOfPurification.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MirrorOfPurification : Item
|
||||
{
|
||||
[Constructable]
|
||||
public MirrorOfPurification()
|
||||
: base(0x1008)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 5.0;
|
||||
this.Hue = 0x530;
|
||||
}
|
||||
|
||||
public MirrorOfPurification(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1075304;
|
||||
}
|
||||
}// Mirror of Purification
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
245
Scripts/Items/Quest/ModifiedClockworkAssembly.cs
Normal file
245
Scripts/Items/Quest/ModifiedClockworkAssembly.cs
Normal file
@@ -0,0 +1,245 @@
|
||||
using System;
|
||||
using Server.Engines.Craft;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public enum ClockworkType
|
||||
{
|
||||
Wolf = 0,
|
||||
Scorpion = 1,
|
||||
Vollem = 2,
|
||||
}
|
||||
|
||||
[Flipable(0x1EA8, 0x1EAC)]
|
||||
public class ModifiedClockworkAssembly : Item, ICraftable
|
||||
{
|
||||
private class GolemInfo
|
||||
{
|
||||
readonly int m_Slots;
|
||||
readonly Type[] m_Types;
|
||||
readonly int[] m_Amounts;
|
||||
readonly int[] m_MsgIds;
|
||||
|
||||
public int Slots
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Slots;
|
||||
}
|
||||
}
|
||||
public Type[] Types
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Types;
|
||||
}
|
||||
}
|
||||
public int[] Amounts
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Amounts;
|
||||
}
|
||||
}
|
||||
public int[] MsgIds
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_MsgIds;
|
||||
}
|
||||
}
|
||||
|
||||
public GolemInfo(int slots, Type[] types, int[] amounts, int[] msgids)
|
||||
{
|
||||
m_Slots = slots;
|
||||
m_Types = types;
|
||||
m_Amounts = amounts;
|
||||
m_MsgIds = msgids;
|
||||
}
|
||||
}
|
||||
|
||||
private static readonly GolemInfo[] m_Info =
|
||||
{
|
||||
// Clockwork Leather Wolf
|
||||
new GolemInfo(1,
|
||||
new Type[] { typeof(Leather), typeof(OilFlask) },
|
||||
new int[] { 100, 1 },
|
||||
new int[] { 1113058, 1113059 }),
|
||||
// ClockWork Scorpion
|
||||
new GolemInfo(1,
|
||||
new Type[] { typeof(BronzeIngot), typeof(Gears) },
|
||||
new int[] { 100, 10 },
|
||||
new int[] { 1113060, 1113061 }),
|
||||
// Vollem
|
||||
new GolemInfo(2,
|
||||
new Type[] { typeof(BronzeIngot), typeof(WhiteScales) },
|
||||
new int[] { 50, 25 },
|
||||
new int[] { 1113060, 1113062 })
|
||||
};
|
||||
|
||||
private ClockworkType m_Type;
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public ClockworkType Type
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Type;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Type = value;
|
||||
InvalidateProperties();
|
||||
}
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return (1113031 + (int)m_Type);
|
||||
}
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public ModifiedClockworkAssembly()
|
||||
: this(ClockworkType.Wolf)
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public ModifiedClockworkAssembly(ClockworkType type)
|
||||
: base(0x1EA8)
|
||||
{
|
||||
m_Type = type;
|
||||
Weight = 5.0;
|
||||
}
|
||||
|
||||
public ModifiedClockworkAssembly(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
PlayerMobile pm = from as PlayerMobile;
|
||||
if (null == pm)
|
||||
return;
|
||||
|
||||
if (!pm.MechanicalLife)
|
||||
{
|
||||
from.SendLocalizedMessage(1113034); // You haven't read the Mechanical Life Manual. Talking to Sutek might help!
|
||||
}
|
||||
|
||||
if (!IsChildOf(from.Backpack))
|
||||
{
|
||||
from.SendLocalizedMessage(1071944); // The clockwork assembly must be in your backpack to construct a golem.
|
||||
return;
|
||||
}
|
||||
|
||||
double tinkerSkill = from.Skills[SkillName.Tinkering].Value;
|
||||
|
||||
if (tinkerSkill < 60.0)
|
||||
{
|
||||
from.SendLocalizedMessage(1113054); // You must be a Journeyman or higher Tinker to construct a mechanical pet.
|
||||
return;
|
||||
}
|
||||
|
||||
if ((int)m_Type > m_Info.Length)
|
||||
return;
|
||||
|
||||
GolemInfo ginfo = m_Info[(int)m_Type];
|
||||
|
||||
if ((from.Followers + ginfo.Slots) > from.FollowersMax)
|
||||
{
|
||||
from.SendLocalizedMessage(1049607); // You have too many followers to control that creature.
|
||||
return;
|
||||
}
|
||||
|
||||
Container pack = from.Backpack;
|
||||
|
||||
if (pack == null)
|
||||
return;
|
||||
|
||||
// check array length to prevent errors
|
||||
if (ginfo.Types.Length != ginfo.Amounts.Length)
|
||||
return;
|
||||
|
||||
int res = pack.ConsumeTotal(ginfo.Types, ginfo.Amounts);
|
||||
|
||||
if (res >= 0)
|
||||
{
|
||||
// send message, if valid index
|
||||
if (res < ginfo.MsgIds.Length)
|
||||
from.SendLocalizedMessage(ginfo.MsgIds[res]); // You need _____ to construct a mechanical pet.
|
||||
return;
|
||||
}
|
||||
|
||||
BaseCreature bc = null;
|
||||
|
||||
switch (m_Type)
|
||||
{
|
||||
case ClockworkType.Scorpion:
|
||||
bc = new ClockworkScorpion();
|
||||
break;
|
||||
case ClockworkType.Wolf:
|
||||
bc = new LeatherWolf();
|
||||
break;
|
||||
case ClockworkType.Vollem:
|
||||
bc = new Vollem();
|
||||
break;
|
||||
}
|
||||
|
||||
if (null != bc && bc.SetControlMaster(from))
|
||||
{
|
||||
Delete();
|
||||
|
||||
bc.MoveToWorld(from.Location, from.Map);
|
||||
from.PlaySound(0x241);
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)1);
|
||||
|
||||
writer.Write((int)m_Type);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
|
||||
switch (version)
|
||||
{
|
||||
case 1:
|
||||
m_Type = (ClockworkType)reader.ReadInt();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
#region ICraftable Members
|
||||
public int OnCraft(int quality, bool makersMark, Mobile from, CraftSystem craftSystem, Type typeRes, ITool tool, CraftItem craftItem, int resHue)
|
||||
{
|
||||
switch (craftItem.NameNumber)
|
||||
{
|
||||
default:
|
||||
case 1113031:
|
||||
m_Type = ClockworkType.Wolf;
|
||||
break;
|
||||
case 1113032:
|
||||
m_Type = ClockworkType.Scorpion;
|
||||
break;
|
||||
case 1113033:
|
||||
m_Type = ClockworkType.Vollem;
|
||||
break;
|
||||
}
|
||||
|
||||
return quality;
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/MoonfireBrew.cs
Normal file
40
Scripts/Items/Quest/MoonfireBrew.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Engines.Quests.Hag
|
||||
{
|
||||
public class MoonfireBrew : Item
|
||||
{
|
||||
[Constructable]
|
||||
public MoonfireBrew()
|
||||
: base(0xF04)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public MoonfireBrew(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1055065;
|
||||
}
|
||||
}// a bottle of magical moonfire brew
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
35
Scripts/Items/Quest/MudPuppy.cs
Normal file
35
Scripts/Items/Quest/MudPuppy.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class MudPuppy : BigFish
|
||||
{
|
||||
public override int LabelNumber { get { return 1095117; } } // Britain Crown Fish
|
||||
|
||||
[Constructable]
|
||||
public MudPuppy()
|
||||
{
|
||||
Hue = 643;
|
||||
}
|
||||
|
||||
public MudPuppy(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = (InheritsItem ? 0 : reader.ReadInt()); // Required for BigFish insertion
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/NaxMarker.cs
Normal file
40
Scripts/Items/Quest/NaxMarker.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
//////////////////////////
|
||||
/// Created by Mitty ////
|
||||
////////////////////////
|
||||
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class NaxMarker : Item
|
||||
{
|
||||
[Constructable]
|
||||
public NaxMarker()
|
||||
: base(0x176B)
|
||||
{
|
||||
this.Weight = 0;
|
||||
this.Name = "Nax Marker";
|
||||
this.Hue = 0;
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Movable = false;
|
||||
this.Visible = false;
|
||||
}
|
||||
|
||||
public NaxMarker(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/NotarizedApplication.cs
Normal file
41
Scripts/Items/Quest/NotarizedApplication.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class NotarizedApplication : Item
|
||||
{
|
||||
[Constructable]
|
||||
public NotarizedApplication()
|
||||
: base(0x14EF)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public NotarizedApplication(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1073135;
|
||||
}
|
||||
}// Notarized Application
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
45
Scripts/Items/Quest/NoteForZoel.cs
Normal file
45
Scripts/Items/Quest/NoteForZoel.cs
Normal file
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using Server.Mobiles;
|
||||
|
||||
namespace Server.Engines.Quests.Ninja
|
||||
{
|
||||
public class NoteForZoel : QuestItem
|
||||
{
|
||||
public override int LabelNumber { get { return 1063186; } }// A Note for Zoel
|
||||
|
||||
[Constructable]
|
||||
public NoteForZoel()
|
||||
: base(0x14EF)
|
||||
{
|
||||
Weight = 1.0;
|
||||
Hue = 0x6B9;
|
||||
}
|
||||
|
||||
public NoteForZoel(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool CanDrop(PlayerMobile player)
|
||||
{
|
||||
EminosUndertakingQuest qs = player.Quest as EminosUndertakingQuest;
|
||||
|
||||
if (qs == null)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
274
Scripts/Items/Quest/Obsidian.cs
Normal file
274
Scripts/Items/Quest/Obsidian.cs
Normal file
@@ -0,0 +1,274 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Server.ContextMenus;
|
||||
using Server.Network;
|
||||
using Server.Targeting;
|
||||
|
||||
namespace Server.Engines.Quests.Collector
|
||||
{
|
||||
public class Obsidian : Item
|
||||
{
|
||||
private static readonly string[] m_Names = new string[]
|
||||
{
|
||||
null,
|
||||
"an aggressive cavalier",
|
||||
"a beguiling rogue",
|
||||
"a benevolent physician",
|
||||
"a brilliant artisan",
|
||||
"a capricious adventurer",
|
||||
"a clever beggar",
|
||||
"a convincing charlatan",
|
||||
"a creative inventor",
|
||||
"a creative tinker",
|
||||
"a cunning knave",
|
||||
"a dauntless explorer",
|
||||
"a despicable ruffian",
|
||||
"an earnest malcontent",
|
||||
"an exultant animal tamer",
|
||||
"a famed adventurer",
|
||||
"a fanatical crusader",
|
||||
"a fastidious clerk",
|
||||
"a fearless hunter",
|
||||
"a festive harlequin",
|
||||
"a fidgety assassin",
|
||||
"a fierce soldier",
|
||||
"a fierce warrior",
|
||||
"a frugal magnate",
|
||||
"a glib pundit",
|
||||
"a gnomic shaman",
|
||||
"a graceful noblewoman",
|
||||
"a idiotic madman",
|
||||
"a imaginative designer",
|
||||
"an inept conjurer",
|
||||
"an innovative architect",
|
||||
"an inventive blacksmith",
|
||||
"a judicious mayor",
|
||||
"a masterful chef",
|
||||
"a masterful woodworker",
|
||||
"a melancholy clown",
|
||||
"a melodic bard",
|
||||
"a merciful guard",
|
||||
"a mirthful jester",
|
||||
"a nervous surgeon",
|
||||
"a peaceful scholar",
|
||||
"a prolific gardener",
|
||||
"a quixotic knight",
|
||||
"a regal aristocrat",
|
||||
"a resourceful smith",
|
||||
"a reticent alchemist",
|
||||
"a sanctified priest",
|
||||
"a scheming patrician",
|
||||
"a shrewd mage",
|
||||
"a singing minstrel",
|
||||
"a skilled tailor",
|
||||
"a squeamish assassin",
|
||||
"a stoic swordsman",
|
||||
"a studious scribe",
|
||||
"a thought provoking writer",
|
||||
"a treacherous scoundrel",
|
||||
"a troubled poet",
|
||||
"an unflappable wizard",
|
||||
"a valiant warrior",
|
||||
"a wayward fool"
|
||||
};
|
||||
private const int m_Partial = 2;
|
||||
private const int m_Completed = 10;
|
||||
private int m_Quantity;
|
||||
private string m_StatueName;
|
||||
[Constructable]
|
||||
public Obsidian()
|
||||
: base(0x1EA7)
|
||||
{
|
||||
Hue = 0x497;
|
||||
|
||||
m_Quantity = 1;
|
||||
m_StatueName = "";
|
||||
}
|
||||
|
||||
public Obsidian(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public int Quantity
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Quantity;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (value <= 1)
|
||||
this.m_Quantity = 1;
|
||||
else if (value >= m_Completed)
|
||||
this.m_Quantity = m_Completed;
|
||||
else
|
||||
this.m_Quantity = value;
|
||||
|
||||
if (this.m_Quantity < m_Partial)
|
||||
this.ItemID = 0x1EA7;
|
||||
else if (this.m_Quantity < m_Completed)
|
||||
this.ItemID = 0x1F13;
|
||||
else
|
||||
this.ItemID = 0x12CB;
|
||||
|
||||
this.InvalidateProperties();
|
||||
}
|
||||
}
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public string StatueName
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_StatueName;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.m_StatueName = value;
|
||||
this.InvalidateProperties();
|
||||
}
|
||||
}
|
||||
public override bool ForceShowProperties
|
||||
{
|
||||
get
|
||||
{
|
||||
return ObjectPropertyList.Enabled;
|
||||
}
|
||||
}
|
||||
public static string RandomName(Mobile from)
|
||||
{
|
||||
int index = Utility.Random(m_Names.Length);
|
||||
if (m_Names[index] == null)
|
||||
return from.Name;
|
||||
else
|
||||
return m_Names[index];
|
||||
}
|
||||
|
||||
public override void AddNameProperty(ObjectPropertyList list)
|
||||
{
|
||||
if (this.m_Quantity < m_Partial)
|
||||
list.Add(1055137); // a section of an obsidian statue
|
||||
else if (this.m_Quantity < m_Completed)
|
||||
list.Add(1055138); // a partially reconstructed obsidian statue
|
||||
else
|
||||
list.Add(1055139, this.m_StatueName); // an obsidian statue of ~1_STATUE_NAME~
|
||||
}
|
||||
|
||||
public override void OnSingleClick(Mobile from)
|
||||
{
|
||||
if (this.m_Quantity < m_Partial)
|
||||
this.LabelTo(from, 1055137); // a section of an obsidian statue
|
||||
else if (this.m_Quantity < m_Completed)
|
||||
this.LabelTo(from, 1055138); // a partially reconstructed obsidian statue
|
||||
else
|
||||
this.LabelTo(from, 1055139, this.m_StatueName); // an obsidian statue of ~1_STATUE_NAME~
|
||||
}
|
||||
|
||||
public override void GetContextMenuEntries(Mobile from, List<ContextMenuEntry> list)
|
||||
{
|
||||
base.GetContextMenuEntries(from, list);
|
||||
|
||||
if (from.Alive && this.m_Quantity >= m_Partial && this.m_Quantity < m_Completed && this.IsChildOf(from.Backpack))
|
||||
list.Add(new DisassembleEntry(this));
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (this.m_Quantity < m_Completed)
|
||||
{
|
||||
if (!this.IsChildOf(from.Backpack))
|
||||
from.Send(new MessageLocalized(this.Serial, this.ItemID, MessageType.Regular, 0x2C, 3, 500309, "", "")); // Nothing Happens.
|
||||
else
|
||||
from.Target = new InternalTarget(this);
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.WriteEncodedInt(this.m_Quantity);
|
||||
writer.Write((string)this.m_StatueName);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
this.m_Quantity = reader.ReadEncodedInt();
|
||||
this.m_StatueName = Utility.Intern(reader.ReadString());
|
||||
}
|
||||
|
||||
private class DisassembleEntry : ContextMenuEntry
|
||||
{
|
||||
private readonly Obsidian m_Obsidian;
|
||||
public DisassembleEntry(Obsidian obsidian)
|
||||
: base(6142)
|
||||
{
|
||||
this.m_Obsidian = obsidian;
|
||||
}
|
||||
|
||||
public override void OnClick()
|
||||
{
|
||||
Mobile from = this.Owner.From;
|
||||
if (!this.m_Obsidian.Deleted && this.m_Obsidian.Quantity >= Obsidian.m_Partial && this.m_Obsidian.Quantity < Obsidian.m_Completed && this.m_Obsidian.IsChildOf(from.Backpack) && from.CheckAlive())
|
||||
{
|
||||
for (int i = 0; i < this.m_Obsidian.Quantity - 1; i++)
|
||||
from.AddToBackpack(new Obsidian());
|
||||
|
||||
this.m_Obsidian.Quantity = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private class InternalTarget : Target
|
||||
{
|
||||
private readonly Obsidian m_Obsidian;
|
||||
public InternalTarget(Obsidian obsidian)
|
||||
: base(-1, false, TargetFlags.None)
|
||||
{
|
||||
this.m_Obsidian = obsidian;
|
||||
}
|
||||
|
||||
protected override void OnTarget(Mobile from, object targeted)
|
||||
{
|
||||
Item targ = targeted as Item;
|
||||
if (this.m_Obsidian.Deleted || this.m_Obsidian.Quantity >= Obsidian.m_Completed || targ == null)
|
||||
return;
|
||||
|
||||
if (this.m_Obsidian.IsChildOf(from.Backpack) && targ.IsChildOf(from.Backpack) && targ is Obsidian && targ != this.m_Obsidian)
|
||||
{
|
||||
Obsidian targObsidian = (Obsidian)targ;
|
||||
if (targObsidian.Quantity < Obsidian.m_Completed)
|
||||
{
|
||||
if (targObsidian.Quantity + this.m_Obsidian.Quantity <= Obsidian.m_Completed)
|
||||
{
|
||||
targObsidian.Quantity += this.m_Obsidian.Quantity;
|
||||
this.m_Obsidian.Delete();
|
||||
}
|
||||
else
|
||||
{
|
||||
int delta = Obsidian.m_Completed - targObsidian.Quantity;
|
||||
targObsidian.Quantity += delta;
|
||||
this.m_Obsidian.Quantity -= delta;
|
||||
}
|
||||
|
||||
if (targObsidian.Quantity >= Obsidian.m_Completed)
|
||||
targObsidian.StatueName = Obsidian.RandomName(from);
|
||||
|
||||
from.Send(new AsciiMessage(targObsidian.Serial, targObsidian.ItemID, MessageType.Regular, 0x59, 3, this.m_Obsidian.Name, "Something Happened."));
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
from.Send(new MessageLocalized(this.m_Obsidian.Serial, this.m_Obsidian.ItemID, MessageType.Regular, 0x2C, 3, 500309, this.m_Obsidian.Name, "")); // Nothing Happens.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
35
Scripts/Items/Quest/OfficialSealingWax.cs
Normal file
35
Scripts/Items/Quest/OfficialSealingWax.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class OfficialSealingWax : Item
|
||||
{
|
||||
public override int LabelNumber { get { return 1072744; } }// Official Sealing Wax
|
||||
|
||||
[Constructable]
|
||||
public OfficialSealingWax()
|
||||
: base(0x1426)
|
||||
{
|
||||
LootType = LootType.Blessed;
|
||||
Weight = 1.0;
|
||||
Hue = 0x84;
|
||||
}
|
||||
|
||||
public OfficialSealingWax(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/OrdersFromMinax.cs
Normal file
40
Scripts/Items/Quest/OrdersFromMinax.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class OrdersFromMinax : Item
|
||||
{
|
||||
[Constructable]
|
||||
public OrdersFromMinax()
|
||||
: base(0x2279)
|
||||
{
|
||||
this.LootType = LootType.Blessed;
|
||||
}
|
||||
|
||||
public OrdersFromMinax(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074639;
|
||||
}
|
||||
}// Orders from Minax
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
93
Scripts/Items/Quest/PaintedImage.cs
Normal file
93
Scripts/Items/Quest/PaintedImage.cs
Normal file
@@ -0,0 +1,93 @@
|
||||
using System;
|
||||
using Server.Gumps;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Quests.Collector
|
||||
{
|
||||
public class PaintedImage : Item
|
||||
{
|
||||
private ImageType m_Image;
|
||||
[Constructable]
|
||||
public PaintedImage(ImageType image)
|
||||
: base(0xFF3)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
this.Hue = 0x8FD;
|
||||
|
||||
this.m_Image = image;
|
||||
}
|
||||
|
||||
public PaintedImage(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public ImageType Image
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.m_Image;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.m_Image = value;
|
||||
this.InvalidateProperties();
|
||||
}
|
||||
}
|
||||
public override void AddNameProperty(ObjectPropertyList list)
|
||||
{
|
||||
ImageTypeInfo info = ImageTypeInfo.Get(this.m_Image);
|
||||
list.Add(1060847, "#1055126\t#" + info.Name); // a painted image of:
|
||||
}
|
||||
|
||||
public override void OnSingleClick(Mobile from)
|
||||
{
|
||||
ImageTypeInfo info = ImageTypeInfo.Get(this.m_Image);
|
||||
this.LabelTo(from, 1060847, "#1055126\t#" + info.Name); // a painted image of:
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (!from.InRange(this.GetWorldLocation(), 2))
|
||||
{
|
||||
from.LocalOverheadMessage(MessageType.Regular, 0x3B2, 1019045); // I can't reach that.
|
||||
return;
|
||||
}
|
||||
|
||||
from.SendGump(new InternalGump(this.m_Image));
|
||||
}
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
|
||||
writer.WriteEncodedInt((int)this.m_Image);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
this.m_Image = (ImageType)reader.ReadEncodedInt();
|
||||
}
|
||||
|
||||
private class InternalGump : Gump
|
||||
{
|
||||
public InternalGump(ImageType image)
|
||||
: base(75, 25)
|
||||
{
|
||||
ImageTypeInfo info = ImageTypeInfo.Get(image);
|
||||
|
||||
this.AddBackground(45, 20, 100, 100, 0xA3C);
|
||||
this.AddBackground(52, 29, 86, 82, 0xBB8);
|
||||
|
||||
this.AddItem(info.X, info.Y, info.Figurine);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
67
Scripts/Items/Quest/ParoxysmusKey.cs
Normal file
67
Scripts/Items/Quest/ParoxysmusKey.cs
Normal file
@@ -0,0 +1,67 @@
|
||||
using System;
|
||||
using Server.Engines.PartySystem;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class ParoxysmusKey : MasterKey
|
||||
{
|
||||
public override int LabelNumber { get { return 1074330; } } // slimy ointment
|
||||
|
||||
public ParoxysmusKey()
|
||||
: base(0xEFB)
|
||||
{
|
||||
Weight = 1.0;
|
||||
Hue = 0x497;
|
||||
}
|
||||
|
||||
public ParoxysmusKey(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
if (!IsChildOf(from.Backpack))
|
||||
{
|
||||
from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it.
|
||||
}
|
||||
else if (Altar != null && (Altar.Owner == from || Party.Get(from) == Party.Get(Altar.Owner)))
|
||||
{
|
||||
if (Altar.Peerless == null)
|
||||
{
|
||||
Altar.SpawnBoss();
|
||||
}
|
||||
|
||||
Altar.AddFighter(from);
|
||||
ParoxysmusAltar.AddProtection(from);
|
||||
from.LocalOverheadMessage(MessageType.Regular, 58, 1074603); // You rub the slimy ointment on your body, temporarily protecting yourself from the corrosive river.
|
||||
Delete();
|
||||
}
|
||||
}
|
||||
|
||||
public override int Lifespan { get { return 600; } }
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override bool CanOfferConfirmation(Mobile from)
|
||||
{
|
||||
if (from.Region != null && from.Region.IsPartOf("Palace of Paroxysmus"))
|
||||
return base.CanOfferConfirmation(from);
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/PartiallyDigestedTorso.cs
Normal file
40
Scripts/Items/Quest/PartiallyDigestedTorso.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class PartiallyDigestedTorso : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public PartiallyDigestedTorso()
|
||||
: base(0x1D9F)
|
||||
{
|
||||
this.Weight = 1.0;
|
||||
}
|
||||
|
||||
public PartiallyDigestedTorso(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074326;
|
||||
}
|
||||
}// partially digested torso
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
41
Scripts/Items/Quest/PiecesOfCrystal.cs
Normal file
41
Scripts/Items/Quest/PiecesOfCrystal.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class PiecesOfCrystal : PeerlessKey
|
||||
{
|
||||
[Constructable]
|
||||
public PiecesOfCrystal()
|
||||
: base(0x2245)
|
||||
{
|
||||
this.Weight = 1;
|
||||
this.Hue = 0x2B2;
|
||||
}
|
||||
|
||||
public PiecesOfCrystal(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1074263;
|
||||
}
|
||||
}// crushed crystal pieces
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
42
Scripts/Items/Quest/PileofInspectedAgapiteIngots.cs
Normal file
42
Scripts/Items/Quest/PileofInspectedAgapiteIngots.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class PileofInspectedAgapiteIngots : Item
|
||||
{
|
||||
[Constructable]
|
||||
public PileofInspectedAgapiteIngots()
|
||||
: base(0x1BEA)
|
||||
{
|
||||
this.Name = "Pile of Inspected Agapite Ingots";
|
||||
|
||||
this.Hue = 2425;
|
||||
}
|
||||
|
||||
public PileofInspectedAgapiteIngots(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1113770;
|
||||
}
|
||||
}//Essence Box
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/PileofInspectedBronzeIngots.cs
Normal file
40
Scripts/Items/Quest/PileofInspectedBronzeIngots.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class PileofInspectedBronzeIngots : Item
|
||||
{
|
||||
[Constructable]
|
||||
public PileofInspectedBronzeIngots()
|
||||
: base(0x1BEA)
|
||||
{
|
||||
this.Hue = 2418;
|
||||
}
|
||||
|
||||
public PileofInspectedBronzeIngots(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1113024;
|
||||
}
|
||||
}//Pile of Inspected Bronze Ingots
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
Scripts/Items/Quest/PileofInspectedCopperIngots.cs
Normal file
40
Scripts/Items/Quest/PileofInspectedCopperIngots.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class PileofInspectedCopperIngots : Item
|
||||
{
|
||||
[Constructable]
|
||||
public PileofInspectedCopperIngots()
|
||||
: base(0x1BEA)
|
||||
{
|
||||
this.Hue = 2413;
|
||||
}
|
||||
|
||||
public PileofInspectedCopperIngots(Serial serial)
|
||||
: base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
get
|
||||
{
|
||||
return 1113023;
|
||||
}
|
||||
}//Pile of Inspected Copper Ingots
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write((int)0);
|
||||
}
|
||||
|
||||
public override void Deserialize(GenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user