From 22ad820aa459e055fde817d94f31a9461aac2726 Mon Sep 17 00:00:00 2001 From: Paul Ouellette Date: Thu, 11 Apr 2019 15:45:39 -0400 Subject: Add node field to PlayerHPChangeReason table (#8368) --- src/script/cpp_api/s_base.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/script/cpp_api/s_base.cpp') diff --git a/src/script/cpp_api/s_base.cpp b/src/script/cpp_api/s_base.cpp index a8ed902dd..e73f613ce 100644 --- a/src/script/cpp_api/s_base.cpp +++ b/src/script/cpp_api/s_base.cpp @@ -404,6 +404,10 @@ void ScriptApiBase::pushPlayerHPChangeReason(lua_State *L, const PlayerHPChangeR objectrefGetOrCreate(L, reason.object); lua_setfield(L, -2, "object"); } + if (!reason.node.empty()) { + lua_pushstring(L, reason.node.c_str()); + lua_setfield(L, -2, "node"); + } } Server* ScriptApiBase::getServer() -- cgit v1.2.3