mirror of
https://github.com/azerothcore/mod-ale
synced 2025-11-29 15:38:17 +08:00
Revert 340fe17f4f partially
The UpdateUInt32Value method is not identical to Set and Set screws up gossip on TC based
This commit is contained in:
@@ -162,6 +162,7 @@ ElunaRegister<Object> ObjectMethods[] =
|
|||||||
// Setters
|
// Setters
|
||||||
{ "SetInt32Value", &LuaObject::SetInt32Value }, // :SetInt32Value(index, value) - Sets an int value for the object
|
{ "SetInt32Value", &LuaObject::SetInt32Value }, // :SetInt32Value(index, value) - Sets an int value for the object
|
||||||
{ "SetUInt32Value", &LuaObject::SetUInt32Value }, // :SetUInt32Value(index, value) - Sets an uint value for the object
|
{ "SetUInt32Value", &LuaObject::SetUInt32Value }, // :SetUInt32Value(index, value) - Sets an uint value for the object
|
||||||
|
{ "UpdateUInt32Value", &LuaObject::UpdateUInt32Value }, // :UpdateUInt32Value(index, value) - Sets an uint value for the object
|
||||||
{ "SetFloatValue", &LuaObject::SetFloatValue }, // :SetFloatValue(index, value) - Sets a float value for the object
|
{ "SetFloatValue", &LuaObject::SetFloatValue }, // :SetFloatValue(index, value) - Sets a float value for the object
|
||||||
{ "SetByteValue", &LuaObject::SetByteValue }, // :SetByteValue(index, offset, value) - Sets a byte value for the object
|
{ "SetByteValue", &LuaObject::SetByteValue }, // :SetByteValue(index, offset, value) - Sets a byte value for the object
|
||||||
{ "SetUInt16Value", &LuaObject::SetUInt16Value }, // :SetUInt16Value(index, offset, value) - Sets an uint16 value for the object
|
{ "SetUInt16Value", &LuaObject::SetUInt16Value }, // :SetUInt16Value(index, offset, value) - Sets an uint16 value for the object
|
||||||
|
|||||||
@@ -259,6 +259,20 @@ namespace LuaObject
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the data at the specified index to the given value, converted to an unsigned 32-bit integer.
|
||||||
|
*
|
||||||
|
* @param uint16 index
|
||||||
|
* @param uint32 value
|
||||||
|
*/
|
||||||
|
int UpdateUInt32Value(Eluna* /*E*/, lua_State* L, Object* obj)
|
||||||
|
{
|
||||||
|
uint16 index = Eluna::CHECKVAL<uint16>(L, 2);
|
||||||
|
uint32 value = Eluna::CHECKVAL<uint32>(L, 3);
|
||||||
|
obj->UpdateUInt32Value(index, value);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the data at the specified index to the given value, converted to a single-precision floating point value.
|
* Sets the data at the specified index to the given value, converted to a single-precision floating point value.
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user