credit to @MusicMonkey5555 for spotting. asserts for Div/NULLs with mutli-element classes

Also includes his magnitude and normalize safe alts
This commit is contained in:
Azaezel 2015-08-12 03:41:49 -05:00
parent c9bf6b1ae5
commit 4d3db61e94
3 changed files with 39 additions and 1 deletions

View file

@ -503,6 +503,7 @@ inline ColorI& ColorI::operator*=(const S32 in_mul)
inline ColorI& ColorI::operator/=(const S32 in_mul)
{
AssertFatal(in_mul != 0.0f, "Error, div by zero...");
red = red / in_mul;
green = green / in_mul;
blue = blue / in_mul;