public override void OnDoubleClick(Mobile from) { if (DateTime.Now > (this.m_LastUse + UseDelay)) { if (!MapTable.ContainsKey(from)) { MapTable.Add(from, new CorgulContext(from)); } else { MapTable[from].SacrificedWMap = false; MapTable[from].SacrificedTMap = false; } } if (!MapTable.ContainsKey(from) || !MapTable[from].SacrificedTMap) { MapTable[from] = new CorgulContext(from); from.SendMessage("Select a treasure map.."); from.BeginTarget(2, false, TargetFlags.None, new TargetCallback(OnTargetTMap)); } else if (!MapTable[from].RewardReceived()) { from.SendMessage("You've already sacrificed a treasure map. You must now sacrifice a world map.."); from.BeginTarget(2, false, TargetFlags.None, new TargetCallback(OnTargetWMap)); } else { from.SendMessage("You have already received your reward from this altar."); from.SendMessage("Please wait at least one hour before attempting another sacrifice."); } }
public override void OnDoubleClick(Mobile from) { if(DateTime.Now > (this.m_LastUse + UseDelay)) { if ( !MapTable.ContainsKey(from) ) { MapTable.Add(from, new CorgulContext(from)); } else { MapTable[from].SacrificedWMap = false; MapTable[from].SacrificedTMap = false; } } if(!MapTable.ContainsKey(from) || !MapTable[from].SacrificedTMap) { MapTable[from] = new CorgulContext(from); from.SendMessage("Select a treasure map.."); from.BeginTarget(2, false, TargetFlags.None, new TargetCallback( OnTargetTMap )); } else if(!MapTable[from].RewardReceived()) { from.SendMessage("You've already sacrificed a treasure map. You must now sacrifice a world map.."); from.BeginTarget(2, false, TargetFlags.None, new TargetCallback( OnTargetWMap )); } else { from.SendMessage("You have already received your reward from this altar."); from.SendMessage("Please wait at least one hour before attempting another sacrifice."); } }