Turned a lot of defines into ints.