Skip to content

Commit

Permalink
Fix wrong type casting
Browse files Browse the repository at this point in the history
  • Loading branch information
Foereaper committed Nov 10, 2024
1 parent 321a184 commit 907131f
Showing 1 changed file with 25 additions and 25 deletions.
50 changes: 25 additions & 25 deletions LuaFunctions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,31 +70,31 @@ ElunaConstrainedObjectRef<Vehicle> GetWeakPtrFor(Vehicle const* obj)
#endif
#endif

template<> inline int ElunaTemplate<unsigned long long>::Add(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::plus<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::Subtract(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::minus<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::Multiply(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::multiplies<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::Divide(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::divides<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::Mod(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::modulus<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::Equal(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::equal_to<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::Less(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::less<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::LessOrEqual(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::less_equal<unsigned long long>()); }
template<> inline int ElunaTemplate<unsigned long long>::ToString(lua_State* L) { return ToStringHelper(L); }
template<> inline int ElunaTemplate<unsigned long long>::Pow(lua_State* L) { return PowHelper(L); }

template<> inline int ElunaTemplate<long long>::Add(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::plus<long long>()); }
template<> inline int ElunaTemplate<long long>::Subtract(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::minus<long long>()); }
template<> inline int ElunaTemplate<long long>::Multiply(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::multiplies<long long>()); }
template<> inline int ElunaTemplate<long long>::Divide(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::divides<long long>()); }
template<> inline int ElunaTemplate<long long>::Mod(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::modulus<long long>()); }
template<> inline int ElunaTemplate<long long>::UnaryMinus(lua_State* L) { return PerformUnaryOp<unsigned long long>(L, std::negate<long long>()); }
template<> inline int ElunaTemplate<long long>::Equal(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::equal_to<long long>()); }
template<> inline int ElunaTemplate<long long>::Less(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::less<long long>()); }
template<> inline int ElunaTemplate<long long>::LessOrEqual(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::less_equal<long long>()); }
template<> inline int ElunaTemplate<long long>::ToString(lua_State* L) { return ToStringHelper(L); }
template<> inline int ElunaTemplate<long long>::Pow(lua_State* L) { return PowHelper(L); }

template<> inline int ElunaTemplate<ObjectGuid>::Equal(lua_State* L) { Eluna* E = Eluna::GetEluna(L); E->Push(E->CHECKVAL<ObjectGuid>(1) == E->CHECKVAL<ObjectGuid>(2)); return 1; }
template<> inline int ElunaTemplate<ObjectGuid>::ToString(lua_State* L)
template<> int ElunaTemplate<unsigned long long>::Add(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::plus<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::Subtract(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::minus<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::Multiply(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::multiplies<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::Divide(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::divides<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::Mod(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::modulus<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::Equal(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::equal_to<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::Less(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::less<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::LessOrEqual(lua_State* L) { return PerformBinaryOp<unsigned long long>(L, std::less_equal<unsigned long long>()); }
template<> int ElunaTemplate<unsigned long long>::ToString(lua_State* L) { return ToStringHelper(L); }
template<> int ElunaTemplate<unsigned long long>::Pow(lua_State* L) { return PowHelper(L); }

template<> int ElunaTemplate<long long>::Add(lua_State* L) { return PerformBinaryOp<long long>(L, std::plus<long long>()); }
template<> int ElunaTemplate<long long>::Subtract(lua_State* L) { return PerformBinaryOp<long long>(L, std::minus<long long>()); }
template<> int ElunaTemplate<long long>::Multiply(lua_State* L) { return PerformBinaryOp<long long>(L, std::multiplies<long long>()); }
template<> int ElunaTemplate<long long>::Divide(lua_State* L) { return PerformBinaryOp<long long>(L, std::divides<long long>()); }
template<> int ElunaTemplate<long long>::Mod(lua_State* L) { return PerformBinaryOp<long long>(L, std::modulus<long long>()); }
template<> int ElunaTemplate<long long>::UnaryMinus(lua_State* L) { return PerformUnaryOp<long long>(L, std::negate<long long>()); }
template<> int ElunaTemplate<long long>::Equal(lua_State* L) { return PerformBinaryOp<long long>(L, std::equal_to<long long>()); }
template<> int ElunaTemplate<long long>::Less(lua_State* L) { return PerformBinaryOp<long long>(L, std::less<long long>()); }
template<> int ElunaTemplate<long long>::LessOrEqual(lua_State* L) { return PerformBinaryOp<long long>(L, std::less_equal<long long>()); }
template<> int ElunaTemplate<long long>::ToString(lua_State* L) { return ToStringHelper(L); }
template<> int ElunaTemplate<long long>::Pow(lua_State* L) { return PowHelper(L); }

template<> int ElunaTemplate<ObjectGuid>::Equal(lua_State* L) { Eluna* E = Eluna::GetEluna(L); E->Push(E->CHECKVAL<ObjectGuid>(1) == E->CHECKVAL<ObjectGuid>(2)); return 1; }
template<> int ElunaTemplate<ObjectGuid>::ToString(lua_State* L)
{
Eluna* E = Eluna::GetEluna(L);
#if defined ELUNA_TRINITY
Expand Down

0 comments on commit 907131f

Please sign in to comment.