That's the way most languages work. When converting from Float to Int, the decimal gets dropped regardless of value. Blitz3D is the first programming language that I've used that rounded the numbers. For games, the BMax version is actually prefered. Suppose you have a play area divided into cells where each cell is 32x32 pixels. How can you tell what cell your mouse is pointing to?
That would give incorrect results if the numbers were rounded. for example, if MouseX() were to return 15, then MouseX() / 32 would be 0.46875 which would be rounded down to 0, but if MouseX were to return 17, then MouseX()/32 would be 0.53125 which would round up to 1. Except that the mouse would still be pointing at the same cell. The next cell does not start until pixel 32.
If you actually need the decimal rounded instead of just dropped, use Dreamora's suggestion.
CellX = MouseX() / 32 CellY = MouseY() / 32
That would give incorrect results if the numbers were rounded. for example, if MouseX() were to return 15, then MouseX() / 32 would be 0.46875 which would be rounded down to 0, but if MouseX were to return 17, then MouseX()/32 would be 0.53125 which would round up to 1. Except that the mouse would still be pointing at the same cell. The next cell does not start until pixel 32.
If you actually need the decimal rounded instead of just dropped, use Dreamora's suggestion.