Example #1
0
        public Updater(BemVisage main)
        {
            _main = main;

            try
            {
                foreach (var unit in EntityManager <Unit> .Entities)
                {
                    if (unit.NetworkName.Contains("CDOTA_Unit_VisageFamiliar") && unit.Team == main.Context.Owner.Team)
                    {
                        allFamiliars[unit.Handle.Handle] = new Familiar(_main, unit);
                        Log.Debug($"new familiar found");
                    }
                    if (unit.NetworkName.Contains("CDOTA_BaseNPC_Creep_Neutral") && unit.Team == main.Context.Owner.Team &&
                        unit.IsControllable && unit.IsControllableByPlayer(ObjectManager.LocalPlayer))
                    {
                        allOtherUnits[unit.Handle.Handle] = new OtherUnits(_main, unit);
                        Log.Debug($"new unit found");
                    }
                }

                Handler = UpdateManager.Subscribe(OnUpdate);
            }
            catch
            {
                //Ignore
            }

            EntityManager <Unit> .EntityAdded   += EntityManagerOnEntityAdded;
            EntityManager <Unit> .EntityRemoved += EntityManagerOnEntityRemoved;
        }
Example #2
0
        public LaneHelper(BemVisage Main)
        {
            bemVisage = Main;
            Map       = new Map();
            var isRadiant = ObjectManager.LocalHero.Team == Team.Radiant;

            TopPath   = isRadiant ? Map.RadiantTopRoute : Map.DireTopRoute;
            MidPath   = isRadiant ? Map.RadiantMiddleRoute : Map.DireMiddleRoute;
            BotPath   = isRadiant ? Map.RadiantBottomRoute : Map.DireBottomRoute;
            LaneCache = new Dictionary <Unit, List <Vector3> >();
        }
Example #3
0
        public Config(BemVisage Main)
        {
            bemVisage = Main;
            NoobFailSafe();

            multiSleeper = new MultiSleeper();

            Factory             = MenuFactory.Create("bemVisage");
            LanePushing         = Factory.Menu("Lane Push");
            AbilitiesInCombo    = Factory.Menu("Combo Abilities");
            Drawings            = Factory.Menu("Drawings");
            CameraPositioner    = Factory.Menu("Camera Positioner");
            LinkenBreaker       = AbilitiesInCombo.Menu("Linken Breaker");
            ComboMenu           = AbilitiesInCombo.Menu("Combo Menu");
            FamiliarMenu        = Factory.Menu("Unit Menu");
            ComboKey            = ComboMenu.Item("Combo", new KeyBind(32));
            TargetOption        = ComboMenu.Item("Target Option", new StringList("Lock", "Default"));
            BmBehavior          = ComboMenu.Item("Keep combo if Blade Mail", false);
            BlinkDistance2Mouse = ComboMenu.Item("Blink Distance to Mouse", new Slider(600, 0, 1200));
            BlinkDistance2Enemy = ComboMenu.Item("Blink Distance to Enemy", new Slider(250, 0, 550));
            //OrbwalkMinimumDistance = ComboMenu.Item("Orbwalker Minimum Distance", new Slider(500, 0, 600));
            //OrbwalkMinimumDistance.Item.Tooltip = "Set to 0 to disable";


            FamiliarsLock = FamiliarMenu.Item("Units Target Lock", new KeyBind('E', KeyBindType.Toggle, false));
            FollowKey     = FamiliarMenu.Item("Follow Key", new KeyBind('F', KeyBindType.Toggle, false));

            LasthitKey = LanePushing.Item("Lane Push Key", new KeyBind('D', KeyBindType.Toggle, false));

            SoulAssumptionDraw  = Drawings.Item("Draw Soul Assumption Range", true);
            GraveChillsDraw     = Drawings.Item("Draw Grave Chills Range", true);
            DrawTargetIndicator = Drawings.Item("Draw target indicator", true);
            DrawInformationTab  = Drawings.Item("Draw information tab", true);
            TextSize            = Drawings.Item("Text size", new Slider(13, 1, 100));
            PosX = Drawings.Item("Drawing X", new Slider(1750, 0, 1800));
            PosY = Drawings.Item("Drawing Y", new Slider(850, 0, 1800));

            CameraEnabled = CameraPositioner.Item("Enabled", false);
            ComboKey.Item.ValueChanged += ComboKeyChanged;
            ComboKey.PropertyChanged   += ComboKeyPropertyChanged;
            var key = KeyInterop.KeyFromVirtualKey((int)ComboKey.Value.Key);

            VisageOrbwalking = new VisageOrbwalking(key, this);
            bemVisage.Context.Orbwalker.RegisterMode(VisageOrbwalking);
        }