Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ PingPongFrom01To010()

static float Terraria.Utils.PingPongFrom01To010 ( float value)
inlinestatic

Definition at line 166 of file Utils.cs.

167 {
168 value %= 1f;
169 if (value < 0f)
170 {
171 value += 1f;
172 }
173 if (value >= 0.5f)
174 {
175 return 2f - value * 2f;
176 }
177 return value * 2f;
178 }

References System.value.

Referenced by Terraria.Projectile.GetFairyQueenWeaponsColor(), and Terraria.Projectile.GetLastPrismHue().