Hallo!
Hab aus purer Langeweile einen Emulator angefangen.
Wichtige Infos:
- C#
- .NET Core 3.0
- DotNetty
- Linq2DB
- Revision: PRODUCTION-201812272209-984739530
- Plus Datenbank (lmao)
Client
Screenshots:
Konsole
Snippets:
Database/Models/User/User.cs
Code
[Table(Name = "users")]
public class User
{
[PrimaryKey, Identity]
public int ID { get; set; }
[Column(Name = "username"), NotNull]
public string Username { get; set; }
[Column(Name = "auth_ticket"), NotNull]
public string AuthTicket { get; set; }
[Column(Name = "motto")]
public string Motto { get; set; }
[Column(Name = "rank"), NotNull]
public int Rank { get; set; }
[Column(Name = "look"), NotNull]
public string Look { get; set; }
[Column(Name = "gender"), NotNull]
public string Gender { get; set; }
[Column(Name = "home_room"), NotNull]
public int HomeRoom { get; set; }
[Column(Name = "credits"), NotNull]
public int Credits { get; set; }
[Column(Name = "activity_points"), NotNull]
public int Duckets { get; set; }
[Column(Name = "vip_points"), NotNull]
public int Diamonds { get; set; }
[Column(Name = "gotw_points"), NotNull]
public int GOTWPoints { get; set; }
Alles anzeigen
Spoiler anzeigen
Code
class MessageEncoder : MessageToMessageEncoder<Composer>
{
private static readonly ILog log = LogManager.GetLogger(typeof(MessageEncoder));
protected override void Encode(IChannelHandlerContext context, Composer packet, List<object> output)
{
ComposerMessage composer = new ComposerMessage(packet.GetHeader());
packet.Compose(composer);
if (!composer.HasLength())
{
composer.Buffer.SetInt(0, composer.Buffer.WriterIndex - 4);
}
log.Debug($"Composer [{packet.GetHeader()}] wurde abgeschickt");
output.Add(composer.Buffer);
}
}
Alles anzeigen
Im allgemeinen würde ich behaupten, dass es einfach eine "verbessere" Plus Version sein wird. GitHub Repository existiert, aber privat.
Vielleicht kommen ja irgendwann wieder mal paar Updates. :))
mfg.
necmi