Compiler issues on iOS 6

There were compiler warnings on iOS 6 complaining of the usage of integers instead of unsigned shorts. Easy fix.