diff options
author | Loïc Blot <nerzhul@users.noreply.github.com> | 2017-04-23 14:35:08 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-23 14:35:08 +0200 |
commit | 29ab20c27229672c24a7699afbcd54caad903331 (patch) | |
tree | e42e7ea35f54b1439055abc500191eb29baa6355 /src/database.cpp | |
parent | dda171d2925e20efc00c78bcb45cf595fd986da9 (diff) | |
download | minetest-29ab20c27229672c24a7699afbcd54caad903331.tar.gz minetest-29ab20c27229672c24a7699afbcd54caad903331.tar.bz2 minetest-29ab20c27229672c24a7699afbcd54caad903331.zip |
Player data to Database (#5475)
* Player data to Database
Add player data into databases (SQLite3 & PG only)
PostgreSQL & SQLite: better POO Design for databases
Add --migrate-players argument to server + deprecation warning
* Remove players directory if empty
Diffstat (limited to 'src/database.cpp')
-rw-r--r-- | src/database.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/database.cpp b/src/database.cpp index 262d475ec..8e1483893 100644 --- a/src/database.cpp +++ b/src/database.cpp @@ -48,7 +48,7 @@ static inline s64 pythonmodulo(s64 i, s16 mod) } -s64 Database::getBlockAsInteger(const v3s16 &pos) +s64 MapDatabase::getBlockAsInteger(const v3s16 &pos) { return (u64) pos.Z * 0x1000000 + (u64) pos.Y * 0x1000 + @@ -56,7 +56,7 @@ s64 Database::getBlockAsInteger(const v3s16 &pos) } -v3s16 Database::getIntegerAsBlock(s64 i) +v3s16 MapDatabase::getIntegerAsBlock(s64 i) { v3s16 pos; pos.X = unsigned_to_signed(pythonmodulo(i, 4096), 2048); |