Exemple #1
0
 private void load(LovewingColours colours)
 {
     if (accentColour == default(Color4))
     {
         AccentColour = colours.White;
     }
 }
Exemple #2
0
 private void load(AudioManager audio, LovewingColours colours)
 {
     SelectionBox.Colour = colours.Magenta;
     Box.Colour          = colours.LightMagenta;
     this.audio          = audio;
     text.Colour         = colours.Magenta;
 }
Exemple #3
0
 private void load(LovewingColours colours)
 {
     AddRangeInternal(new Drawable[]
     {
         new IconButton
         {
             Icon   = FontAwesome.fa_server,
             Colour = colours.Magenta,
             Size   = new Vector2(20),
             Anchor = Anchor.TopLeft,
             Origin = Anchor.TopLeft,
             Margin = new MarginPadding
             {
                 Top  = 40,
                 Left = 90
             }
         },
         new LovewingSearchBox
         {
             CommitColour      = colours.LightMagenta,
             UnfocusedColour   = colours.White,
             FocusedColour     = colours.LightMagenta,
             PlaceholderColour = colours.Magenta,
             TextColour        = colours.Magenta,
             Margin            = new MarginPadding {
                 Top = 25
             },
             Anchor          = Anchor.TopCentre,
             Origin          = Anchor.TopCentre,
             Size            = new Vector2(200, 50),
             Colour          = colours.White,
             BorderColour    = colours.Magenta,
             BorderThickness = 5
         },
         new Box
         {
             RelativeSizeAxes = Axes.Both,
             Colour           = colours.White,
             Anchor           = Anchor.Centre,
             Origin           = Anchor.Centre,
             Depth            = 5
         }
     });
 }
Exemple #4
0
 private void load(LovewingColours colours)
 {
     wedgeColour  = colours.Magenta;
     buttonColour = colours.LightMagenta;
 }
 private void load(LovewingColours colours)
 {
     wedgeColour  = colours.LightYellow;
     buttonColour = colours.Yellow;
 }
Exemple #6
0
 private void load(LovewingColours colours) => BorderColour = colours.Magenta;
Exemple #7
0
 private void load(LovewingColours colours)
 {
     wedgeColour  = colours.DarkBlue;
     buttonColour = colours.Blue;
 }
