openmw-tes3coop/apps/openmw-mp/Script
David Cernat 7fae28ce91 Prevent RemoveItem() script function from clearing inventorySendBuffer
Up to this commit, the following commands in a Lua script led to the target player receiving all three items, as expected:

    tes3mp.AddItem(self.pid, "common_shirt_01", 1, -1)
    tes3mp.AddItem(self.pid, "common_pants_01", 1, -1)
    tes3mp.AddItem(self.pid, "common_shoes_01", 1, -1)
    tes3mp.SendInventory(self.pid)

This, on the other hand, only led to the removal of the last item specified (in this case, the shoes):

    tes3mp.RemoveItem(self.pid, "common_shirt_01", 1)
    tes3mp.RemoveItem(self.pid, "common_pants_01", 1)
    tes3mp.RemoveItem(self.pid, "common_shoes_01", 1)
    tes3mp.SendInventory(self.pid)

Inventory functions are bound to remain confusing, but they should at least be consistent in their behavior.
2016-11-20 03:06:04 +02:00
..
API Revert "Use lowerCamelCase in tes3mp server script function names, part 2" 2016-11-16 19:27:46 +02:00
Functions Prevent RemoveItem() script function from clearing inventorySendBuffer 2016-11-20 03:06:04 +02:00
LangLua Revert "Use lowerCamelCase in tes3mp server script function names, part 2" 2016-11-16 19:27:46 +02:00
LangNative Fixed types in all GetInterface functions 2016-08-02 18:10:06 +08:00
LangPawn Revert "Use lowerCamelCase in tes3mp server script function names, part 2" 2016-11-16 19:27:46 +02:00
Language.hpp Fixed types in all GetInterface functions 2016-08-02 18:10:06 +08:00
Platform.hpp Fix include guard 2016-11-17 13:22:34 +08:00
Script.cpp Implement 'setenv' for windows 2016-08-02 17:32:10 +08:00
Script.hpp Log callbacks 2016-09-18 11:55:51 +08:00
ScriptFunction.cpp Make formatting consistent, part 2 2016-08-17 18:20:36 +03:00
ScriptFunction.hpp Fix include guard 2016-11-17 13:22:34 +08:00
ScriptFunctions.cpp Revert "Use lowerCamelCase in tes3mp server script function names, part 2" 2016-11-16 19:27:46 +02:00
ScriptFunctions.hpp Fix include guard 2016-11-17 13:22:34 +08:00
SystemInterface.hpp Fixed types in all GetInterface functions 2016-08-02 18:10:06 +08:00
Types.hpp Fix include guard 2016-11-17 13:22:34 +08:00