removed unused usings, no functional change

This commit is contained in:
Toastie (DCS Team) 2024-08-06 22:33:22 +12:00
parent d428fc5532
commit fe7445eefb
Signed by: toastie_t0ast
GPG key ID: 27F3B6855AFD40A4
112 changed files with 77 additions and 205 deletions

View file

@ -1,5 +1,4 @@
using Discord;
using EllieBot;
namespace EllieBot.Marmalade;

View file

@ -1,6 +1,4 @@
#nullable disable
using System.ComponentModel.DataAnnotations.Schema;
namespace EllieBot.Db.Models;

View file

@ -1,6 +1,5 @@
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Migrations;
using EllieBot.Db.Models;
namespace EllieBot.Migrations;

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
namespace EllieBot.Migrations
{

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
namespace EllieBot.Migrations
{

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
namespace EllieBot.Migrations
{

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
namespace EllieBot.Migrations
{

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
namespace EllieBot.Migrations
{

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Administration._common.results;

View file

@ -4,7 +4,6 @@ using System.Net;
using System.Threading.Channels;
using LinqToDB;
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
namespace EllieBot.Modules.Administration.Services;

View file

@ -1,6 +1,4 @@
#nullable disable
using EllieBot.Db;
namespace EllieBot.Modules.Administration.Services;
public class GameVoiceChannelService : IEService

View file

@ -1,5 +1,4 @@
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
using System.Threading.Channels;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Administration.Services;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
using System.Threading.Channels;

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Modules.Patronage;
using EllieBot.Db.Models;
using OneOf;
using OneOf.Types;

View file

@ -2,7 +2,6 @@
using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Modules.Patronage;
using EllieBot.Db.Models;
using OneOf.Types;

View file

@ -3,7 +3,6 @@ using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using EllieBot.Db.Models;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
namespace EllieBot.Modules.Administration;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Administration.Services;

View file

@ -1,7 +1,6 @@
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Caching.Memory;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Modules.Administration.Services;
using EllieBot.Db.Models;

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Common.ModuleBehaviors;

View file

@ -4,7 +4,6 @@ using LinqToDB.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Common.TypeReaders.Models;
using EllieBot.Db;
using EllieBot.Modules.Permissions.Services;
using EllieBot.Db.Models;
using Newtonsoft.Json;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Administration.Services;

View file

@ -2,7 +2,6 @@
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Common.Yml;
using EllieBot.Db;
using EllieBot.Db.Models;
using System.Runtime.CompilerServices;
using LinqToDB.EntityFrameworkCore;

View file

@ -3,7 +3,6 @@ using EllieBot.Common.TypeReaders;
using EllieBot.Modules.Gambling.Common;
using EllieBot.Modules.Gambling.Common.Blackjack;
using EllieBot.Modules.Gambling.Services;
using EllieBot.Modules.Utility;
namespace EllieBot.Modules.Gambling;

View file

@ -13,7 +13,6 @@ using System.Text;
using EllieBot.Modules.Gambling.Rps;
using EllieBot.Common.TypeReaders;
using EllieBot.Modules.Patronage;
using EllieBot.Modules.Utility;
namespace EllieBot.Modules.Gambling;

View file

@ -2,7 +2,6 @@
using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Gambling.Common;
using EllieBot.Modules.Gambling.Common.Connect4;

View file

@ -1,7 +1,6 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
using SixLabors.Fonts;
using SixLabors.ImageSharp;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Modules.Gambling.Common;
using EllieBot.Modules.Gambling.Services;
using EllieBot.Db.Models;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Gambling.Services;

View file

@ -7,9 +7,7 @@ using SixLabors.ImageSharp;
using SixLabors.ImageSharp.Drawing.Processing;
using SixLabors.ImageSharp.PixelFormats;
using SixLabors.ImageSharp.Processing;
using EllieBot.Modules.Gambling;
using EllieBot.Common.TypeReaders;
using EllieBot.Modules.Utility;
using Color = SixLabors.ImageSharp.Color;
using Image = SixLabors.ImageSharp.Image;

View file

@ -3,7 +3,6 @@ using EllieBot.Modules.Gambling.Common;
using EllieBot.Modules.Gambling.Common.Waifu;
using EllieBot.Modules.Gambling.Services;
using EllieBot.Db.Models;
using TwitchLib.Api.Helix.Models.Teams;
namespace EllieBot.Modules.Gambling;

View file

@ -3,11 +3,9 @@ using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Gambling.Common;
using EllieBot.Modules.Gambling.Common.Waifu;
using SixLabors.ImageSharp;
namespace EllieBot.Modules.Gambling.Services;

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Modules.Gambling;
using EllieBot.Modules.Gambling.Betdraw;
using EllieBot.Modules.Gambling.Rps;
using OneOf;

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Modules.Gambling;
using EllieBot.Modules.Gambling.Betdraw;
using EllieBot.Modules.Gambling.Rps;
using EllieBot.Modules.Gambling.Services;

View file

@ -1,5 +1,4 @@
using System.Text.RegularExpressions;
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Gambling.Services;
using NCalc;

View file

@ -1,7 +1,5 @@
#nullable disable
using EllieBot.Db;
using EllieBot.Modules.Games.Services;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Games;

View file

@ -1,6 +1,4 @@
#nullable disable
using System.CodeDom;
namespace EllieBot.Modules.Games.Common.ChatterBot;
public sealed class ThinkResult

View file

@ -1,7 +1,6 @@
#nullable disable
using EllieBot.Modules.Music.Services;
using EllieBot.Db.Models;
using EllieBot.Modules.Utility;
namespace EllieBot.Modules.Music;

View file

@ -1,6 +1,5 @@
#nullable disable
using LinqToDB;
using EllieBot.Db;
using EllieBot.Modules.Music.Services;
using EllieBot.Db.Models;

View file

@ -1,5 +1,4 @@
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Db.Models;
using System.Diagnostics.CodeAnalysis;
namespace EllieBot.Modules.Music.Services;

View file

@ -2,8 +2,6 @@
using LinqToDB.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db.Models;
using StackExchange.Redis;
using System.Diagnostics;
namespace EllieBot.Modules.Patronage;

View file

@ -1,6 +1,5 @@
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
namespace EllieBot.Modules.Permissions.Services;

View file

@ -1,7 +1,6 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.TypeReaders;
using EllieBot.Db;
using EllieBot.Modules.Permissions.Services;
using EllieBot.Db.Models;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Modules.Permissions.Services;
using EllieBot.Db.Models;

View file

@ -1,7 +1,6 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Permissions.Services;

View file

@ -1,7 +1,6 @@
#nullable disable
using EllieBot.Common.TypeReaders;
using EllieBot.Common.TypeReaders.Models;
using EllieBot.Db;
using EllieBot.Modules.Permissions.Common;
using EllieBot.Modules.Permissions.Services;
using EllieBot.Db.Models;

View file

@ -1,7 +1,6 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Modules.Permissions.Common;
using EllieBot.Db.Models;

View file

@ -4,13 +4,11 @@ using SixLabors.ImageSharp;
using SixLabors.ImageSharp.Drawing.Processing;
using SixLabors.ImageSharp.PixelFormats;
using SixLabors.ImageSharp.Processing;
using System.Collections.ObjectModel;
using System.Globalization;
using System.Net.Http.Json;
using System.Text.Json.Serialization;
using System.Xml;
using Color = SixLabors.ImageSharp.Color;
using StringExtensions = EllieBot.Extensions.StringExtensions;
namespace EllieBot.Modules.Searches.Services;

View file

@ -1,7 +1,6 @@
using AngleSharp;
using CsvHelper;
using CsvHelper.Configuration;
using System.Diagnostics;
using System.Globalization;
using System.Text.Json;

View file

@ -4,7 +4,6 @@ using CodeHollow.FeedReader.Feeds;
using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Searches.Services;

View file

@ -1,5 +1,4 @@
using EllieBot.Modules.Searches.Common;
using OneOf;
using OneOf;
using OneOf.Types;
using System.Net;
using System.Net.Http.Json;

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Searches.Services;

View file

@ -1,7 +1,6 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Searches.Common;
using EllieBot.Modules.Searches.Common.StreamNotifications;

View file

@ -1,6 +1,4 @@
using EllieBot.Modules.Administration;
namespace EllieBot.Modules.Utility;
namespace EllieBot.Modules.Utility;
public partial class UtilityCommands
{

View file

@ -1,6 +1,5 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Modules.Utility.Services;
using EllieBot.Db.Models;

View file

@ -1,7 +1,6 @@
#nullable disable
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Utility.Services;

View file

@ -2,7 +2,6 @@
using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using EllieBot.Common.Yml;
using EllieBot.Db;
using EllieBot.Db.Models;
using YamlDotNet.Serialization;
using YamlDotNet.Serialization.NamingConventions;

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Db;
using EllieBot.Modules.Utility.Services;
using EllieBot.Db.Models;

View file

@ -1,5 +1,4 @@
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Modules.Utility.Common;
using EllieBot.Modules.Utility.Common.Exceptions;
using EllieBot.Db.Models;

View file

@ -1,4 +1,3 @@
using LinqToDB.Reflection;
using EllieBot.Modules.Utility.Services;
using Newtonsoft.Json;
using System.Diagnostics;
@ -7,7 +6,6 @@ using System.Text.Json;
using System.Text.Json.Serialization;
using Microsoft.CodeAnalysis.CSharp.Scripting;
using Microsoft.CodeAnalysis.Scripting;
using EllieBot.Modules.Games.Hangman;
using EllieBot.Modules.Searches.Common;
namespace EllieBot.Modules.Utility;

View file

@ -1,6 +1,4 @@
#nullable disable
using EllieBot.Db;
namespace EllieBot.Modules.Utility.Services;
public class VerboseErrorsService : IEService

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Db;
using EllieBot.Db.Models;
using EllieBot.Modules.Xp.Services;

View file

@ -2,7 +2,6 @@
using LinqToDB;
using LinqToDB.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using EllieBot.Db;
using EllieBot.Db.Models;
using OneOf;

View file

@ -2,7 +2,6 @@
using EllieBot.Modules.Xp.Services;
using EllieBot.Db.Models;
using EllieBot.Modules.Patronage;
using EllieBot.Modules.Utility;
namespace EllieBot.Modules.Xp;

View file

@ -2,7 +2,6 @@
using LinqToDB;
using Microsoft.EntityFrameworkCore;
using EllieBot.Common.ModuleBehaviors;
using EllieBot.Db;
using EllieBot.Db.Models;
using Newtonsoft.Json;
using SixLabors.Fonts;
@ -191,9 +190,9 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
var items = await ctx.Set<DiscordUser>()
.Where(x => group.Contains(x.UserId))
.UpdateWithOutputAsync(old => new()
{
TotalXp = old.TotalXp + group.Key
},
{
TotalXp = old.TotalXp + group.Key
},
(_, n) => n);
await ctx.Set<ClubInfo>()
@ -216,9 +215,9 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
.Where(x => x.GuildId == guildId)
.Where(x => group.Contains(x.UserId))
.UpdateWithOutputAsync(old => new()
{
Xp = old.Xp + group.Key
},
{
Xp = old.Xp + group.Key
},
(_, n) => n);
gxps.AddRange(items);
@ -230,14 +229,14 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
.Set<UserXpStats>()
.ToLinqToDBTable()
.InsertOrUpdateAsync(() => new UserXpStats()
{
UserId = userId,
GuildId = guildId,
Xp = group.Key,
DateAdded = DateTime.UtcNow,
AwardedXp = 0,
NotifyOnLevelUp = XpNotificationLocation.None
},
{
UserId = userId,
GuildId = guildId,
Xp = group.Key,
DateAdded = DateTime.UtcNow,
AwardedXp = 0,
NotifyOnLevelUp = XpNotificationLocation.None
},
_ => new()
{
},
@ -1010,12 +1009,12 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
img.Mutate(x =>
{
x.DrawText(new TextOptions(usernameFont)
{
HorizontalAlignment = HorizontalAlignment.Left,
VerticalAlignment = VerticalAlignment.Center,
FallbackFontFamilies = _fonts.FallBackFonts,
Origin = new(template.User.Name.Pos.X, template.User.Name.Pos.Y + 8)
},
{
HorizontalAlignment = HorizontalAlignment.Left,
VerticalAlignment = VerticalAlignment.Center,
FallbackFontFamilies = _fonts.FallBackFonts,
Origin = new(template.User.Name.Pos.X, template.User.Name.Pos.Y + 8)
},
"@" + username,
Brushes.Solid(template.User.Name.Color),
outlinePen);
@ -1031,12 +1030,12 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
var clubFont = _fonts.NotoSans.CreateFont(template.Club.Name.FontSize, FontStyle.Regular);
img.Mutate(x => x.DrawText(new TextOptions(clubFont)
{
HorizontalAlignment = HorizontalAlignment.Right,
VerticalAlignment = VerticalAlignment.Top,
FallbackFontFamilies = _fonts.FallBackFonts,
Origin = new(template.Club.Name.Pos.X + 50, template.Club.Name.Pos.Y - 8)
},
{
HorizontalAlignment = HorizontalAlignment.Right,
VerticalAlignment = VerticalAlignment.Top,
FallbackFontFamilies = _fonts.FallBackFonts,
Origin = new(template.Club.Name.Pos.X + 50, template.Club.Name.Pos.Y - 8)
},
clubName,
Brushes.Solid(template.Club.Name.Color),
outlinePen));
@ -1248,9 +1247,9 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
if (template.Club.Icon.Show)
await DrawClubImage(img, stats);
// #if GLOBAL_ELLIE
// #if GLOBAL_ELLIE
await DrawFrame(img, stats.User.UserId);
// #endif
// #endif
var outputSize = template.OutputSize;
if (outputSize.X != img.Width || outputSize.Y != img.Height)
@ -1307,7 +1306,7 @@ public class XpService : IEService, IReadyExecutor, IExecNoCommand
if (frame is not null)
img.Mutate(x => x.DrawImage(frame, new Point(0, 0), new GraphicsOptions()));
}
// #endif
// #endif
private void DrawXpBar(float percent, XpBar info, Image<Rgba32> img)
{

View file

@ -1,5 +1,4 @@
#nullable disable
using EllieBot.Db;
using EllieBot.Db.Models;
namespace EllieBot.Modules.Xp;

Some files were not shown because too many files have changed in this diff Show more