Exemple #8
0
        private void load(TextureStore texStore, LovewingColours colours, UserData user)
        {
            Padding = new MarginPadding {
                Right = 75, Top = 5
            };
            Spacing = new Vector2(75, 0);

            Children = new Drawable[]
            {
                new IconButton
                {
                    Icon   = FontAwesome.fa_ellipsis_v,
                    Action = ButtonAction,
                    Margin = new MarginPadding {
                        Top = 17.5f
                    },
                    Size   = new Vector2(15, 55),
                    Origin = Anchor.TopRight,
                    Anchor = Anchor.TopRight,
                    Colour = Color4.White
                },
                new CircularContainer
                {
                    Anchor           = Anchor.TopRight,
                    Origin           = Anchor.TopRight,
                    RelativeSizeAxes = Axes.Both,
                    FillMode         = FillMode.Fit,
                    Colour           = Color4.White,
                    Masking          = true,
                    BorderColour     = new Color4(85, 85, 85, 255),
                    BorderThickness  = 10,
                    Children         = new Drawable[]
                    {
                        new Sprite
                        {
                            Anchor           = Anchor.Centre,
                            Origin           = Anchor.Centre,
                            RelativeSizeAxes = Axes.Both,
                            FillMode         = FillMode.Fit,
                            Texture          = texStore.Get(user.Avatar)
                        }
                    }
                },
                new FillFlowContainer
                {
                    RelativeSizeAxes = Axes.Y,
                    AutoSizeAxes     = Axes.X,
                    Height           = 0.4f,
                    Anchor           = Anchor.CentreRight,
                    Origin           = Anchor.CentreRight,
                    Direction        = FillDirection.Horizontal,
                    Spacing          = new Vector2(10, 0),
                    Children         = new Drawable[]
                    {
                        new IconButton
                        {
                            Anchor = Anchor.CentreRight,
                            Origin = Anchor.BottomRight,
                            Size   = new Vector2(20),
                            Colour = Color4.LightGreen,
                            Icon   = FontAwesome.fa_plus
                        },
                        new SpriteText
                        {
                            Anchor   = Anchor.TopRight,
                            Origin   = Anchor.TopRight,
                            Text     = user.Loveca.ToString(),
                            TextSize = 40
                        },
                        new CircularContainer
                        {
                            Anchor           = Anchor.BottomRight,
                            Origin           = Anchor.BottomRight,
                            RelativeSizeAxes = Axes.Both,
                            FillMode         = FillMode.Fit,
                            BorderColour     = colours.Magenta,
                            BorderThickness  = 6,
                            Masking          = true,
                            Children         = new Drawable[]
                            {
                                new Box
                                {
                                    RelativeSizeAxes = Axes.Both,
                                    Colour           = Color4.Transparent
                                },
                                new SpriteIcon
                                {
                                    Anchor           = Anchor.Centre,
                                    Origin           = Anchor.Centre,
                                    Colour           = colours.Magenta,
                                    RelativeSizeAxes = Axes.Both,
                                    Size             = new Vector2(0.5f),
                                    Icon             = FontAwesome.fa_heart
                                }
                            }
                        }
                    }
                },
                new FillFlowContainer
                {
                    RelativeSizeAxes = Axes.Y,
                    AutoSizeAxes     = Axes.X,
                    Height           = 0.4f,
                    Anchor           = Anchor.CentreRight,
                    Origin           = Anchor.CentreRight,
                    Direction        = FillDirection.Horizontal,
                    Spacing          = new Vector2(10, 0),
                    Children         = new Drawable[]
                    {
                        new IconButton
                        {
                            Anchor = Anchor.CentreRight,
                            Origin = Anchor.BottomRight,
                            Size   = new Vector2(20),
                            Colour = Color4.LightGreen,
                            Icon   = FontAwesome.fa_plus
                        },
                        new SpriteText
                        {
                            Anchor   = Anchor.TopRight,
                            Origin   = Anchor.TopRight,
                            Text     = user.Coins.ToString(),
                            TextSize = 40
                        },
                        new CircularContainer
                        {
                            Anchor           = Anchor.BottomRight,
                            Origin           = Anchor.BottomRight,
                            RelativeSizeAxes = Axes.Both,
                            FillMode         = FillMode.Fit,
                            BorderColour     = colours.Yellow,
                            BorderThickness  = 6,
                            Masking          = true,
                            Children         = new Drawable[]
                            {
                                new Box
                                {
                                    RelativeSizeAxes = Axes.Both,
                                    Colour           = Color4.Transparent
                                },
                                new SpriteIcon
                                {
                                    Anchor           = Anchor.Centre,
                                    Origin           = Anchor.Centre,
                                    Colour           = colours.Yellow,
                                    RelativeSizeAxes = Axes.Both,
                                    Size             = new Vector2(0.5f),
                                    Icon             = FontAwesome.fa_star
                                }
                            }
                        }
                    }
                }
            };
        }
