// Token: 0x0600152E RID: 5422 RVA: 0x0002D2CC File Offset: 0x0002B4CC
 private void method_5(Control4.Class311 btn, Class324 gag)
 {
     if (gag.GetType() == typeof(Class325))
     {
         this.method_6(btn, gag as Class325);
         return;
     }
     if (gag.NormalQuantity > 0)
     {
         this.int_0        -= gag.NormalQuantity;
         gag.NormalQuantity = 0;
     }
     btn.Selected = false;
 }
 // Token: 0x06001531 RID: 5425 RVA: 0x0002D61C File Offset: 0x0002B81C
 private void method_8(Enum32 type, out int damage, out int quantity)
 {
     GagAMatic.Class85 @class = new GagAMatic.Class85();
     @class.enum32_0 = type;
     damage          = 0;
     quantity        = 0;
     foreach (Control4.Class311 class2 in this.GagBoard.Buttons.Union(this.SosBoard.Buttons).Where(new Func <Control4.Class311, bool>(@class.method_0)))
     {
         if (class2.Overlay.GetType() == typeof(Class325))
         {
             Class325 class3 = class2.Overlay as Class325;
             damage   += class3.OrganicQuantity * class3.OrganicDamage;
             quantity += class3.OrganicQuantity;
         }
         Class324 class4 = class2.Overlay as Class324;
         damage   += class4.NormalQuantity * class4.Damage;
         quantity += class4.NormalQuantity;
     }
 }
Пример #3
0
    internal Class324 method_7()
    {
        Class324 class2 = new Class324(this.document_0);

        foreach (KeyValuePair <string, Class326> pair2 in this.method_0())
        {
            class2.method_0().Add(pair2.Key, pair2.Value.method_10());
        }
        foreach (KeyValuePair <string, Class325> pair4 in this.method_2())
        {
            class2.method_2().Add(pair4.Key, pair4.Value.method_9());
        }
        foreach (KeyValuePair <string, Class325> pair3 in this.method_1())
        {
            class2.method_1().Add(pair3.Key, pair3.Value.method_9());
        }
        foreach (KeyValuePair <string, Stream> pair in this.method_3())
        {
            class2.method_3().Add(pair.Key, pair.Value);
        }
        return(class2);
    }
        // Token: 0x0600152B RID: 5419 RVA: 0x0002CCD8 File Offset: 0x0002AED8
        private void method_3(object sender, EventArgs21 e)
        {
            switch ((Enum32)e.ButtonBoardButton.ButtonType)
            {
            case Enum32.const_1:
                if (e.ButtonBoardButton.Selected)
                {
                    if (e.MouseButton == MouseButtons.Left)
                    {
                        Class324 @class = e.ButtonBoardButton.Overlay as Class324;
                        if (@class.NormalQuantity == 0)
                        {
                            this.method_5(e.ButtonBoardButton, @class);
                            int num = this.int_0;
                            @class.NormalQuantity        = 1;
                            this.int_0                   = num + 1;
                            e.ButtonBoardButton.Selected = true;
                            this.method_1();
                            goto IL_49A;
                        }
                        this.method_5(e.ButtonBoardButton, @class);
                        goto IL_49A;
                    }
                    else
                    {
                        if (!(e.ButtonBoardButton.Overlay.GetType() == typeof(Class325)))
                        {
                            goto IL_49A;
                        }
                        Class325 class2 = e.ButtonBoardButton.Overlay as Class325;
                        if (class2.OrganicQuantity == 0)
                        {
                            this.method_6(e.ButtonBoardButton, class2);
                            int num2 = this.int_0;
                            class2.OrganicQuantity       = 1;
                            this.int_0                   = num2 + 1;
                            e.ButtonBoardButton.Selected = true;
                            this.method_1();
                            goto IL_49A;
                        }
                        this.method_6(e.ButtonBoardButton, class2);
                        goto IL_49A;
                    }
                }
                else
                {
                    foreach (Control4.Class311 class3 in this.GagBoard.Buttons.Union(this.SosBoard.Buttons))
                    {
                        if ((Enum32)class3.ButtonType == Enum32.const_1)
                        {
                            this.method_5(class3, class3.Overlay as Class324);
                        }
                    }
                }
                break;

            case Enum32.const_2:
                if (e.ButtonBoardButton.Selected)
                {
                    this.method_2(false);
                    goto IL_49A;
                }
                if (this.int_0 < 4)
                {
                    this.method_2(true);
                    goto IL_49A;
                }
                this.MaxMessage.method_0();
                goto IL_49A;
            }
            if (e.ButtonBoardButton.Selected)
            {
                if (this.int_0 < 4)
                {
                    if (e.MouseButton == MouseButtons.Left)
                    {
                        (e.ButtonBoardButton.Overlay as Class324).NormalQuantity++;
                        this.int_0++;
                    }
                    else if (e.ButtonBoardButton.Overlay.GetType() == typeof(Class325))
                    {
                        (e.ButtonBoardButton.Overlay as Class325).OrganicQuantity++;
                        this.int_0++;
                    }
                }
                else if (e.MouseButton == MouseButtons.Left)
                {
                    Class324 class4 = e.ButtonBoardButton.Overlay as Class324;
                    if (class4.NormalQuantity == 0)
                    {
                        this.MaxMessage.method_0();
                    }
                    else
                    {
                        this.int_0                  -= class4.NormalQuantity;
                        class4.NormalQuantity        = 0;
                        e.ButtonBoardButton.Selected = (class4.NormalQuantity != 0 || (class4.GetType() == typeof(Class325) && (class4 as Class325).OrganicQuantity != 0));
                    }
                }
                else if (e.ButtonBoardButton.Overlay.GetType() == typeof(Class325))
                {
                    Class325 class5 = e.ButtonBoardButton.Overlay as Class325;
                    if (class5.OrganicQuantity == 0)
                    {
                        this.MaxMessage.method_0();
                    }
                    else
                    {
                        this.int_0                  -= class5.OrganicQuantity;
                        class5.OrganicQuantity       = 0;
                        e.ButtonBoardButton.Selected = (class5.NormalQuantity != 0 || class5.OrganicQuantity != 0);
                    }
                }
            }
            else if (this.int_0 < 4)
            {
                if (e.MouseButton == MouseButtons.Left)
                {
                    (e.ButtonBoardButton.Overlay as Class324).NormalQuantity++;
                    this.int_0++;
                    e.ButtonBoardButton.Selected = true;
                    if ((Enum32)e.ButtonBoardButton.ButtonType == Enum32.const_1)
                    {
                        this.method_1();
                    }
                }
                else if (e.ButtonBoardButton.Overlay.GetType() == typeof(Class325))
                {
                    (e.ButtonBoardButton.Overlay as Class325).OrganicQuantity++;
                    this.int_0++;
                    e.ButtonBoardButton.Selected = true;
                    if ((Enum32)e.ButtonBoardButton.ButtonType == Enum32.const_1)
                    {
                        this.method_1();
                    }
                }
            }
            else
            {
                this.MaxMessage.method_0();
            }
IL_49A:
            this.method_7();
        }
 public abstract void Visit(Class324 c);
 public override void Visit(Class324 c) { }