Made math compatible with 64bit
Fixed warning in demo project for implicit conversion