forked from teamnwah/openmw-tes3coop
ac374a8ef9
Conflicts: apps/openmw-mp/Player.cpp apps/openmw-mp/Script/Functions/Mechanics.cpp apps/openmw-mp/Script/Functions/Mechanics.hpp apps/openmw-mp/Script/Functions/Quests.cpp apps/openmw-mp/Script/Functions/Quests.hpp apps/openmw-mp/Script/ScriptFunctions.hpp apps/openmw-mp/processors/player/ProcessorRecordDynamic.hpp apps/openmw/mwmp/LocalPlayer.hpp apps/openmw/mwmp/WorldEvent.cpp apps/openmw/mwworld/worldimp.cpp components/openmw-mp/Base/BasePlayer.hpp
27 lines
804 B
C++
27 lines
804 B
C++
#ifndef OPENMW_PROCESSORACTORINTERACTION_HPP
|
|
#define OPENMW_PROCESSORACTORINTERACTION_HPP
|
|
|
|
#include "../ActorProcessor.hpp"
|
|
|
|
namespace mwmp
|
|
{
|
|
class ProcessorActorInteraction final : public ActorProcessor
|
|
{
|
|
public:
|
|
ProcessorActorInteraction()
|
|
{
|
|
BPP_INIT(ID_ACTOR_INTERACTION)
|
|
}
|
|
|
|
void Do(ActorPacket &packet, const std::shared_ptr<Player> &player, BaseActorList &actorList) override
|
|
{
|
|
// Send only to players who have the cell loaded
|
|
Cell *serverCell = CellController::get().getCell(actorList.cell);
|
|
|
|
if (serverCell != nullptr && *serverCell->getAuthority() == actorList.guid)
|
|
serverCell->sendToLoaded(&packet, &actorList);
|
|
}
|
|
};
|
|
}
|
|
|
|
#endif //OPENMW_PROCESSORACTORINTERACTION_HPP
|