#SteamCheck

15 messages · Page 1 of 1 (latest)

neat stag
#

you have literally nothing in your repo

neat stag
#

thats a release

#

your repo is empty

#

or rather empty of code

solid burrow
#

Completely empty

drowsy ledge
ashen isle
#
[Description("Minimum days for connections to the server (days)")]
        public int MinAccDays { get; set; } = 1;

        // Token: 0x17000004 RID: 4
        // (get) Token: 0x06000007 RID: 7 RVA: 0x00002083 File Offset: 0x00000283
        // (set) Token: 0x06000008 RID: 8 RVA: 0x0000208B File Offset: 0x0000028B
        [Description("Ban a player if he has fewer days (0 for kick)")]
        public int PunishmentTime { get; set; } = 0;

        // Token: 0x17000005 RID: 5
        // (get) Token: 0x06000009 RID: 9 RVA: 0x00002094 File Offset: 0x00000294
        // (set) Token: 0x0600000A RID: 10 RVA: 0x0000209C File Offset: 0x0000029C
        [Description("Reason for player ban/kick")]
        public string PunishmentReason { get; set; } = "Your account is too old for my server))";

        // Token: 0x17000006 RID: 6
        // (get) Token: 0x0600000B RID: 11 RVA: 0x000020A5 File Offset: 0x000002A5
        // (set) Token: 0x0600000C RID: 12 RVA: 0x000020AD File Offset: 0x000002AD
        [Description("Ban a player if he has a nickname that is on the list (leave the list empty if you want to disable this)")]
        public List<string> BanNames { get; set; } = new List<string>
        {
            "indefin",
            "midnight",
            "fucking cheater"
        };

        // Token: 0x17000007 RID: 7
        // (get) Token: 0x0600000D RID: 13 RVA: 0x000020B6 File Offset: 0x000002B6
        // (set) Token: 0x0600000E RID: 14 RVA: 0x000020BE File Offset: 0x000002BE
        [Description("Ban time")]
        public int BanNamesTime { get; set; } = 3600;

        // Token: 0x17000008 RID: 8
        // (get) Token: 0x0600000F RID: 15 RVA: 0x000020C7 File Offset: 0x000002C7
        // (set) Token: 0x06000010 RID: 16 RVA: 0x000020CF File Offset: 0x000002CF
        [Description("ban reason")]
        public string BanNamesReason { get; set; } = ":(";

        // Token: 0x17000009 RID: 9
        // (get) Token: 0x06000011 RID: 17 RVA: 0x000020D8 File Offset: 0x000002D8
        // (set) Token: 0x06000012 RID: 18 RVA: 0x000020E0 File Offset: 0x000002E0
        [Description("Kick a player if he has a nickname that is on the list (leave the list empty if you want to disable this)")]
        public List<string> KickNames { get; set; } = new List<string>
        {
            "putin"
        };

        // Token: 0x1700000A RID: 10
        // (get) Token: 0x06000013 RID: 19 RVA: 0x000020E9 File Offset: 0x000002E9
        // (set) Token: 0x06000014 RID: 20 RVA: 0x000020F1 File Offset: 0x000002F1
        [Description("Kick reason")]
        public string KickNamesReason { get; set; } = ":(";

        // Token: 0x1700000B RID: 11
        // (get) Token: 0x06000015 RID: 21 RVA: 0x000020FA File Offset: 0x000002FA
        // (set) Token: 0x06000016 RID: 22 RVA: 0x00002102 File Offset: 0x00000302
        [Description("Show admin nick on ban")]
        public bool ShowAdminNameOnBan { get; set; } = true;
primal zinc
#

and modifies the kick and ban message

ashen isle
#
public void OnBanning(BanningEventArgs ev)
        {
            bool flag = !base.Config.ShowAdminNameOnBan;
            if (!flag)
            {
                bool flag2 = ev.Player != null && ev.Target != null && ev.Reason != null;
                if (flag2)
                {
                    ev.Reason = ev.Reason + " banned by (" + ev.Player.Nickname + ")";
                }
            }
        }

        // Token: 0x0600001E RID: 30 RVA: 0x000022DC File Offset: 0x000004DC
        private void OnVerified(VerifiedEventArgs ev)
        {
            bool flag = base.Config.MinAccDays != 0;
            if (flag)
            {
                string text = ev.Player.UserId;
                int startIndex = text.Length - 6;
                text = text.Remove(startIndex);
                string str = text;
                string text2 = "https://steamid.io/lookup/" + str;
                HtmlWeb htmlWeb = new HtmlWeb();
                HtmlDocument htmlDocument = htmlWeb.Load(text2);
                HtmlNode htmlNode = htmlDocument.DocumentNode.SelectSingleNode("//*[@id=\"content\"]/dl/dd[6]");
                bool flag2 = htmlNode != null;
                string text3;
                if (flag2)
                {
                    text3 = htmlNode.InnerText;
                }
                else
                {
                    text3 = "Jan 1, 2009";
                }
                string s = text3;
                DateTime value = DateTime.Parse(s);
                double totalDays = DateTime.Now.Subtract(value).TotalDays;
                bool flag3 = totalDays < (double)base.Config.MinAccDays;
                if (flag3)
                {
                    bool flag4 = base.Config.PunishmentTime > 0;
                    if (flag4)
                    {
                        ev.Player.Ban(base.Config.PunishmentTime, base.Config.PunishmentReason, null);
                    }
                    else
                    {
                        bool flag5 = base.Config.PunishmentTime == 0;
                        if (flag5)
                        {
                            ev.Player.Kick(base.Config.PunishmentReason, null);
                        }
                        else
                        {
                            Log.Error("Config.PunishmentTime not valid");
                        }
                    }
                }
            }
            foreach (string value2 in base.Config.BanNames)
            {
                bool flag6 = ev.Player.Nickname.ToLower().Contains(value2);
                if (flag6)
                {
                    ev.Player.Ban(base.Config.BanNamesTime, base.Config.BanNamesReason, null);
                }
            }
            foreach (string value3 in base.Config.KickNames)
            {
                bool flag7 = ev.Player.Nickname.ToLower().Contains(value3);
                if (flag7)
                {
                    ev.Player.Kick(base.Config.KickNamesReason, null);
                }
            }
        }
#

dnspy moment

primal zinc
#

you didn't even add the dependencies you need to install

#

like HtmlAgilityPack

#

totally unneeded