Use (int) instead of intval() for performance reasons and to unify it.

Micro-optimization of int casting.
(int) is about 3 times faster than the method call. Same for (float).

I used my auto-correct [Cast sniff](https://github.com/dereuromark/cakephp-codesniffer/blob/master/Vendor/PHP/CodeSniffer/Standards/MyCakePHP/Sniffs/PHP/CastSniff.php)

    cake CodeSniffer.CodeSniffer run --sniffs MyCakePHP.PHP.Cast {corefolder} -v -f

That means, we could make this a CakePHP code-sniffer rule to keep the improvement in the future.

But it should be noted that I skipped on non-trivial replacements (more than a single argument) for now due to  probably errors then (`intval($x + $y)` would need to keep the parentheses). It would be easy to keep the additional (superfluous) parentheses, if no-one minds though. That would probably eliminate the change of errors.