forked from LagrangeDev/Lagrange.Core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master'
- Loading branch information
Showing
53 changed files
with
1,290 additions
and
125 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
namespace Lagrange.Core.Common.Entity; | ||
|
||
[Serializable] | ||
public class BotGetGroupTodoResult | ||
{ | ||
public int Retcode { get; } | ||
|
||
public string? ResultMessage { get; } | ||
|
||
public uint GroupUin { get; } | ||
|
||
public uint Sequence { get; } | ||
|
||
public string Preview { get; } | ||
|
||
public BotGetGroupTodoResult(int retcode, string? resultMessage, uint groupUin, uint sequence, string preview) | ||
{ | ||
Retcode = retcode; | ||
ResultMessage = resultMessage; | ||
GroupUin = groupUin; | ||
Sequence = sequence; | ||
Preview = preview; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
namespace Lagrange.Core.Common.Entity; | ||
|
||
public class BotGroupReaction | ||
{ | ||
public string FaceId { get; set; } | ||
|
||
public uint Type { get; set; } | ||
|
||
public uint Count { get; set; } | ||
|
||
public bool IsAdded { get; set; } | ||
|
||
public BotGroupReaction(string faceId, uint type, uint count, bool isAdded) | ||
{ | ||
FaceId = faceId; | ||
Type = type; | ||
Count = count; | ||
IsAdded = isAdded; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
namespace Lagrange.Core.Common.Entity; | ||
|
||
[Serializable] | ||
public class SysFaceEntry | ||
{ | ||
public string QSid { get; set; } | ||
|
||
public string? QDes { get; set; } | ||
|
||
public string? EMCode { get; set; } | ||
|
||
public int? QCid { get; set; } | ||
|
||
public int? AniStickerType { get; set; } | ||
|
||
public int? AniStickerPackId { get; set; } | ||
|
||
public int? AniStickerId { get; set; } | ||
|
||
public string? Url { get; set; } | ||
|
||
public string[]? EmojiNameAlias { get; set; } | ||
|
||
public int? AniStickerWidth { get; set; } | ||
|
||
public int? AniStickerHeight { get; set; } | ||
|
||
public SysFaceEntry(string qSid, string? qDes, string? emCode, int? qCid, int? aniStickerType, | ||
int? aniStickerPackId, int? aniStickerId, string? url, string[]? emojiNameAlias, int? aniStickerWidth, | ||
int? aniStickerHeight) | ||
{ | ||
QSid = qSid; | ||
QDes = qDes; | ||
EMCode = emCode; | ||
QCid = qCid; | ||
AniStickerType = aniStickerType; | ||
AniStickerPackId = aniStickerPackId; | ||
AniStickerId = aniStickerId; | ||
Url = url; | ||
EmojiNameAlias = emojiNameAlias; | ||
AniStickerWidth = aniStickerWidth; | ||
AniStickerHeight = aniStickerHeight; | ||
} | ||
} | ||
|
||
[Serializable] | ||
public class SysFacePackEntry | ||
{ | ||
public string EmojiPackName { get; set; } | ||
|
||
public SysFaceEntry[] Emojis { get; set; } | ||
|
||
public SysFacePackEntry(string emojiPackName, SysFaceEntry[] emojis) | ||
{ | ||
EmojiPackName = emojiPackName; | ||
Emojis = emojis; | ||
} | ||
|
||
public uint[] GetUniqueSuperQSids((int AniStickerType, int AniStickerPackId)[] excludeAniStickerTypesAndPackIds) | ||
=> Emojis | ||
.Where(e => e.AniStickerType is not null | ||
&& e.AniStickerPackId is not null | ||
&& !excludeAniStickerTypesAndPackIds.Contains((e.AniStickerType.Value, e.AniStickerPackId.Value))) | ||
.Select(e => uint.Parse(e.QSid)) | ||
.Distinct() | ||
.ToArray(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
namespace Lagrange.Core.Event.EventArg; | ||
|
||
public class GroupTodoEvent : EventBase | ||
{ | ||
public uint GroupUin { get; } | ||
|
||
public uint OperatorUin { get; } | ||
|
||
public GroupTodoEvent(uint groupUin, uint operatorUin) | ||
{ | ||
GroupUin = groupUin; | ||
OperatorUin = operatorUin; | ||
|
||
EventMessage = $"{nameof(GroupPokeEvent)}: GroupUin: {GroupUin} | OperatorUin: {OperatorUin}"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.