From 669ebb97942037029834daf45ed3eeebaed3d96e Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Wed, 19 Aug 2015 00:21:11 -0400 Subject: [PATCH] v0.3.1a: updated deprecated method usage --- .../shatteredpixeldungeon/effects/Flare.java | 8 ++++---- .../shatteredpixeldungeon/effects/Speck.java | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/effects/Flare.java b/src/com/shatteredpixel/shatteredpixeldungeon/effects/Flare.java index 17884e4d4..fec565a51 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/effects/Flare.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/effects/Flare.java @@ -88,13 +88,13 @@ public class Flare extends Visual { for (int i=0; i < nRays; i++) { float a = i * 3.1415926f * 2 / nRays; - v[0] = FloatMath.cos( a ) * radius; - v[1] = FloatMath.sin( a ) * radius; + v[0] = (float)Math.cos( a ) * radius; + v[1] = (float)Math.sin( a ) * radius; vertices.put( v ); a += 3.1415926f * 2 / nRays / 2; - v[0] = FloatMath.cos( a ) * radius; - v[1] = FloatMath.sin( a ) * radius; + v[0] = (float)Math.cos( a ) * radius; + v[1] = (float)Math.sin( a ) * radius; vertices.put( v ); indices.put( (short)0 ); diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/effects/Speck.java b/src/com/shatteredpixel/shatteredpixeldungeon/effects/Speck.java index c0537deef..d4b24526c 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/effects/Speck.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/effects/Speck.java @@ -394,9 +394,9 @@ public class Speck extends Image { break; case CHANGE: - am = (float)FloatMath.sqrt( (p < 0.5f ? p : 1 - p) * 2); + am = (float)Math.sqrt( (p < 0.5f ? p : 1 - p) * 2); scale.y = (1 + p) * 0.5f; - scale.x = scale.y * FloatMath.cos( left * 15 ); + scale.x = scale.y * (float)Math.cos( left * 15 ); break; case HEART: @@ -430,7 +430,7 @@ public class Speck extends Image { break; case COIN: - scale.x = FloatMath.cos( left * 5 ); + scale.x = (float)Math.cos( left * 5 ); rm = gm = bm = (Math.abs( scale.x ) + 1) * 0.5f; am = p < 0.9f ? 1 : (1 - p) * 10; break;