Exemple #9
0
        private void load(LovewingColours colours, UserData user, TextureStore texStore)
        {
            FillFlowContainer badges;

            AddRange(new Drawable[]
            {
                new Box
                {
                    Colour           = colours.White,
                    RelativeSizeAxes = Axes.Both
                },
                main = new Container
                {
                    Anchor           = Anchor.Centre,
                    Origin           = Anchor.Centre,
                    RelativeSizeAxes = Axes.Both,
                    Children         = new Drawable[]
                    {
                        new BufferedContainer
                        {
                            Height           = 250,
                            RelativeSizeAxes = Axes.X,
                            BlurSigma        = Vector2.One,
                            Anchor           = Anchor.TopCentre,
                            Origin           = Anchor.TopCentre,
                            Children         = new Drawable[]
                            {
                                new Sprite
                                {
                                    Anchor           = Anchor.TopCentre,
                                    Origin           = Anchor.TopCentre,
                                    RelativeSizeAxes = Axes.Both,
                                    FillMode         = FillMode.Fill,
                                    Scale            = new Vector2(1.5f),
                                    Margin           = new MarginPadding
                                    {
                                        Right = 150,
                                        Top   = -20
                                    },
                                    Texture = texStore.Get(user.UserBackground)
                                },
                                new Box
                                {
                                    Anchor           = Anchor.TopCentre,
                                    Origin           = Anchor.TopCentre,
                                    RelativeSizeAxes = Axes.Both,
                                    Colour           = Color4.Black.Opacity(0.5f)
                                }
                            }
                        },
                        new SpriteText
                        {
                            Margin = new MarginPadding
                            {
                                Top = 150
                            },
                            Font     = @"Noto Sans CJK Regular",
                            TextSize = 40,
                            Anchor   = Anchor.TopCentre,
                            Origin   = Anchor.TopCentre,
                            Text     = user.Username
                        },
                        new Box
                        {
                            Margin = new MarginPadding
                            {
                                Top = 250
                            },
                            Height           = 40,
                            RelativeSizeAxes = Axes.X,
                            Colour           = new Color4(225, 167, 42, 255)
                        },
                        new CircularContainer
                        {
                            Height = 125,
                            Width  = 125,
                            Anchor = Anchor.TopCentre,
                            Origin = Anchor.TopCentre,
                            Margin = new MarginPadding
                            {
                                Top = 200
                            },
                            FillMode        = FillMode.Fit,
                            Colour          = Color4.White,
                            Masking         = true,
                            BorderColour    = new Color4(85, 85, 85, 255),
                            BorderThickness = 15,
                            Children        = new Drawable[]
                            {
                                new Sprite
                                {
                                    Anchor           = Anchor.Centre,
                                    Origin           = Anchor.Centre,
                                    RelativeSizeAxes = Axes.Both,
                                    FillMode         = FillMode.Fit,
                                    Texture          = texStore.Get(user.Avatar)
                                }
                            }
                        },
                        badges = new FillFlowContainer
                        {
                            Padding          = new MarginPadding(15),
                            Spacing          = new Vector2(2),
                            Anchor           = Anchor.TopCentre,
                            Origin           = Anchor.TopCentre,
                            RelativeSizeAxes = Axes.X,
                            Height           = 50
                        },
                        new Container
                        {
                            Anchor       = Anchor.TopCentre,
                            Origin       = Anchor.TopCentre,
                            Width        = 25 + 5 * user.Level.ToString().Length,
                            Height       = 30,
                            CornerRadius = 5,
                            Masking      = true,
                            Margin       = new MarginPadding
                            {
                                Top = 300
                            },
                            Children = new Drawable[]
                            {
                                new Circle
                                {
                                    Colour           = colours.Blue,
                                    Anchor           = Anchor.Centre,
                                    Origin           = Anchor.Centre,
                                    RelativeSizeAxes = Axes.Both
                                },
                                new SpriteText
                                {
                                    Font     = @"Muli Light",
                                    Anchor   = Anchor.Centre,
                                    Origin   = Anchor.Centre,
                                    TextSize = 30,
                                    Text     = user.Level.ToString()
                                }
                            }
                        },
                        new ScrollContainer
                        {
                            Anchor           = Anchor.TopCentre,
                            Origin           = Anchor.TopCentre,
                            RelativeSizeAxes = Axes.Both,
                            Margin           = new MarginPadding
                            {
                                Top = 350
                            },
                            Children = new Drawable[]
                            {
                                new FillFlowContainer
                                {
                                    Spacing          = new Vector2(10),
                                    Anchor           = Anchor.TopCentre,
                                    Origin           = Anchor.TopCentre,
                                    RelativeSizeAxes = Axes.Both,
                                    Direction        = FillDirection.Vertical,
                                    Margin           = new MarginPadding
                                    {
                                        Top = 150
                                    },
                                    Children = new Drawable[]
                                    {
                                        new LovewingSmallButton
                                        {
                                            Anchor       = Anchor.Centre,
                                            Origin       = Anchor.Centre,
                                            ButtonColour = colours.LightMagenta,
                                            ShadowColour = colours.Magenta,
                                            CornerRadius = 7,
                                            Size         = new Vector2(250, 50),
                                            Text         = "Friends",
                                            Icon         = FontAwesome.fa_users
                                        },
                                        new LovewingSmallButton
                                        {
                                            Anchor       = Anchor.Centre,
                                            Origin       = Anchor.Centre,
                                            ButtonColour = colours.LightMagenta,
                                            ShadowColour = colours.Magenta,
                                            CornerRadius = 7,
                                            Size         = new Vector2(250, 50),
                                            Text         = "Profile",
                                            Icon         = FontAwesome.fa_user
                                        },
                                        new LovewingSmallButton
                                        {
                                            Anchor       = Anchor.Centre,
                                            Origin       = Anchor.Centre,
                                            ButtonColour = colours.LightMagenta,
                                            ShadowColour = colours.Magenta,
                                            CornerRadius = 7,
                                            Size         = new Vector2(250, 50),
                                            Text         = "Events",
                                            Icon         = FontAwesome.fa_clock_o
                                        },
                                        new LovewingSmallButton
                                        {
                                            Anchor       = Anchor.Centre,
                                            Origin       = Anchor.Centre,
                                            ButtonColour = colours.LightMagenta,
                                            ShadowColour = colours.Magenta,
                                            CornerRadius = 7,
                                            Size         = new Vector2(250, 50),
                                            Text         = "Shoutout!",
                                            Icon         = FontAwesome.fa_bullhorn
                                        },
                                        new LovewingSmallButton
                                        {
                                            Anchor       = Anchor.Centre,
                                            Origin       = Anchor.Centre,
                                            ButtonColour = colours.LightMagenta,
                                            ShadowColour = colours.Magenta,
                                            CornerRadius = 7,
                                            Size         = new Vector2(250, 50),
                                            Text         = "Settings",
                                            Icon         = FontAwesome.fa_wrench,
                                            Action       = toSettings
                                        }
                                    }
                                }

                                /*new FillFlowContainer
                                 * {
                                 *  Anchor = Anchor.BottomCentre,
                                 *  Origin = Anchor.BottomCentre,
                                 *  Direction = FillDirection.Vertical,
                                 *  Children = new Drawable[]
                                 *  {
                                 *      new LovewingHollowButton
                                 *      {
                                 *          Anchor = Anchor.Centre,
                                 *          Origin = Anchor.Centre,
                                 *          BackgroundColour = colours.White,
                                 *          BorderColour = colours.Magenta,
                                 *          TextColour = colours.Magenta,
                                 *          IconColour = colours.Magenta,
                                 *          BorderThickness = 3,
                                 *          CornerRadius = 7,
                                 *          Size = new Vector2(250, 50),
                                 *          Text = "Home",
                                 *          Icon = FontAwesome.fa_home,
                                 *      }
                                 *  }
                                 * }*/
                            }
                        }
                    }
                },
                settings = new Container
                {
                    Anchor           = Anchor.Centre,
                    Origin           = Anchor.Centre,
                    RelativeSizeAxes = Axes.Both,
                    Children         = new Drawable[]
                    {
                        new Container
                        {
                            Anchor           = Anchor.TopCentre,
                            Origin           = Anchor.TopCentre,
                            RelativeSizeAxes = Axes.X,
                            Height           = 100,
                            Children         = new Drawable[]
                            {
                                new IconButton
                                {
                                    Margin = new MarginPadding
                                    {
                                        Left = 10
                                    },
                                    Icon   = FontAwesome.fa_chevron_left,
                                    Size   = new Vector2(20),
                                    Anchor = Anchor.CentreLeft,
                                    Origin = Anchor.CentreLeft,
                                    Action = toMain,
                                    Colour = colours.Magenta
                                },
                                new SpriteText
                                {
                                    Font     = "Noto Sans CJK JP Regular",
                                    Text     = "Settings",
                                    Colour   = colours.Magenta,
                                    Anchor   = Anchor.Centre,
                                    Origin   = Anchor.Centre,
                                    TextSize = 20
                                },
                                new ScrollContainer
                                {
                                    Anchor           = Anchor.TopCentre,
                                    Origin           = Anchor.TopCentre,
                                    RelativeSizeAxes = Axes.Both,
                                    Margin           = new MarginPadding
                                    {
                                        Top = 100
                                    },
                                    Children = new Drawable[]
                                    {
                                        new FillFlowContainer
                                        {
                                            Spacing          = new Vector2(10),
                                            Anchor           = Anchor.TopCentre,
                                            Origin           = Anchor.TopCentre,
                                            RelativeSizeAxes = Axes.Both,
                                            Direction        = FillDirection.Vertical,
                                            Margin           = new MarginPadding
                                            {
                                                Top = 50
                                            },
                                            Children = new Drawable[]
                                            {
                                                new VolumeSlider
                                                {
                                                    Anchor = Anchor.Centre,
                                                    Origin = Anchor.Centre,
                                                    Size   = new Vector2(200, 50)
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            });

            settings.MoveToX(Width);

            user.Badges.Add(new Online.User.Badge());

            foreach (var badge in user.Badges)
            {
                badges.Add(new CircularContainer
                {
                    Anchor          = Anchor.TopCentre,
                    Origin          = Anchor.TopCentre,
                    FillMode        = FillMode.Fit,
                    BorderColour    = badge.Colour,
                    BorderThickness = 6,
                    Masking         = true,
                    Height          = 40,
                    Width           = 40,
                    Children        = new Drawable[]
                    {
                        new Box
                        {
                            RelativeSizeAxes = Axes.Both,
                            Colour           = Color4.Transparent
                        },
                        new SpriteIcon
                        {
                            Anchor           = Anchor.Centre,
                            Origin           = Anchor.Centre,
                            Colour           = badge.Colour,
                            RelativeSizeAxes = Axes.Both,
                            Scale            = new Vector2(0.5f),
                            Icon             = badge.Icon
                        }
                    }
                });
            }
        }