public static void OnLoad() { Persistence.Deserialize( FilePath, reader => { int version = reader.ReadInt(); switch (version) { case 1: { TownCryerSystem.Load(reader); goto case 0; } case 0: { int count = reader.ReadInt(); for (int i = 0; i < count; i++) { TownCrierEntry entry = new TownCrierEntry(reader); if (!entry.Expired) { Instance.AddEntry(entry); } } } break; } }); }
public void CompleteQuest() { OnCompleted(); Objectives[0].CurProgress++; TownCryerSystem.CompleteQuest(Owner, 1016275, Complete, 0x619); GiveRewards(); }
public override void OnDoubleClick(Mobile m) { if (m is PlayerMobile) { var pm = m as PlayerMobile; if (QuestHelper.HasQuest <AForcedSacraficeQuest2>(pm)) { if (!TownCryerSystem.UnderMysteriousPotionEffects(pm)) { pm.SendGump(new ConfirmCallbackGump(pm, 1158286, 1158287, null, null, confirm: (mob, o) => { TownCryerSystem.AddMysteriousPotionEffects(mob); mob.FixedParticles(0x376A, 9, 32, 5007, EffectLayer.Waist); mob.PlaySound(0x1E3); BasePotion.PlayDrinkEffect(mob); Delete(); })); } else { pm.SendLocalizedMessage(1158289); // You have already used this. } } else { pm.SendLocalizedMessage(1158285); // You must be on the "A Forced Sacrifice" quest to use this item. } } }
public override void OnChestOpened(Mobile from, TreasureMapChest chest) { if (from is PlayerMobile) { var quest = QuestHelper.GetQuest <TheTreasureChaseQuest>((PlayerMobile)from); if (quest != null) { if (Level == 0) { TownCryerSystem.CompleteQuest((PlayerMobile)from, 1158239, 1158251, 0x655); /*Your eyes widen as you pry open the old chest and reveal the treasure within! Even this small cache * excites you as the thought of bigger and better treasure looms on the horizon! The map is covered * in ancient runes and marks the location of another treasure hoard. You carefully furl the map and * set off on your next adventure!*/ from.SendLocalizedMessage(1158245, "", 0x23); // You have found the first zealot treasure! As you dig up the chest a leather bound case appears to contain an additional map. You place it in your backpack for later examination. chest.DropItem(new BuriedRichesTreasureMap(1)); } else { from.SendLocalizedMessage(1158246, "", 0x23); // You have found the second zealot treasure! As you dig up the chest a leather bound case appears to contain an additional map. You place it in your backpack for later examination. quest.CompleteQuest(); } } } }
public void CompleteQuest() { OnCompleted(); Objectives[0].CurProgress++; TownCryerSystem.CompleteQuest(Owner, 1153468, 1158309, 0x65C); GiveRewards(); }
public void CompleteChallenge() { OnCompleted(); Objectives[0].CurProgress++; TownCryerSystem.CompleteQuest(Owner, this); GiveRewards(); }
public void CompleteQuest() { OnCompleted(); Objectives[0].Complete(); TownCryerSystem.CompleteQuest(Owner, 1158275, 1158276, 0x65B); GiveRewards(); }
public void CompleteQuest() { TownCryerSystem.CompleteQuest(Owner, 1158303, 1158323, 0x650); GiveRewards(); Owner.SendLocalizedMessage(1158326); // For your accomplishments you have been awarded a bonus 1000 Despise points! Trade with the wisp to redeem them! Server.Engines.Points.PointsSystem.DespiseCrystals.AwardPoints(Owner, 1000, false, false); }
public void CompleteQuest() { TownCryerSystem.CompleteQuest(Owner, 1158280, 1158281, 0x623); GiveRewards(); Server.Engines.Points.PointsSystem.VoidPool.AwardPoints(Owner, 2000, false, false); Owner.SendLocalizedMessage(1158282); // For your accomplishments you have been awarded a bonus 2000 Covetous points! Visit Vela in the Town of Cove to redeem them! }
public override void GetContextMenuEntries(Mobile from, List <ContextMenuEntry> list) { base.GetContextMenuEntries(from, list); if (TownCryerSystem.Enabled) { TownCryerSystem.GetContextMenus(this, from, list); } }
public void CompleteQuest() { TownCryerSystem.CompleteQuest(Owner, new RightingWrongQuest()); OnCompleted(); GiveRewards(); QuestHelper.Delay(Owner, typeof(RightingWrongQuest2), RestartDelay); }
public void CompleteQuest() { TownCryerSystem.CompleteQuest(Owner, new PaladinsOfTrinsic()); OnCompleted(); GiveRewards(); QuestHelper.Delay(Owner, typeof(PaladinsOfTrinsic), RestartDelay); }
public static void CheckLocation(PlayerMobile pm, Point3D oldLocation) { AVisitToCastleBlackthornQuest quest = QuestHelper.GetQuest <AVisitToCastleBlackthornQuest>(pm); if (quest != null) { quest.OnCompleted(); TownCryerSystem.CompleteQuest(quest.Owner, 1158202, quest.Complete, 0x61B); quest.Objectives[0].CurProgress++; quest.GiveRewards(); } }
public static void OnSave(WorldSaveEventArgs e) { Persistence.Serialize( FilePath, writer => { writer.Write(1); TownCryerSystem.Save(writer); writer.Write(Instance.Entries == null ? 0 : Instance.Entries.Count); if (Instance.Entries != null) { Instance.Entries.ForEach(entry => entry.Serialize(writer)); } }); }
public void CompleteQuest() { OnCompleted(); Objectives[0].CurProgress++; TownCryerSystem.CompleteQuest(Owner, 1158239, 1158249, 0x655); /*Another rusted chest emerges from the broken ground at your feet! As you pry it open the brilliant * shimmer of gold and jewels catches your eye. This map too is highly decorated with ancient runic * text and marks another location for the hoard. You notice the magical creatures guarding the previous * hoard were more challenging than the first, and you expect that trend to continue. With greater * difficulty comes greater reward! On the reverse of the map is a short hand-written note,<br><br><i>For * those who will come long after and discover this treasure, know you will never truly discover the * extent of our wealth. If you posses this map you no doubt have some connection to our society, which * has survived generation after generation. Use this wealth for what we have used it for, to be virtuous * and good throughout Sosaria...</i><br><br>The note is very cryptic about the origins of these zealots * and their beliefs, but from what you can gleam they are a long gone organization who's values were * that of virtue and good. You are warmed by this altruistic purpose and decide to use your wealth to * promote their cause throughout the realm as you search for other treasures.*/ GiveRewards(); }