title: jQuery animateNumber - How to prop.animate floats
body: <p>i try to animate a number. I dont have any problems with ints, but my system doesnt work with floats.</p>
  
  <p>If the propNumberGV would be 5.5 and the new data.value = 10.0, the animations beginns at 0.0 and it doesnt at 5.5. The system works for integers, but not for floats...</p>
  
  <pre><code>var propNumberGV = gv == undefined || gv == null || gv == 0.0 ? 0 : gv;
          var dcp = 2;
          var dcf = dcp === 0 ? 1 : Math.pow(10, dcp);
          $("#gameValue").prop('number', propNumberGV).animateNumber({
              number: data.value * dcf,
              numberStep: function(now, tween) {
                  var floored_number = Math.floor(now) / dcf,
                  target = $("#gameValue");
                  if (dcp &gt; 0) {
                    floored_number = floored_number.toFixed(dcp);
                  }
  
                  target.text(floored_number);
              }
          }, 4000);
          gv = data.value;
  </code></pre>
  
  <p>I hope you can help me.</p>
  
  <p>jQuery animateNumber: 
  <a href="https://github.com/aishek/jquery-animateNumber/" rel="nofollow">https://github.com/aishek/jquery-animateNumber/</a></p>