Equivalent float ops are being optimized more aggressively
| 40 | // Equivalent |
| 41 | // float ops are being optimized more aggressively |
| 42 | void xClimateInitAsset(_tagClimate* climate, xEnvAsset* asset) |
| 43 | { |
| 44 | sClimate = climate; |
| 45 | climate->wind.strength = 0.0f; |
| 46 | xClimateVecFromAngle(climate->wind.angle, &climate->wind.dir); |
| 47 | |
| 48 | if (asset->climateFlags == 0) |
| 49 | { |
| 50 | climate->wind.strength = 0.0f; |
| 51 | climate->rain.strength = 0.0f; |
| 52 | return; |
| 53 | } |
| 54 | if (asset->climateFlags & 1) |
| 55 | { |
| 56 | climate->rain.rain = 1.0f; |
| 57 | climate->rain.strength = 0.5f * (asset->climateStrengthMax - asset->climateStrengthMin); |
| 58 | climate->rain.strength += asset->climateStrengthMin; |
| 59 | } |
| 60 | else if (asset->climateFlags & 2) |
| 61 | { |
| 62 | climate->rain.rain = 0.0f; |
| 63 | climate->rain.strength = 0.5f * (asset->climateStrengthMax - asset->climateStrengthMin); |
| 64 | climate->rain.strength += asset->climateStrengthMin; |
| 65 | } |
| 66 | } |
| 67 | |
| 68 | void xClimateSetSnow(F32 stre) |
| 69 | { |
no test coverage detected