Modulo function fix

Fixes #453 

Test (custom-branch-no-emma): http://catrobatgw.ist.tugraz.at:8080/job/Catroid-custom-branch-no-emma-test/33/
http://catrobatgw.ist.tugraz.at:8080/job/Catroid-custom-branch-no-emma-test/40/
Test (custom-branch): http://catrobatgw.ist.tugraz.at:8080/job/Catroid-custom-branch-test/1240/
http://catrobatgw.ist.tugraz.at:8080/job/Catroid-custom-branch-test/1241/
http://catrobatgw.ist.tugraz.at:8080/job/Catroid-custom-branch-test/1242/