Fixed ArrayIndexOutOfBoundException
Merge pull request #233 from LolNO/master

Fixed ArrayIndexOutOfBoundException in ImageMode:Repeat