/// <summary> /// Show sticky notification. /// </summary> public void ShowNotifySticky() { NotifySimpleTemplate.Clone().Show( "Sticky Notification. Click on the × above to close.", customHideDelay: 0f ); }
void Buy() { var order = new JRPGOrder(ShopItems.DataSource); if (Player.CanBuy(order)) { Shop.Sell(order); Player.Buy(order); } else { var message = string.Format("Not enough money to buy items. Available: {0}; Required: {1}", Player.Money, order.Total()); NotifyTemplate.Clone().Show(message, customHideDelay: 3f, sequenceType: NotifySequence.First, clearSequence: true); } }
/// <summary> /// Show notification for specified item index. /// </summary> /// <param name="index">Item index.</param> public void Notification(int index) { var message = ListView.SelectedIndex == -1 ? "Nothing selected" : "Selected: " + ListView.SelectedItem.Name; NotifyTemplate.Clone().Show( message, customHideDelay: 5f ); }
/// <summary> /// Show notify. /// </summary> public void ShowNotify() { NotifyTemplate.Clone().Show("Achievement unlocked. Hide after 3 seconds.", customHideDelay: 3f); }