[Client] Send PlayerInventory packet after completing a vendor trade

0.6.2
David Cernat 7 years ago
parent e97c9f72a2
commit 0ad9c99cf4

@ -1,5 +1,12 @@
#include "hud.hpp"
#include <MyGUI_RenderManager.h>
#include <MyGUI_ProgressBar.h>
#include <MyGUI_Button.h>
#include <MyGUI_InputManager.h>
#include <MyGUI_ImageBox.h>
#include <MyGUI_ScrollView.h>
/*
Start of tes3mp addition
@ -14,13 +21,6 @@
End of tes3mp addition
*/
#include <MyGUI_RenderManager.h>
#include <MyGUI_ProgressBar.h>
#include <MyGUI_Button.h>
#include <MyGUI_InputManager.h>
#include <MyGUI_ImageBox.h>
#include <MyGUI_ScrollView.h>
#include <components/settings/settings.hpp>
#include <components/openmw-mp/Log.hpp>

@ -6,6 +6,17 @@
#include <MyGUI_InputManager.h>
#include <MyGUI_ControllerManager.h>
/*
Start of tes3mp addition
Include additional headers for multiplayer purposes
*/
#include "../mwmp/Main.hpp"
#include "../mwmp/LocalPlayer.hpp"
/*
End of tes3mp addition
*/
#include <components/widgets/numericeditbox.hpp>
#include "../mwbase/environment.hpp"
@ -350,6 +361,16 @@ namespace MWGui
mPtr.getClass().getCreatureStats(mPtr).getGoldPool() - mCurrentBalance );
}
/*
Start of tes3mp addition
Send an ID_PLAYER_INVENTORY packet every time a player completes a trade
*/
mwmp::Main::get().getLocalPlayer()->sendInventory();
/*
End of tes3mp addition
*/
MWBase::Environment::get().getWindowManager()->getDialogueWindow()->addResponse(
MWBase::Environment::get().getWorld()->getStore().get<ESM::GameSetting>().find("sBarterDialog5")->getString());

Loading…
Cancel
Save