fix: Updates disguises and codegens tinkering items (#1353)
This commit is contained in:
parent
f2fdc0321c
commit
d14e864c85
56 changed files with 1012 additions and 1454 deletions
|
|
@ -1,96 +1,74 @@
|
|||
using ModernUO.Serialization;
|
||||
using Server.Engines.Quests.Hag;
|
||||
using Server.Mobiles;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Items
|
||||
namespace Server.Items;
|
||||
|
||||
[Flippable(0x14F5, 0x14F6)]
|
||||
[SerializationGenerator(0, false)]
|
||||
public partial class Spyglass : Item
|
||||
{
|
||||
[Flippable(0x14F5, 0x14F6)]
|
||||
public class Spyglass : Item
|
||||
[Constructible]
|
||||
public Spyglass() : base(0x14F5) => Weight = 3.0;
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
[Constructible]
|
||||
public Spyglass() : base(0x14F5) => Weight = 3.0;
|
||||
// You peer into the heavens, seeking the moons...
|
||||
from.LocalOverheadMessage(MessageType.Regular, 0x3B2, 1008155);
|
||||
|
||||
public Spyglass(Serial serial) : base(serial)
|
||||
from.NetState.SendMessageLocalizedAffix(
|
||||
from.Serial,
|
||||
from.Body,
|
||||
MessageType.Regular,
|
||||
0x3B2,
|
||||
3,
|
||||
1008146 + (int)Clock.GetMoonPhase(Map.Trammel, from.X, from.Y),
|
||||
"",
|
||||
AffixType.Prepend,
|
||||
"Trammel : "
|
||||
);
|
||||
|
||||
from.NetState.SendMessageLocalizedAffix(
|
||||
from.Serial,
|
||||
from.Body,
|
||||
MessageType.Regular,
|
||||
0x3B2,
|
||||
3,
|
||||
1008146 + (int)Clock.GetMoonPhase(Map.Felucca, from.X, from.Y),
|
||||
"",
|
||||
AffixType.Prepend,
|
||||
"Felucca : "
|
||||
);
|
||||
|
||||
if (from is PlayerMobile player)
|
||||
{
|
||||
}
|
||||
var qs = player.Quest;
|
||||
|
||||
public override void OnDoubleClick(Mobile from)
|
||||
{
|
||||
from.LocalOverheadMessage(
|
||||
MessageType.Regular,
|
||||
0x3B2,
|
||||
1008155
|
||||
); // You peer into the heavens, seeking the moons...
|
||||
|
||||
from.NetState.SendMessageLocalizedAffix(
|
||||
from.Serial,
|
||||
from.Body,
|
||||
MessageType.Regular,
|
||||
0x3B2,
|
||||
3,
|
||||
1008146 + (int)Clock.GetMoonPhase(Map.Trammel, from.X, from.Y),
|
||||
"",
|
||||
AffixType.Prepend,
|
||||
"Trammel : "
|
||||
);
|
||||
|
||||
from.NetState.SendMessageLocalizedAffix(
|
||||
from.Serial,
|
||||
from.Body,
|
||||
MessageType.Regular,
|
||||
0x3B2,
|
||||
3,
|
||||
1008146 + (int)Clock.GetMoonPhase(Map.Felucca, from.X, from.Y),
|
||||
"",
|
||||
AffixType.Prepend,
|
||||
"Felucca : "
|
||||
);
|
||||
|
||||
if (from is PlayerMobile player)
|
||||
if (qs is not WitchApprenticeQuest)
|
||||
{
|
||||
var qs = player.Quest;
|
||||
return;
|
||||
}
|
||||
|
||||
if (qs is not WitchApprenticeQuest)
|
||||
var obj = qs.FindObjective<FindIngredientObjective>();
|
||||
|
||||
if (obj?.Completed == false && obj.Ingredient == Ingredient.StarChart)
|
||||
{
|
||||
Clock.GetTime(from.Map, from.X, from.Y, out var hours, out int _);
|
||||
|
||||
if (hours is < 5 or > 17)
|
||||
{
|
||||
return;
|
||||
// You gaze up into the glittering night sky. With great care, you compose a chart of the most prominent star patterns.
|
||||
player.SendLocalizedMessage(1055040);
|
||||
|
||||
obj.Complete();
|
||||
}
|
||||
|
||||
var obj = qs.FindObjective<FindIngredientObjective>();
|
||||
|
||||
if (obj?.Completed == false && obj.Ingredient == Ingredient.StarChart)
|
||||
else
|
||||
{
|
||||
Clock.GetTime(from.Map, from.X, from.Y, out var hours, out int _);
|
||||
|
||||
if (hours is < 5 or > 17)
|
||||
{
|
||||
player.SendLocalizedMessage(
|
||||
1055040
|
||||
); // You gaze up into the glittering night sky. With great care, you compose a chart of the most prominent star patterns.
|
||||
|
||||
obj.Complete();
|
||||
}
|
||||
else
|
||||
{
|
||||
player.SendLocalizedMessage(
|
||||
1055039
|
||||
); // You gaze up into the sky, but it is not dark enough to see any stars.
|
||||
}
|
||||
// You gaze up into the sky, but it is not dark enough to see any stars.
|
||||
player.SendLocalizedMessage(1055039);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Serialize(IGenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(IGenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
var version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue