本文整理汇总了C#中LeagueSharp.Common.Menu.GetSlider方法的典型用法代码示例。如果您正苦于以下问题:C# Menu.GetSlider方法的具体用法?C# Menu.GetSlider怎么用?C# Menu.GetSlider使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LeagueSharp.Common.Menu
的用法示例。
在下文中一共展示了Menu.GetSlider方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnGameLoad
private static void OnGameLoad(EventArgs args)
{
_menuMap = new Dictionary<MenuItem, int>();
_menu = new Menu("【红叶推介】自动加点", "UniversalLeveler" + ObjectManager.Player.ChampionName, true);
foreach (var entry in DefaultSpellSlotPriorities)
{
MenuItem menuItem = MakeSlider(
entry.Key.ToString(), entry.Key.ToString(), entry.Value, 1, DefaultSpellSlotPriorities.Count);
menuItem.ValueChanged += menuItem_ValueChanged;
_menu.AddItem(menuItem);
var subMenu = new Menu(entry.Key + " Extra", entry.Key + "extra");
subMenu.AddItem(MakeSlider(entry.Key + "extra", "Level after X (inclusive) ?", 1, 1, 18));
_menu.AddSubMenu(subMenu);
}
_activate = new MenuItem("activate", "Start at level?").SetValue(new StringList(new[] { "2", "3", "4" }));
_delay = new MenuItem("delay", "LevelUp Delay (ms)").SetValue(new Slider(0, 0, 2000));
_menu.AddItem(_activate);
_menu.AddItem(_delay);
_menu.AddToMainMenu();
foreach (var entry in DefaultSpellSlotPriorities)
{
MenuItem item = _menu.GetSlider(entry.Key.ToString());
_menuMap[item] = item.GetValue<Slider>().Value;
}
ParseMenu();
_levelStrategy = new DefaultLevelStrategy();
if (LevelStrategyByChampion.ContainsKey(ObjectManager.Player.ChampionName))
{
_levelStrategy = LevelStrategyByChampion[ObjectManager.Player.ChampionName];
}
_level = ObjectManager.Player.Level;
//CustomEvents.Unit.OnLevelUp += UnitOnOnLevelUp;
Game.OnUpdate += Game_OnUpdate;
Print("Loaded!");
}