Skip to content

Instantly share code, notes, and snippets.

View Brian1KB's full-sized avatar

Brian Kenny Brian1KB

View GitHub Profile
POST /tenants/minecraftprod/routes/android/b9b7752b-b78d-4d0b-aec3-d1e9c1ff6072 HTTP/1.1
Content-Type: application/ms-maelstrom.v3+json;type=eventbatch;charset=utf-8
User-Agent: MCPE/Android
Charset: utf-8
Content-Length: 843
Connection: Keep-Alive
Host: minecraftprod.rtep.msgamestudios.com
{"events":[{"body":{"EventName":"BlockPlaced","Measurements":{"Count":10000000},"Properties":{"AccountType":1,"ActiveSessionID":"703a587f-ed4f-4a23-92c1-e9643119e4b2","AppSessionID":"626c18aa-c4ef-416d-ae43-68d52e2e1586","AuxType":0,"Biome":5,"Block":"coral","Build":"1.4.4","BuildPlat":1,"Cheevos":true,"ClientId":"12345678901234455678891112131415","CurrentInput":2,"DeviceSessionId":"b9b7752b-b78d-4d0b-aec3-d1e9c1ff6072","Dim":0,"Mode":0,"Namespace":"minecraft","NetworkType":1,"PlacementMethod":0,"Plat":"Android 8.0.0","PlayerGameMode":0,"ToolItemType":-131,"Treatments":"mc-store-treat-2018-6-5:mc-perf-plat-12-20:mc-perf-plat-1-20:mc-perf-plat-2-20:mc-perf-plat-4-20:mc-perf-plat-7-20:mc-perf-plat-13-20","Type":-1,"UserId":
@Brian1KB
Brian1KB / AnvilProviderFactory.cs
Created July 4, 2017 20:57
This is a factory for efficiently creating anvil world providers that can be safely re-used
using System.Collections.Generic;
using MiNET;
using MiNET.Utils;
using MiNET.Worlds;
namespace Network
{
public class AnvilProviderFactory
{
private static readonly Dictionary<string, AnvilWorldProvider> ProviderCache = new Dictionary<string, AnvilWorldProvider>();
using System.Collections.Generic;
using MiNET.Utils;
using MiNET.Worlds;
namespace Network
{
public class AnvilProviderFactory
{
private static readonly Dictionary<string, AnvilWorldProvider> ProviderCache = new Dictionary<string, AnvilWorldProvider>();
using System.Collections.Generic;
using MiNET.Utils;
using MiNET.Worlds;
namespace Network
{
public class AnvilProviderFactory
{
private static readonly Dictionary<string, AnvilWorldProvider> ProviderCache = new Dictionary<string, AnvilWorldProvider>();
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_17] WARN MiNET.MiNetServer - NAK, resent datagram #807 for Rab
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_12] WARN MiNET.MiNetServer - NAK, resent datagram #811 for Rab
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_27] WARN MiNET.MiNetServer - NAK, resent datagram #817 for Rab
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_31] WARN MiNET.MiNetServer - NAK, resent datagram #823 for Rab
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_13] WARN MiNET.MiNetServer - NAK, resent datagram #827 for Rab
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_7] WARN MiNET.MiNetServer - NAK, resent datagram #825 for Rab
2017-07-01 17:41:15,996 [DedicatedThreadPool-b9e350e3-99df-4246-8907-e67d95719d9d_14] WARN MiNET.MiNetServer - NAK, resent datagram #808 for Rab
201
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Threading;
namespace MiNET.Utils
{
public class HighPrecisionTimerManager
{
private static readonly ConcurrentDictionary<Thread, List<HighPrecisionTimer>> Managers = new ConcurrentDictionary<Thread, List<HighPrecisionTimer>>();
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Threading;
namespace MiNET.Utils
{
public class HighPrecisionTimerManager
{
private static readonly ConcurrentDictionary<Thread, List<HighPrecisionTimer>> Managers = new ConcurrentDictionary<Thread, List<HighPrecisionTimer>>();
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<configSections>
<!-- Level 1 -->
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"/>
<!-- Level 2 -->
</configSections>
<startup>
2017-06-18 23:38:35,422 DEBUG MiNET.Client.MiNetClient - Block Coordinates=X=112, Y=85, Z=10, Block ID=90, Metadata=2
2017-06-18 23:38:35,422 WARN MiNET.Client.MiNetClient - > Receive: 44 (0x2c): McpeAnimate
2017-06-18 23:38:35,422 DEBUG MiNET.Client.MiNetClient - Animate: EID=4, Action ID=1
2017-06-18 23:38:35,472 WARN MiNET.Net.Package - McpeEvent: Still have 9 bytes to read!!
41 d3 ff ff ff 1f 06 01 02 00 AÓÿÿÿ.....
2017-06-18 23:38:35,478 WARN MiNET.Client.MiNetClient - > Receive: 65 (0x41): McpeEvent
2017-06-18 23:38:35,478 WARN MiNET.Client.MiNetClient - > Receive: 14 (0x0e): McpeRemoveEntity
2017-06-18 23:38:35,480 WARN MiNET.Client.MiNetClient - > Receive: 61 (0x3d): McpeChangeDimension
2017-06-18 23:38:35,484 WARN MiNET.Client.MiNetClient - > Receive: 12 (0x0c): McpeAddPlayer
@Brian1KB
Brian1KB / HighPrecisionTimer.cs
Created April 16, 2017 00:28
High Precision Timer V1
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Threading;
using log4net;
namespace MiNET.Utils
{
public class HighPrecisionTimer : IDisposable
{