I hate all this code now, but plowing forward nontheless, port to Loge