Artifact Logic, Tests, Etc

This is still a WIP but can probably be merged into development if you guys think it looks decent.