Explorar o código

Merge pull request #8973 from thomas-goerlich/8957_rand_range_bugfix

Fixed rand_range not returning correct random values on windows
Rémi Verschelde %!s(int64=8) %!d(string=hai) anos
pai
achega
5a6d4971e1
Modificáronse 1 ficheiros con 1 adicións e 3 borrados
  1. 1 3
      core/math/math_funcs.h

+ 1 - 3
core/math/math_funcs.h

@@ -51,9 +51,7 @@ class Math {
 public:
 	Math() {} // useless to instance
 
-	enum {
-		RANDOM_MAX = 4294967295L
-	};
+	static const uint64_t RANDOM_MAX = 4294967295;
 
 	static _ALWAYS_INLINE_ double sin(double p_x) { return ::sin(p_x); }
 	static _ALWAYS_INLINE_ float sin(float p_x) { return ::sinf(p_x); }