In manually bound functions, allows one to use any Vector3<T> value, as well as a {x, y, z} table, in Lua as any Vector3<T> parameter.
Has example in Debuggers' /vector command.
Unfortunately doesn't work in auto-bindings.
* Now having two funcs, Push(cEntity* ..) and Push(const cEntity* ...).
For now, the const function just casts away the const qualifier and
passes to the other.
Co-authored-by: mluchterhand <mluchterhand@max.de>
* Change reinterpret_cast -> static_cast wherever possible
* Remove more unnecessary `const_cast`s.
reinterpret_casts should be avoided for the same reason as c-style casts - they don't do any type-checking. reinterpret_cast was mainly being used for down-casting in inheritance hierarchies but static_cast works just as well while also making sure that there is actually an inheritance relationship there.
* Fixes a number of "<function>: not all control paths return a value" warnings on MSVC.
* Introduces the UNREACHABLE global macro and uses it instead of conditionally compiled switch defaults.
* Move cNBTParseErrorCategory from FastNBT.h into FastNBT.cpp to prevent bad calls to message()
* Replaces AppendVPrintf with fmt::sprintf
* fmt::ArgList now used as a type safe alternative to varargs.
* Removed SIZE_T_FMT compatibility macros. fmt::sprintf is fully portable and supports %zu.
* Adds FLOG functions to log with fmt's native formatting style.
Fixes#4127
Some classes were exported but were only pushed as a cEntity
meaning exported functions were inaccessible.
This brings cLuaState::Push(cEntity *) up to date with all exported entities.
* Fixed Clang 5.0 compile errors
* Fixed wrong comment
* Only disable warnings in Clang 5 or higher
* Added a CMake condition for the Clang 5 no-zero-as-null-pointer-constant warning
* Now using the use_nullptr branch of the Cuberite specific SQLiteCpp fork
Introduced new cLuaState::cOptionalCallback for representing optional callbacks (nil from Lua side).
Introduced new cLuaState::cStackTable class for easy access to Lua table's elements.
Fixes#3305.
On RasPi with gcc 4.8.2, the asserts wouldn't compile when tests were enabled.
Enforced the assumption that ASSERT code is generated only in Debug builds.