示例#1
0
        private static void Game_OnGameLoad(EventArgs args)
        {
            try {
                /*ObjectHandle handle = Activator.CreateInstance(null,
                    "Assemblies." + ObjectManager.Player.ChampionName);

                champion = (Champion) handle.Unwrap();*/
                switch (ObjectManager.Player.ChampionName) {
                    case "Ezreal":
                        champion = new Ezreal();
                        break;
                    case "Vayne":
                        champion = new VayneHunter();
                        break;
                    case "Fizz":
                        champion = new Fizz();
                        break;
                    default:
                        champion = new Champion();
                        break;
                }
            }
            catch {
                Console.WriteLine("Fail.");
            }
        }
示例#2
0
        private static void Game_OnGameLoad(EventArgs args)
        {
            try {
                ObjectHandle handle = Activator.CreateInstance(null,
                    "Assemblies." + ObjectManager.Player.ChampionName);

                champion = (Champion) handle.Unwrap();
            }
            catch {
                Console.WriteLine("Fail.");
            }
        }