Make love::Type handle type names

TODO: Fix undefined behaviour in luax_register_type, you can't use a va_list after a reference type

--HG--
branch : dynamiccore2
This commit is contained in:
Bart van Strien
2016-11-14 21:06:53 +01:00
parent 5d43c9601a
commit d967a755e5
110 changed files with 177 additions and 186 deletions
+2 -2
View File
@@ -47,6 +47,8 @@ static uint64 wangHash64(uint64 key)
return key;
}
love::Type RandomGenerator::type("RandomGenerator", &Object::type);
// 64 bit Xorshift implementation taken from the end of Sec. 3 (page 4) in
// George Marsaglia, "Xorshift RNGs", Journal of Statistical Software, Vol.8 (Issue 14), 2003
// Use an 'Xorshift*' variant, as shown here: http://xorshift.di.unimi.it
@@ -62,8 +64,6 @@ RandomGenerator::RandomGenerator()
setSeed(newseed);
}
love::Type RandomGenerator::type(&Object::type);
uint64 RandomGenerator::rand()
{
rng_state.b64 ^= (rng_state.b64 >> 12);