CODE OVERHAUL!!!