Skip to content

Instantly share code, notes, and snippets.

View airbreather's full-sized avatar
💭
Wondering why there's a "Set status" button.

Joe Amenta airbreather

💭
Wondering why there's a "Set status" button.
  • Urban Science Applications, Inc.
  • Sterling Heights, Michigan, USA
View GitHub Profile
[15:01:19] [Server thread/ERROR] [FML/]: Caught exception from HardcoreQuesting
java.lang.NoClassDefFoundError: org/lwjgl/input/Keyboard
at hardcorequesting.client.KeyboardHandler.toConfig(KeyboardHandler.java:73) ~[KeyboardHandler.class:?]
at hardcorequesting.client.KeyboardHandler.getDefault(KeyboardHandler.java:94) ~[KeyboardHandler.class:?]
at hardcorequesting.config.ConfigHandler.<clinit>(ConfigHandler.java:41) ~[ConfigHandler.class:?]
at hardcorequesting.HardcoreQuesting.preInit(HardcoreQuesting.java:48) ~[HardcoreQuesting.class:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_66]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_66]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66]
at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66]
@airbreather
airbreather / HeapSlaveProgram.cs
Last active January 9, 2016 18:59
A Console application that uses CLR MD to identify the indices of elements in a particular cache that would be eligible for garbage collection if the underlying cache were to only remove the element at that index.
using System;
using System.Collections;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using Microsoft.Diagnostics.Runtime;
namespace HeapSlave
{
@airbreather
airbreather / TestingGround.cs
Created January 16, 2016 15:12
Testing ground for union optimization.
using System;
using System.Diagnostics;
using System.IO;
using System.Linq;
using GeoAPI.Geometries;
using NetTopologySuite;
using NetTopologySuite.IO;
using NetTopologySuite.Operation.Union;
namespace TestingGround
@airbreather
airbreather / SuperCoordSeq.cs
Created January 16, 2016 15:14
My coord sequence... uses stuff from https://github.com/airbreather/AirBreather.Common and I don't feel like taking it out for this
using System;
using AirBreather.Common.Utilities;
using GeoAPI.Geometries;
namespace TestingGround
{
internal struct CoordVal : IEquatable<CoordVal>
{
internal double X;
internal double Y;
//******************************
// Written by Peter Golde
// Copyright (c) 2004-2005, Wintellect
//
// Use and restribution of this code is subject to the license agreement
// contained in the file "License.txt" accompanying this file.
//******************************
#region Using directives
@airbreather
airbreather / 32025538-measure.cs
Last active February 28, 2016 20:20
Measurements for SO answer with ID 32025538
// comment this out to see how comparatively expensive it is if all you have are properties.
#define FIELDS
using System;
using System.Diagnostics;
namespace ConsoleApplication1
{
struct Point
{
<?xml version="1.0" encoding="utf-8"?>
<Modpack Name="STEP" Variant="Core" Version="2.2.9.2">
<Files>
<!-- TODO: Cleaned MD5s are outdated. Check this against a re-run of the cleaning process:
http://afkmods.iguanadons.net/index.php?/topic/4110-manual-cleaning-skyrim-master-files
and update accordingly if it's correct. -->
<Group Name="1.C. Install Utilities">
<File Name="Mod Organizer 1.3.1.1"
CanonicalFileName="Mod Organizer v1_3_11-1334-1-3-11.7z"
MD5Checksum="215ccbbca78af9cd3f833dd2efb81759"
using CommandLine;
using CommandLine.Text;
namespace StepperUpper
{
internal sealed class Options
{
// input file
[Option('p', "packDefinitionFile", Required = true, HelpText = "The .xml file that defines a pack.")]
public string PackDefinitionFilePath { get; set; }
using System;
using System.Collections.Generic;
using System.Linq;
namespace ConsoleApplication1
{
internal static class Program
{
private static void Main()
{
using System.Collections.Concurrent;
using System.IO.MemoryMappedFiles;
using BlockingCollection<string> coll = new();
var threads = new Thread[100];
foreach (ref var thread in threads.AsSpan())
{
thread = new Thread(RunThread) { IsBackground = true };
thread.Start(coll);