public override void OnDetached()
        {
            base.OnDetached();

            var settings = Bot.Settings.GetOrAddEntry <BasicPluginSettings>();

            settings.FloodEntries = FloodEntries.ToArray();

            BotViewModel viewModel = Bot.GetViewModel();

            viewModel.RemoveDocument(View);
        }
        public void HandleGameRolePlayShowActorMessage(Bot bot, GameRolePlayShowActorMessage message)
        {
            if (!IsFloodEnabled)
            {
                return;
            }

            var character = bot.Character.Context.GetActor(message.informations.contextualId) as IPlayer;

            if (character != null)
            {
                foreach (FloodEntry floodEntry in FloodEntries.Where(x => x.OnCharacterEnterMap))
                {
                    ExecuteEntry(floodEntry, new[] { character });
                }
            }
        }