Merge pull request #378 from TES3MP/0.6.3 while resolving conflicts

Conflicts:
	apps/openmw-mp/CMakeLists.txt
	apps/openmw-mp/Script/ScriptFunctions.hpp
	components/CMakeLists.txt
sol2-server-rewrite
David Cernat 7 years ago
commit 5858e05362

@ -61,31 +61,35 @@ source_group(tes3mp-server FILES ${SERVER} ${SERVER_HEADER})
set(PROCESSORS_ACTOR set(PROCESSORS_ACTOR
processors/actor/ProcessorActorAnimFlags.hpp processors/actor/ProcessorActorAnimPlay.hpp processors/actor/ProcessorActorAnimFlags.hpp processors/actor/ProcessorActorAnimPlay.hpp
processors/actor/ProcessorActorAttack.hpp processors/actor/ProcessorActorCellChange.hpp processors/actor/ProcessorActorAttack.hpp processors/actor/ProcessorActorCellChange.hpp
processors/actor/ProcessorActorEquipment.hpp processors/actor/ProcessorActorList.hpp processors/actor/ProcessorActorEquipment.hpp processors/actor/ProcessorActorInteraction.hpp
processors/actor/ProcessorActorPosition.hpp processors/actor/ProcessorActorSpeech.hpp processors/actor/ProcessorActorList.hpp processors/actor/ProcessorActorPosition.hpp
processors/actor/ProcessorActorStatsDynamic.hpp processors/actor/ProcessorActorTest.hpp processors/actor/ProcessorActorSpeech.hpp processors/actor/ProcessorActorStatsDynamic.hpp
processors/actor/ProcessorActorTest.hpp
) )
source_group(tes3mp-server\\processors\\actor FILES ${PROCESSORS_ACTOR}) source_group(tes3mp-server\\processors\\actor FILES ${PROCESSORS_ACTOR})
set(PROCESSORS_PLAYER set(PROCESSORS_PLAYER
processors/player/ProcessorChatMsg.hpp processors/player/ProcessorGUIMessageBox.hpp processors/player/ProcessorChatMsg.hpp processors/player/ProcessorGUIMessageBox.hpp
processors/player/ProcessorGameWeather.hpp processors/player/ProcessorPlayerAnimFlags.hpp processors/player/ProcessorGUIWindow.hpp
processors/player/ProcessorPlayerAnimPlay.hpp processors/player/ProcessorPlayerAttack.hpp
processors/player/ProcessorPlayerAttribute.hpp processors/player/ProcessorPlayerBook.hpp processors/player/ProcessorRecordDynamic.hpp processors/player/ProcessorGameWeather.hpp
processors/player/ProcessorPlayerBounty.hpp processors/player/ProcessorPlayerCellChange.hpp processors/player/ProcessorPlayerAnimFlags.hpp processors/player/ProcessorPlayerAnimPlay.hpp
processors/player/ProcessorPlayerCellState.hpp processors/player/ProcessorPlayerCharClass.hpp processors/player/ProcessorPlayerAttack.hpp processors/player/ProcessorPlayerAttribute.hpp
processors/player/ProcessorPlayerCharGen.hpp processors/player/ProcessorPlayerDeath.hpp processors/player/ProcessorPlayerBook.hpp processors/player/ProcessorPlayerBounty.hpp
processors/player/ProcessorPlayerDisposition.hpp processors/player/ProcessorPlayerEquipment.hpp processors/player/ProcessorPlayerCellChange.hpp processors/player/ProcessorPlayerCellState.hpp
processors/player/ProcessorPlayerFaction.hpp processors/player/ProcessorPlayerInventory.hpp processors/player/ProcessorPlayerCharClass.hpp processors/player/ProcessorPlayerCharGen.hpp
processors/player/ProcessorPlayerDeath.hpp processors/player/ProcessorPlayerDisposition.hpp
processors/player/ProcessorPlayerEquipment.hpp processors/player/ProcessorPlayerFaction.hpp
processors/player/ProcessorPlayerInteraction.hpp processors/player/ProcessorPlayerInventory.hpp
processors/player/ProcessorPlayerJournal.hpp processors/player/ProcessorPlayerKillCount.hpp processors/player/ProcessorPlayerJournal.hpp processors/player/ProcessorPlayerKillCount.hpp
processors/player/ProcessorPlayerLevel.hpp processors/player/ProcessorPlayerMap.hpp processors/player/ProcessorPlayerLevel.hpp processors/player/ProcessorPlayerMap.hpp
processors/player/ProcessorPlayerPosition.hpp processors/player/ProcessorPlayerQuickKeys.hpp processors/player/ProcessorPlayerMiscellaneous.hpp processors/player/ProcessorPlayerPosition.hpp
processors/player/ProcessorPlayerRest.hpp processors/player/ProcessorPlayerResurrect.hpp processors/player/ProcessorPlayerQuickKeys.hpp processors/player/ProcessorPlayerRest.hpp
processors/player/ProcessorPlayerShapeshift.hpp processors/player/ProcessorPlayerSkill.hpp processors/player/ProcessorPlayerResurrect.hpp processors/player/ProcessorPlayerShapeshift.hpp
processors/player/ProcessorPlayerSpeech.hpp processors/player/ProcessorPlayerSpellbook.hpp processors/player/ProcessorPlayerSkill.hpp processors/player/ProcessorPlayerSpeech.hpp
processors/player/ProcessorPlayerStatsDynamic.hpp processors/player/ProcessorPlayerTopic.hpp processors/player/ProcessorPlayerSpellbook.hpp processors/player/ProcessorPlayerStatsDynamic.hpp
processors/player/ProcessorGUIWindow.hpp processors/player/ProcessorPlayerTopic.hpp
) )
source_group(tes3mp-server\\processors\\player FILES ${PROCESSORS_PLAYER}) source_group(tes3mp-server\\processors\\player FILES ${PROCESSORS_PLAYER})
@ -99,7 +103,8 @@ set(PROCESSORS_WORLD
processors/world/ProcessorObjectSpawn.hpp processors/world/ProcessorObjectState.hpp processors/world/ProcessorObjectSpawn.hpp processors/world/ProcessorObjectState.hpp
processors/world/ProcessorObjectTrap.hpp processors/world/ProcessorScriptLocalShort.hpp processors/world/ProcessorObjectTrap.hpp processors/world/ProcessorScriptLocalShort.hpp
processors/world/ProcessorScriptLocalFloat.hpp processors/world/ProcessorScriptMemberShort.hpp processors/world/ProcessorScriptLocalFloat.hpp processors/world/ProcessorScriptMemberShort.hpp
processors/world/ProcessorScriptGlobalShort.hpp processors/world/ProcessorVideoPlay.hpp processors/world/ProcessorScriptMemberFloat.hpp processors/world/ProcessorScriptGlobalShort.hpp
processors/world/ProcessorScriptGlobalFloat.hpp processors/world/ProcessorVideoPlay.hpp
) )
source_group(tes3mp-server\\processors\\world FILES ${PROCESSORS_WORLD}) source_group(tes3mp-server\\processors\\world FILES ${PROCESSORS_WORLD})

@ -51,6 +51,7 @@ EventController::EventController(LuaState *luaCtrl)
ADD_CORE_EVENT(ON_PLAYER_SKILL), ADD_CORE_EVENT(ON_PLAYER_SKILL),
ADD_CORE_EVENT(ON_PLAYER_LEVEL), ADD_CORE_EVENT(ON_PLAYER_LEVEL),
ADD_CORE_EVENT(ON_PLAYER_BOUNTY), ADD_CORE_EVENT(ON_PLAYER_BOUNTY),
ADD_CORE_EVENT(ON_PLAYER_REPUTATION),
ADD_CORE_EVENT(ON_PLAYER_EQUIPMENT), ADD_CORE_EVENT(ON_PLAYER_EQUIPMENT),
ADD_CORE_EVENT(ON_PLAYER_INVENTORY), ADD_CORE_EVENT(ON_PLAYER_INVENTORY),
ADD_CORE_EVENT(ON_PLAYER_JOURNAL), ADD_CORE_EVENT(ON_PLAYER_JOURNAL),
@ -61,7 +62,9 @@ EventController::EventController(LuaState *luaCtrl)
ADD_CORE_EVENT(ON_PLAYER_TOPIC), ADD_CORE_EVENT(ON_PLAYER_TOPIC),
ADD_CORE_EVENT(ON_PLAYER_DISPOSITION), ADD_CORE_EVENT(ON_PLAYER_DISPOSITION),
ADD_CORE_EVENT(ON_PLAYER_BOOK), ADD_CORE_EVENT(ON_PLAYER_BOOK),
ADD_CORE_EVENT(ON_PLAYER_MISCELLANEOUS),
ADD_CORE_EVENT(ON_PLAYER_MAP), ADD_CORE_EVENT(ON_PLAYER_MAP),
ADD_CORE_EVENT(ON_PLAYER_INTERACTION),
ADD_CORE_EVENT(ON_PLAYER_REST), ADD_CORE_EVENT(ON_PLAYER_REST),
ADD_CORE_EVENT(ON_PLAYER_SENDMESSAGE), ADD_CORE_EVENT(ON_PLAYER_SENDMESSAGE),
ADD_CORE_EVENT(ON_PLAYER_ENDCHARGEN), ADD_CORE_EVENT(ON_PLAYER_ENDCHARGEN),

@ -27,6 +27,7 @@ namespace CoreEvent
ON_PLAYER_SKILL, ON_PLAYER_SKILL,
ON_PLAYER_LEVEL, ON_PLAYER_LEVEL,
ON_PLAYER_BOUNTY, ON_PLAYER_BOUNTY,
ON_PLAYER_REPUTATION,
ON_PLAYER_EQUIPMENT, ON_PLAYER_EQUIPMENT,
ON_PLAYER_INVENTORY, ON_PLAYER_INVENTORY,
ON_PLAYER_JOURNAL, ON_PLAYER_JOURNAL,
@ -37,7 +38,9 @@ namespace CoreEvent
ON_PLAYER_TOPIC, ON_PLAYER_TOPIC,
ON_PLAYER_DISPOSITION, ON_PLAYER_DISPOSITION,
ON_PLAYER_BOOK, ON_PLAYER_BOOK,
ON_PLAYER_MISCELLANEOUS,
ON_PLAYER_MAP, ON_PLAYER_MAP,
ON_PLAYER_INTERACTION,
ON_PLAYER_REST, ON_PLAYER_REST,
ON_PLAYER_SENDMESSAGE, ON_PLAYER_SENDMESSAGE,
ON_PLAYER_ENDCHARGEN, ON_PLAYER_ENDCHARGEN,

@ -0,0 +1,27 @@
#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

@ -1,7 +1,3 @@
//
// Created by koncord on 01.04.17.
//
#ifndef OPENMW_PROCESSORPLAYERATTACK_HPP #ifndef OPENMW_PROCESSORPLAYERATTACK_HPP
#define OPENMW_PROCESSORPLAYERATTACK_HPP #define OPENMW_PROCESSORPLAYERATTACK_HPP

@ -0,0 +1,25 @@
#ifndef OPENMW_PROCESSORPLAYERINTERACTION_HPP
#define OPENMW_PROCESSORPLAYERINTERACTION_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerInteraction final : public PlayerProcessor
{
public:
ProcessorPlayerInteraction()
{
BPP_INIT(ID_PLAYER_INTERACTION)
}
void Do(PlayerPacket &packet, const std::shared_ptr<Player> &player) override
{
DEBUG_PRINTF(strPacketID.c_str());
Networking::get().getState().getEventCtrl().Call<CoreEvent::ON_PLAYER_INTERACTION>(player);
}
};
}
#endif //OPENMW_PROCESSORPLAYERINTERACTION_HPP

@ -0,0 +1,25 @@
#ifndef OPENMW_PROCESSORPLAYERMISCELLANEOUS_HPP
#define OPENMW_PROCESSORPLAYERMISCELLANEOUS_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerMiscellaneous final : public PlayerProcessor
{
public:
ProcessorPlayerMiscellaneous()
{
BPP_INIT(ID_PLAYER_MISCELLANEOUS)
}
void Do(PlayerPacket &packet, const std::shared_ptr<Player> &player) override
{
DEBUG_PRINTF(strPacketID.c_str());
Networking::get().getState().getEventCtrl().Call<CoreEvent::ON_PLAYER_MISCELLANEOUS>(player);
}
};
}
#endif //OPENMW_PROCESSORPLAYERMISCELLANEOUS_HPP

@ -5,7 +5,7 @@
namespace mwmp namespace mwmp
{ {
class ProcessorPlayerQuickKeys : public PlayerProcessor class ProcessorPlayerQuickKeys final : public PlayerProcessor
{ {
public: public:
ProcessorPlayerQuickKeys() ProcessorPlayerQuickKeys()

@ -0,0 +1,23 @@
#ifndef OPENMW_PROCESSORPLAYERREPUTATION_HPP
#define OPENMW_PROCESSORPLAYERREPUTATION_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerReputation final : public PlayerProcessor
{
public:
ProcessorPlayerReputation()
{
BPP_INIT(ID_PLAYER_REPUTATION)
}
void Do(PlayerPacket &packet, const std::shared_ptr<Player> &player) override
{
Networking::get().getState().getEventCtrl().Call<CoreEvent::ON_PLAYER_REPUTATION>(player);
}
};
}
#endif //OPENMW_PROCESSORPLAYERREPUTATION_HPP

@ -0,0 +1,25 @@
#ifndef OPENMW_PROCESSORPLAYERRECORDDYNAMIC_HPP
#define OPENMW_PROCESSORPLAYERRECORDDYNAMIC_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerRecordDynamic final : public PlayerProcessor
{
public:
ProcessorPlayerRecordDynamic()
{
BPP_INIT(ID_RECORD_DYNAMIC)
}
void Do(PlayerPacket &packet, const std::shared_ptr<Player> &player) override
{
DEBUG_PRINTF(strPacketID.c_str());
Script::Call<Script::CallbackIdentity("OnRecordDynamic")>(player.getId());
}
};
}
#endif //OPENMW_PROCESSORPLAYERRECORDDYNAMIC_HPP

@ -0,0 +1,18 @@
#ifndef OPENMW_PROCESSORSCRIPTGLOBALFLOAT_HPP
#define OPENMW_PROCESSORSCRIPTGLOBALFLOAT_HPP
#include "../WorldProcessor.hpp"
namespace mwmp
{
class ProcessorScriptGlobalFloat final : public WorldProcessor
{
public:
ProcessorScriptGlobalFloat()
{
BPP_INIT(ID_SCRIPT_GLOBAL_FLOAT)
}
};
}
#endif //OPENMW_PROCESSORSCRIPTGLOBALFLOAT_HPP

@ -0,0 +1,18 @@
#ifndef OPENMW_PROCESSORSCRIPTMEMBERFLOAT_HPP
#define OPENMW_PROCESSORSCRIPTMEMBERFLOAT_HPP
#include "../WorldProcessor.hpp"
namespace mwmp
{
class ProcessorScriptMemberFloat final : public WorldProcessor
{
public:
ProcessorScriptMemberFloat()
{
BPP_INIT(ID_SCRIPT_MEMBER_FLOAT)
}
};
}
#endif //OPENMW_PROCESSORSCRIPTMEMBERFLOAT_HPP

@ -108,25 +108,27 @@ add_openmw_dir(mwmp/processors BaseClientPacketProcessor PlayerProcessor WorldPr
) )
add_openmw_dir (mwmp/processors/actor ProcessorActorAI ProcessorActorAnimFlags ProcessorActorAnimPlay ProcessorActorAttack add_openmw_dir (mwmp/processors/actor ProcessorActorAI ProcessorActorAnimFlags ProcessorActorAnimPlay ProcessorActorAttack
ProcessorActorAuthority ProcessorActorCellChange ProcessorActorDeath ProcessorActorEquipment ProcessorActorList ProcessorActorAuthority ProcessorActorCellChange ProcessorActorDeath ProcessorActorEquipment ProcessorActorInteraction
ProcessorActorPosition ProcessorActorSpeech ProcessorActorStatsDynamic ProcessorActorTest ProcessorActorList ProcessorActorPosition ProcessorActorSpeech ProcessorActorStatsDynamic ProcessorActorTest
) )
add_openmw_dir (mwmp/processors/player ProcessorChatMessage ProcessorGUIMessageBox ProcessorHandshake add_openmw_dir (mwmp/processors/player ProcessorChatMessage ProcessorGUIMessageBox ProcessorHandshake
ProcessorUserDisconnected ProcessorUserMyID ProcessorGameSettings ProcessorGameTime ProcessorGameWeather ProcessorUserDisconnected ProcessorUserMyID ProcessorCellCreate ProcessorRecordDynamic ProcessorGameSettings
ProcessorPlayerBaseInfo ProcessorPlayerAnimFlags ProcessorPlayerAnimPlay ProcessorPlayerAttack ProcessorPlayerAttribute ProcessorGameTime ProcessorGameWeather ProcessorPlayerAnimFlags ProcessorPlayerAnimPlay ProcessorPlayerAttack
ProcessorPlayerBook ProcessorPlayerBounty ProcessorPlayerCellChange ProcessorPlayerCellState ProcessorPlayerCharClass ProcessorPlayerAttribute ProcessorPlayerBaseInfo ProcessorPlayerBehavior ProcessorPlayerBook ProcessorPlayerBounty
ProcessorPlayerCharGen ProcessorPlayerDeath ProcessorPlayerDisposition ProcessorPlayerEquipment ProcessorPlayerFaction ProcessorPlayerCellChange ProcessorPlayerCellState ProcessorPlayerCharClass ProcessorPlayerCharGen ProcessorPlayerDeath
ProcessorPlayerDisposition ProcessorPlayerEquipment ProcessorPlayerFaction ProcessorPlayerInteraction
ProcessorPlayerInventory ProcessorPlayerJail ProcessorPlayerJournal ProcessorPlayerKillCount ProcessorPlayerLevel ProcessorPlayerInventory ProcessorPlayerJail ProcessorPlayerJournal ProcessorPlayerKillCount ProcessorPlayerLevel
ProcessorPlayerMap ProcessorPlayerPosition ProcessorPlayerQuickKeys ProcessorPlayerResurrect ProcessorPlayerShapeshift ProcessorPlayerMap ProcessorPlayerMiscellaneous ProcessorPlayerPosition ProcessorPlayerQuickKeys
ProcessorPlayerSkill ProcessorPlayerSpeech ProcessorPlayerSpellbook ProcessorPlayerStatsDynamic ProcessorPlayerTopic ProcessorPlayerReputation ProcessorPlayerResurrect ProcessorPlayerShapeshift ProcessorPlayerSkill ProcessorPlayerSpeech
ProcessorPlayerSpellbook ProcessorPlayerStatsDynamic ProcessorPlayerTopic
) )
add_openmw_dir (mwmp/processors/world BaseObjectProcessor ProcessorConsoleCommand ProcessorContainer ProcessorDoorState add_openmw_dir (mwmp/processors/world BaseObjectProcessor ProcessorConsoleCommand ProcessorContainer ProcessorDoorState
ProcessorMusicPlay ProcessorVideoPlay ProcessorObjectAnimPlay ProcessorObjectDelete ProcessorObjectLock ProcessorMusicPlay ProcessorVideoPlay ProcessorObjectAnimPlay ProcessorObjectDelete ProcessorObjectLock
ProcessorObjectMove ProcessorObjectPlace ProcessorObjectRotate ProcessorObjectScale ProcessorObjectSpawn ProcessorObjectMove ProcessorObjectPlace ProcessorObjectReset ProcessorObjectRotate ProcessorObjectScale
ProcessorObjectState ProcessorObjectTrap ProcessorScriptLocalShort ProcessorScriptLocalFloat ProcessorScriptMemberShort ProcessorObjectSpawn ProcessorObjectState ProcessorObjectTrap ProcessorScriptLocalShort ProcessorScriptLocalFloat
ProcessorScriptGlobalShort ProcessorScriptMemberShort ProcessorScriptMemberFloat ProcessorScriptGlobalShort ProcessorScriptGlobalFloat
) )
# Main executable # Main executable

@ -11,33 +11,39 @@
#include "player/ProcessorGUIWindow.hpp" #include "player/ProcessorGUIWindow.hpp"
#include "player/ProcessorHandshake.hpp" #include "player/ProcessorHandshake.hpp"
#include "player/ProcessorUserDisconnected.hpp" #include "player/ProcessorUserDisconnected.hpp"
#include "player/ProcessorCellCreate.hpp"
#include "player/ProcessorRecordDynamic.hpp"
#include "player/ProcessorGameSettings.hpp" #include "player/ProcessorGameSettings.hpp"
#include "player/ProcessorGameTime.hpp" #include "player/ProcessorGameTime.hpp"
#include "player/ProcessorGameWeather.hpp" #include "player/ProcessorGameWeather.hpp"
#include "player/ProcessorPlayerBaseInfo.hpp"
#include "player/ProcessorPlayerCharGen.hpp"
#include "player/ProcessorPlayerAnimFlags.hpp" #include "player/ProcessorPlayerAnimFlags.hpp"
#include "player/ProcessorPlayerAnimPlay.hpp" #include "player/ProcessorPlayerAnimPlay.hpp"
#include "player/ProcessorPlayerAttack.hpp" #include "player/ProcessorPlayerAttack.hpp"
#include "player/ProcessorPlayerAttribute.hpp" #include "player/ProcessorPlayerAttribute.hpp"
#include "player/ProcessorPlayerBaseInfo.hpp"
#include "player/ProcessorPlayerBehavior.hpp"
#include "player/ProcessorPlayerBook.hpp" #include "player/ProcessorPlayerBook.hpp"
#include "player/ProcessorPlayerBounty.hpp" #include "player/ProcessorPlayerBounty.hpp"
#include "player/ProcessorPlayerCellChange.hpp" #include "player/ProcessorPlayerCellChange.hpp"
#include "player/ProcessorPlayerCellState.hpp" #include "player/ProcessorPlayerCellState.hpp"
#include "player/ProcessorPlayerCharClass.hpp" #include "player/ProcessorPlayerCharClass.hpp"
#include "player/ProcessorPlayerCharGen.hpp"
#include "player/ProcessorPlayerDeath.hpp" #include "player/ProcessorPlayerDeath.hpp"
#include "player/ProcessorPlayerDisposition.hpp" #include "player/ProcessorPlayerDisposition.hpp"
#include "player/ProcessorPlayerEquipment.hpp" #include "player/ProcessorPlayerEquipment.hpp"
#include "player/ProcessorPlayerFaction.hpp" #include "player/ProcessorPlayerFaction.hpp"
#include "player/ProcessorPlayerInteraction.hpp"
#include "player/ProcessorPlayerInventory.hpp" #include "player/ProcessorPlayerInventory.hpp"
#include "player/ProcessorPlayerJail.hpp" #include "player/ProcessorPlayerJail.hpp"
#include "player/ProcessorPlayerJournal.hpp" #include "player/ProcessorPlayerJournal.hpp"
#include "player/ProcessorPlayerKillCount.hpp" #include "player/ProcessorPlayerKillCount.hpp"
#include "player/ProcessorPlayerLevel.hpp" #include "player/ProcessorPlayerLevel.hpp"
#include "player/ProcessorPlayerMap.hpp" #include "player/ProcessorPlayerMap.hpp"
#include "player/ProcessorPlayerMiscellaneous.hpp"
#include "player/ProcessorPlayerPosition.hpp" #include "player/ProcessorPlayerPosition.hpp"
#include "player/ProcessorPlayerQuickKeys.hpp" #include "player/ProcessorPlayerQuickKeys.hpp"
#include "player/ProcessorPlayerRegionAuthority.hpp" #include "player/ProcessorPlayerRegionAuthority.hpp"
#include "player/ProcessorPlayerReputation.hpp"
#include "player/ProcessorPlayerRest.hpp" #include "player/ProcessorPlayerRest.hpp"
#include "player/ProcessorPlayerResurrect.hpp" #include "player/ProcessorPlayerResurrect.hpp"
#include "player/ProcessorPlayerShapeshift.hpp" #include "player/ProcessorPlayerShapeshift.hpp"
@ -50,6 +56,7 @@
#include "WorldProcessor.hpp" #include "WorldProcessor.hpp"
#include "world/ProcessorConsoleCommand.hpp" #include "world/ProcessorConsoleCommand.hpp"
#include "world/ProcessorContainer.hpp" #include "world/ProcessorContainer.hpp"
#include "world/ProcessorDoorDestination.hpp"
#include "world/ProcessorDoorState.hpp" #include "world/ProcessorDoorState.hpp"
#include "world/ProcessorMusicPlay.hpp" #include "world/ProcessorMusicPlay.hpp"
#include "world/ProcessorObjectAnimPlay.hpp" #include "world/ProcessorObjectAnimPlay.hpp"
@ -57,6 +64,7 @@
#include "world/ProcessorObjectLock.hpp" #include "world/ProcessorObjectLock.hpp"
#include "world/ProcessorObjectMove.hpp" #include "world/ProcessorObjectMove.hpp"
#include "world/ProcessorObjectPlace.hpp" #include "world/ProcessorObjectPlace.hpp"
#include "world/ProcessorObjectReset.hpp"
#include "world/ProcessorObjectRotate.hpp" #include "world/ProcessorObjectRotate.hpp"
#include "world/ProcessorObjectScale.hpp" #include "world/ProcessorObjectScale.hpp"
#include "world/ProcessorObjectSpawn.hpp" #include "world/ProcessorObjectSpawn.hpp"
@ -65,7 +73,9 @@
#include "world/ProcessorScriptLocalShort.hpp" #include "world/ProcessorScriptLocalShort.hpp"
#include "world/ProcessorScriptLocalFloat.hpp" #include "world/ProcessorScriptLocalFloat.hpp"
#include "world/ProcessorScriptMemberShort.hpp" #include "world/ProcessorScriptMemberShort.hpp"
#include "world/ProcessorScriptMemberFloat.hpp"
#include "world/ProcessorScriptGlobalShort.hpp" #include "world/ProcessorScriptGlobalShort.hpp"
#include "world/ProcessorScriptGlobalFloat.hpp"
#include "world/ProcessorVideoPlay.hpp" #include "world/ProcessorVideoPlay.hpp"
#include "actor/ProcessorActorAI.hpp" #include "actor/ProcessorActorAI.hpp"
@ -76,6 +86,7 @@
#include "actor/ProcessorActorCellChange.hpp" #include "actor/ProcessorActorCellChange.hpp"
#include "actor/ProcessorActorDeath.hpp" #include "actor/ProcessorActorDeath.hpp"
#include "actor/ProcessorActorEquipment.hpp" #include "actor/ProcessorActorEquipment.hpp"
#include "actor/ProcessorActorInteraction.hpp"
#include "actor/ProcessorActorList.hpp" #include "actor/ProcessorActorList.hpp"
#include "actor/ProcessorActorPosition.hpp" #include "actor/ProcessorActorPosition.hpp"
#include "actor/ProcessorActorSpeech.hpp" #include "actor/ProcessorActorSpeech.hpp"
@ -91,33 +102,39 @@ void ProcessorInitializer()
PlayerProcessor::AddProcessor(new ProcessorGUIWindow()); PlayerProcessor::AddProcessor(new ProcessorGUIWindow());
PlayerProcessor::AddProcessor(new ProcessorHandshake()); PlayerProcessor::AddProcessor(new ProcessorHandshake());
PlayerProcessor::AddProcessor(new ProcessorUserDisconnected()); PlayerProcessor::AddProcessor(new ProcessorUserDisconnected());
PlayerProcessor::AddProcessor(new ProcessorCellCreate());
PlayerProcessor::AddProcessor(new ProcessorRecordDynamic());
PlayerProcessor::AddProcessor(new ProcessorGameSettings()); PlayerProcessor::AddProcessor(new ProcessorGameSettings());
PlayerProcessor::AddProcessor(new ProcessorGameTime()); PlayerProcessor::AddProcessor(new ProcessorGameTime());
PlayerProcessor::AddProcessor(new ProcessorGameWeather()); PlayerProcessor::AddProcessor(new ProcessorGameWeather());
PlayerProcessor::AddProcessor(new ProcessorPlayerBaseInfo());
PlayerProcessor::AddProcessor(new ProcessorPlayerCharGen());
PlayerProcessor::AddProcessor(new ProcessorPlayerAnimFlags()); PlayerProcessor::AddProcessor(new ProcessorPlayerAnimFlags());
PlayerProcessor::AddProcessor(new ProcessorPlayerAnimPlay()); PlayerProcessor::AddProcessor(new ProcessorPlayerAnimPlay());
PlayerProcessor::AddProcessor(new ProcessorPlayerAttack()); PlayerProcessor::AddProcessor(new ProcessorPlayerAttack());
PlayerProcessor::AddProcessor(new ProcessorPlayerAttribute()); PlayerProcessor::AddProcessor(new ProcessorPlayerAttribute());
PlayerProcessor::AddProcessor(new ProcessorPlayerBaseInfo());
PlayerProcessor::AddProcessor(new ProcessorPlayerBehavior());
PlayerProcessor::AddProcessor(new ProcessorPlayerBook()); PlayerProcessor::AddProcessor(new ProcessorPlayerBook());
PlayerProcessor::AddProcessor(new ProcessorPlayerBounty()); PlayerProcessor::AddProcessor(new ProcessorPlayerBounty());
PlayerProcessor::AddProcessor(new ProcessorPlayerCellChange()); PlayerProcessor::AddProcessor(new ProcessorPlayerCellChange());
PlayerProcessor::AddProcessor(new ProcessorPlayerCellState()); PlayerProcessor::AddProcessor(new ProcessorPlayerCellState());
PlayerProcessor::AddProcessor(new ProcessorPlayerCharClass()); PlayerProcessor::AddProcessor(new ProcessorPlayerCharClass());
PlayerProcessor::AddProcessor(new ProcessorPlayerCharGen());
PlayerProcessor::AddProcessor(new ProcessorPlayerDeath()); PlayerProcessor::AddProcessor(new ProcessorPlayerDeath());
PlayerProcessor::AddProcessor(new ProcessorPlayerDisposition()); PlayerProcessor::AddProcessor(new ProcessorPlayerDisposition());
PlayerProcessor::AddProcessor(new ProcessorPlayerEquipment()); PlayerProcessor::AddProcessor(new ProcessorPlayerEquipment());
PlayerProcessor::AddProcessor(new ProcessorPlayerFaction()); PlayerProcessor::AddProcessor(new ProcessorPlayerFaction());
PlayerProcessor::AddProcessor(new ProcessorPlayerInteraction());
PlayerProcessor::AddProcessor(new ProcessorPlayerInventory()); PlayerProcessor::AddProcessor(new ProcessorPlayerInventory());
PlayerProcessor::AddProcessor(new ProcessorPlayerJail()); PlayerProcessor::AddProcessor(new ProcessorPlayerJail());
PlayerProcessor::AddProcessor(new ProcessorPlayerJournal()); PlayerProcessor::AddProcessor(new ProcessorPlayerJournal());
PlayerProcessor::AddProcessor(new ProcessorPlayerKillCount()); PlayerProcessor::AddProcessor(new ProcessorPlayerKillCount());
PlayerProcessor::AddProcessor(new ProcessorPlayerLevel()); PlayerProcessor::AddProcessor(new ProcessorPlayerLevel());
PlayerProcessor::AddProcessor(new ProcessorPlayerMap()); PlayerProcessor::AddProcessor(new ProcessorPlayerMap());
PlayerProcessor::AddProcessor(new ProcessorPlayerMiscellaneous());
PlayerProcessor::AddProcessor(new ProcessorPlayerPosition()); PlayerProcessor::AddProcessor(new ProcessorPlayerPosition());
PlayerProcessor::AddProcessor(new ProcessorPlayerQuickKeys()); PlayerProcessor::AddProcessor(new ProcessorPlayerQuickKeys());
PlayerProcessor::AddProcessor(new ProcessorPlayerRegionAuthority()); PlayerProcessor::AddProcessor(new ProcessorPlayerRegionAuthority());
PlayerProcessor::AddProcessor(new ProcessorPlayerReputation());
PlayerProcessor::AddProcessor(new ProcessorPlayerRest()); PlayerProcessor::AddProcessor(new ProcessorPlayerRest());
PlayerProcessor::AddProcessor(new ProcessorPlayerResurrect()); PlayerProcessor::AddProcessor(new ProcessorPlayerResurrect());
PlayerProcessor::AddProcessor(new ProcessorPlayerShapeshift()); PlayerProcessor::AddProcessor(new ProcessorPlayerShapeshift());
@ -129,6 +146,7 @@ void ProcessorInitializer()
WorldProcessor::AddProcessor(new ProcessorConsoleCommand()); WorldProcessor::AddProcessor(new ProcessorConsoleCommand());
WorldProcessor::AddProcessor(new ProcessorContainer()); WorldProcessor::AddProcessor(new ProcessorContainer());
WorldProcessor::AddProcessor(new ProcessorDoorDestination());
WorldProcessor::AddProcessor(new ProcessorDoorState()); WorldProcessor::AddProcessor(new ProcessorDoorState());
WorldProcessor::AddProcessor(new ProcessorMusicPlay()); WorldProcessor::AddProcessor(new ProcessorMusicPlay());
WorldProcessor::AddProcessor(new ProcessorObjectAnimPlay()); WorldProcessor::AddProcessor(new ProcessorObjectAnimPlay());
@ -136,6 +154,7 @@ void ProcessorInitializer()
WorldProcessor::AddProcessor(new ProcessorObjectLock()); WorldProcessor::AddProcessor(new ProcessorObjectLock());
WorldProcessor::AddProcessor(new ProcessorObjectMove()); WorldProcessor::AddProcessor(new ProcessorObjectMove());
WorldProcessor::AddProcessor(new ProcessorObjectPlace()); WorldProcessor::AddProcessor(new ProcessorObjectPlace());
WorldProcessor::AddProcessor(new ProcessorObjectReset());
WorldProcessor::AddProcessor(new ProcessorObjectRotate()); WorldProcessor::AddProcessor(new ProcessorObjectRotate());
WorldProcessor::AddProcessor(new ProcessorObjectScale()); WorldProcessor::AddProcessor(new ProcessorObjectScale());
WorldProcessor::AddProcessor(new ProcessorObjectSpawn()); WorldProcessor::AddProcessor(new ProcessorObjectSpawn());
@ -144,7 +163,9 @@ void ProcessorInitializer()
WorldProcessor::AddProcessor(new ProcessorScriptLocalShort()); WorldProcessor::AddProcessor(new ProcessorScriptLocalShort());
WorldProcessor::AddProcessor(new ProcessorScriptLocalFloat()); WorldProcessor::AddProcessor(new ProcessorScriptLocalFloat());
WorldProcessor::AddProcessor(new ProcessorScriptMemberShort()); WorldProcessor::AddProcessor(new ProcessorScriptMemberShort());
WorldProcessor::AddProcessor(new ProcessorScriptMemberFloat());
WorldProcessor::AddProcessor(new ProcessorScriptGlobalShort()); WorldProcessor::AddProcessor(new ProcessorScriptGlobalShort());
WorldProcessor::AddProcessor(new ProcessorScriptGlobalFloat());
WorldProcessor::AddProcessor(new ProcessorVideoPlay()); WorldProcessor::AddProcessor(new ProcessorVideoPlay());
ActorProcessor::AddProcessor(new ProcessorActorAI()); ActorProcessor::AddProcessor(new ProcessorActorAI());
@ -155,6 +176,7 @@ void ProcessorInitializer()
ActorProcessor::AddProcessor(new ProcessorActorCellChange()); ActorProcessor::AddProcessor(new ProcessorActorCellChange());
ActorProcessor::AddProcessor(new ProcessorActorDeath()); ActorProcessor::AddProcessor(new ProcessorActorDeath());
ActorProcessor::AddProcessor(new ProcessorActorEquipment()); ActorProcessor::AddProcessor(new ProcessorActorEquipment());
ActorProcessor::AddProcessor(new ProcessorActorInteraction());
ActorProcessor::AddProcessor(new ProcessorActorList()); ActorProcessor::AddProcessor(new ProcessorActorList());
ActorProcessor::AddProcessor(new ProcessorActorPosition()); ActorProcessor::AddProcessor(new ProcessorActorPosition());
ActorProcessor::AddProcessor(new ProcessorActorSpeech()); ActorProcessor::AddProcessor(new ProcessorActorSpeech());

@ -0,0 +1,25 @@
#ifndef OPENMW_PROCESSORACTORINTERACTION_HPP
#define OPENMW_PROCESSORACTORINTERACTION_HPP
#include "../ActorProcessor.hpp"
#include "apps/openmw/mwmp/Main.hpp"
#include "apps/openmw/mwmp/CellController.hpp"
namespace mwmp
{
class ProcessorActorInteraction final: public ActorProcessor
{
public:
ProcessorActorInteraction()
{
BPP_INIT(ID_ACTOR_INTERACTION);
}
virtual void Do(ActorPacket &packet, ActorList &actorList)
{
//Main::get().getCellController()->readInteraction(actorList);
}
};
}
#endif //OPENMW_PROCESSORACTORINTERACTION_HPP

@ -0,0 +1,23 @@
#ifndef OPENMW_PROCESSORCELLCREATE_HPP
#define OPENMW_PROCESSORCELLCREATE_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorCellCreate final: public PlayerProcessor
{
public:
ProcessorCellCreate()
{
BPP_INIT(ID_CELL_CREATE)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
// Placeholder
}
};
}
#endif //OPENMW_PROCESSORCELLCREATE_HPP

@ -1,19 +1,9 @@
//
// Created by koncord on 16.04.17.
//
#ifndef OPENMW_PROCESSORPLAYERATTACK_HPP #ifndef OPENMW_PROCESSORPLAYERATTACK_HPP
#define OPENMW_PROCESSORPLAYERATTACK_HPP #define OPENMW_PROCESSORPLAYERATTACK_HPP
#include "apps/openmw/mwmp/Main.hpp" #include "apps/openmw/mwmp/Main.hpp"
#include "../PlayerProcessor.hpp" #include "../PlayerProcessor.hpp"
#include "apps/openmw/mwmp/MechanicsHelper.hpp" #include "apps/openmw/mwmp/MechanicsHelper.hpp"
#include "apps/openmw/mwbase/world.hpp"
#include "apps/openmw/mwworld/containerstore.hpp"
#include "apps/openmw/mwworld/inventorystore.hpp"
#include "apps/openmw/mwmechanics/combat.hpp"
#include "apps/openmw/mwbase/environment.hpp"
namespace mwmp namespace mwmp
{ {

@ -0,0 +1,30 @@
#ifndef OPENMW_PROCESSORPLAYERBEHAVIOR_HPP
#define OPENMW_PROCESSORPLAYERBEHAVIOR_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerBehavior final: public PlayerProcessor
{
public:
ProcessorPlayerBehavior()
{
BPP_INIT(ID_PLAYER_BEHAVIOR)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
if (isLocal())
{
//static_cast<LocalPlayer *>(player)->setBehavior();
}
else if (player != 0)
{
//static_cast<DedicatedPlayer *>(player)->setBehavior();
}
}
};
}
#endif //OPENMW_PROCESSORPLAYERBEHAVIOR_HPP

@ -0,0 +1,27 @@
#ifndef OPENMW_PROCESSORPLAYERINTERACTION_HPP
#define OPENMW_PROCESSORPLAYERINTERACTION_HPP
#include "apps/openmw/mwmp/Main.hpp"
#include "../PlayerProcessor.hpp"
#include "apps/openmw/mwmp/MechanicsHelper.hpp"
namespace mwmp
{
class ProcessorPlayerInteraction final: public PlayerProcessor
{
public:
ProcessorPlayerInteraction()
{
BPP_INIT(ID_PLAYER_INTERACTION)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
//if (player != 0)
// MechanicsHelper::processInteraction(player->interaction, static_cast<DedicatedPlayer*>(player)->getPtr());
}
};
}
#endif //OPENMW_PROCESSORPLAYERINTERACTION_HPP

@ -1,7 +1,3 @@
//
// Created by koncord on 16.04.17.
//
#ifndef OPENMW_PROCESSORPLAYERLEVEL_HPP #ifndef OPENMW_PROCESSORPLAYERLEVEL_HPP
#define OPENMW_PROCESSORPLAYERLEVEL_HPP #define OPENMW_PROCESSORPLAYERLEVEL_HPP

@ -0,0 +1,32 @@
#ifndef OPENMW_PROCESSORPLAYERMISCELLANEOUS_HPP
#define OPENMW_PROCESSORPLAYERMISCELLANEOUS_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerMiscellaneous final: public PlayerProcessor
{
public:
ProcessorPlayerMiscellaneous()
{
BPP_INIT(ID_PLAYER_MISCELLANEOUS)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
if (!isLocal()) return;
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received ID_PLAYER_MISCELLANEOUS about LocalPlayer from server");
if (!isRequest())
{
LocalPlayer &localPlayer = static_cast<LocalPlayer&>(*player);
//localPlayer.setMiscellaneous();
}
}
};
}
#endif //OPENMW_PROCESSORPLAYERMISCELLANEOUS_HPP

@ -6,7 +6,7 @@
namespace mwmp namespace mwmp
{ {
class ProcessorPlayerQuickKeys : public PlayerProcessor class ProcessorPlayerQuickKeys final: public PlayerProcessor
{ {
public: public:
ProcessorPlayerQuickKeys() ProcessorPlayerQuickKeys()

@ -0,0 +1,38 @@
#ifndef OPENMW_PROCESSORPLAYERREPUTATION_HPP
#define OPENMW_PROCESSORPLAYERREPUTATION_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorPlayerReputation final: public PlayerProcessor
{
public:
ProcessorPlayerReputation()
{
BPP_INIT(ID_PLAYER_REPUTATION)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
if (isLocal())
{
//if (isRequest())
// static_cast<LocalPlayer *>(player)->updateReputation(true);
//else
// static_cast<LocalPlayer *>(player)->setReputation();
}
else if (player != 0)
{
MWWorld::Ptr ptrPlayer = static_cast<DedicatedPlayer *>(player)->getPtr();
MWMechanics::NpcStats *ptrNpcStats = &ptrPlayer.getClass().getNpcStats(ptrPlayer);
ptrNpcStats->setReputation(player->npcStats.mReputation);
}
}
};
}
#endif //OPENMW_PROCESSORPLAYERREPUTATION_HPP

@ -0,0 +1,23 @@
#ifndef OPENMW_PROCESSORRECORDDYNAMIC_HPP
#define OPENMW_PROCESSORRECORDDYNAMIC_HPP
#include "../PlayerProcessor.hpp"
namespace mwmp
{
class ProcessorRecordDynamic final: public PlayerProcessor
{
public:
ProcessorRecordDynamic()
{
BPP_INIT(ID_RECORD_DYNAMIC)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
// Placeholder
}
};
}
#endif //OPENMW_PROCESSORRECORDDYNAMIC_HPP

@ -0,0 +1,25 @@
#ifndef OPENMW_PROCESSDOORDESTINATION_HPP
#define OPENMW_PROCESSDOORDESTINATION_HPP
#include "BaseObjectProcessor.hpp"
namespace mwmp
{
class ProcessorDoorDestination final : public BaseObjectProcessor
{
public:
ProcessorDoorDestination()
{
BPP_INIT(ID_DOOR_DESTINATION)
}
virtual void Do(WorldPacket &packet, WorldEvent &event)
{
BaseObjectProcessor::Do(packet, event);
//event.setDoorDestinations(ptrCellStore);
}
};
}
#endif //OPENMW_PROCESSDOORDESTINATION_HPP

@ -0,0 +1,26 @@
#ifndef OPENMW_PROCESSOROBJECTRESET_HPP
#define OPENMW_PROCESSOROBJECTRESET_HPP
#include "BaseObjectProcessor.hpp"
namespace mwmp
{
class ProcessorObjectReset : public BaseObjectProcessor
{
public:
ProcessorObjectReset()
{
BPP_INIT(ID_OBJECT_RESET)
}
virtual void Do(WorldPacket &packet, WorldEvent &event)
{
BaseObjectProcessor::Do(packet, event);
//event.resetObjects(ptrCellStore);
}
};
}
#endif //OPENMW_PROCESSOROBJECTRESET_HPP

@ -0,0 +1,24 @@
#ifndef OPENMW_PROCESSORSCRIPTGLOBALFLOAT_HPP
#define OPENMW_PROCESSORSCRIPTGLOBALFLOAT_HPP
#include "../WorldProcessor.hpp"
namespace mwmp
{
class ProcessorScriptGlobalFloat final: public WorldProcessor
{
public:
ProcessorScriptGlobalFloat()
{
BPP_INIT(ID_SCRIPT_GLOBAL_FLOAT)
}
virtual void Do(WorldPacket &packet, WorldEvent &event)
{
LOG_MESSAGE_SIMPLE(Log::LOG_VERBOSE, "Received %s", strPacketID.c_str());
//event.setGlobalFloats();
}
};
}
#endif //OPENMW_PROCESSORSCRIPTGLOBALFLOAT_HPP

@ -5,7 +5,7 @@
namespace mwmp namespace mwmp
{ {
class ProcessorScriptLocalFloat : public BaseObjectProcessor class ProcessorScriptLocalFloat final: public BaseObjectProcessor
{ {
public: public:
ProcessorScriptLocalFloat() ProcessorScriptLocalFloat()

@ -5,7 +5,7 @@
namespace mwmp namespace mwmp
{ {
class ProcessorScriptLocalShort : public BaseObjectProcessor class ProcessorScriptLocalShort final: public BaseObjectProcessor
{ {
public: public:
ProcessorScriptLocalShort() ProcessorScriptLocalShort()

@ -0,0 +1,24 @@
#ifndef OPENMW_PROCESSORSCRIPTMEMBERFLOAT_HPP
#define OPENMW_PROCESSORSCRIPTMEMBERFLOAT_HPP
#include "../WorldProcessor.hpp"
namespace mwmp
{
class ProcessorScriptMemberFloat final: public WorldProcessor
{
public:
ProcessorScriptMemberFloat()
{
BPP_INIT(ID_SCRIPT_MEMBER_FLOAT)
}
virtual void Do(WorldPacket &packet, WorldEvent &event)
{
LOG_MESSAGE_SIMPLE(Log::LOG_VERBOSE, "Received %s", strPacketID.c_str());
//event.setMemberFloats();
}
};
}
#endif //OPENMW_PROCESSORSCRIPTMEMBERFLOAT_HPP

@ -176,27 +176,33 @@ add_component_dir (openmw-mp/Packets
add_component_dir (openmw-mp/Packets/Actor add_component_dir (openmw-mp/Packets/Actor
ActorPacket ActorPacket
PacketActorList PacketActorAuthority PacketActorTest PacketActorAI PacketActorAnimFlags PacketActorAnimPlay PacketActorList PacketActorAuthority PacketActorTest PacketActorAI PacketActorAnimFlags PacketActorAnimPlay
PacketActorAttack PacketActorCellChange PacketActorDeath PacketActorEquipment PacketActorPosition PacketActorSpeech PacketActorAttack PacketActorCellChange PacketActorDeath PacketActorEquipment PacketActorInteraction PacketActorPosition
PacketActorStatsDynamic PacketActorSpeech PacketActorStatsDynamic
) )
add_component_dir (openmw-mp/Packets/Player add_component_dir (openmw-mp/Packets/Player
PlayerPacket PlayerPacket
PacketHandshake PacketChatMessage PacketGUIBoxes PacketGameSettings PacketGameTime PacketGameWeather PacketHandshake PacketChatMessage PacketGUIBoxes PacketGUIWindow PacketGameSettings PacketGameTime
PacketGameWeather
PacketCellCreate PacketRecordDynamic
PacketPlayerBaseInfo PacketPlayerCharGen PacketPlayerActiveSkills PacketPlayerAnimFlags PacketPlayerAnimPlay PacketPlayerBaseInfo PacketPlayerCharGen PacketPlayerActiveSkills PacketPlayerAnimFlags PacketPlayerAnimPlay
PacketPlayerAttack PacketPlayerAttribute PacketPlayerBook PacketPlayerBounty PacketPlayerCellChange PacketPlayerAttack PacketPlayerAttribute PacketPlayerBehavior PacketPlayerBook PacketPlayerBounty PacketPlayerCellChange
PacketPlayerCellState PacketPlayerClass PacketPlayerDeath PacketPlayerEquipment PacketPlayerFaction PacketPlayerCellState PacketPlayerClass PacketPlayerDeath PacketPlayerEquipment PacketPlayerFaction
PacketPlayerInventory PacketPlayerJail PacketPlayerJournal PacketPlayerKillCount PacketPlayerLevel PacketPlayerInteraction PacketPlayerInventory PacketPlayerJail PacketPlayerJournal PacketPlayerKillCount PacketPlayerLevel
PacketPlayerMap PacketPlayerPosition PacketPlayerQuickKeys PacketPlayerRegionAuthority PacketPlayerRest PacketPlayerMap PacketPlayerMiscellaneous PacketPlayerPosition PacketPlayerQuickKeys PacketPlayerRegionAuthority
PacketPlayerResurrect PacketPlayerShapeshift PacketPlayerSkill PacketPlayerSpeech PacketPlayerSpellbook PacketPlayerStatsDynamic PacketPlayerTopic PacketGUIWindow PacketPlayerReputation PacketPlayerRest PacketPlayerResurrect PacketPlayerShapeshift PacketPlayerSkill PacketPlayerSpeech
PacketPlayerSpellbook PacketPlayerStatsDynamic PacketPlayerTopic
) )
add_component_dir (openmw-mp/Packets/World add_component_dir (openmw-mp/Packets/World
WorldPacket WorldPacket
PacketConsoleCommand PacketContainer PacketObjectAnimPlay PacketObjectDelete PacketDoorState PacketObjectLock PacketConsoleCommand PacketContainer PacketObjectAnimPlay PacketObjectDelete PacketDoorDestination
PacketObjectMove PacketObjectPlace PacketObjectRotate PacketObjectScale PacketObjectSpawn PacketObjectState PacketDoorState PacketObjectLock PacketObjectMove PacketObjectPlace PacketObjectReset PacketObjectRotate
PacketObjectTrap PacketMusicPlay PacketVideoPlay PacketScriptLocalShort PacketScriptLocalFloat PacketObjectScale PacketObjectSpawn PacketObjectState PacketObjectTrap PacketMusicPlay PacketVideoPlay
PacketScriptMemberShort PacketScriptGlobalShort PacketScriptLocalShort PacketScriptLocalFloat PacketScriptMemberShort PacketScriptMemberFloat PacketScriptGlobalShort
PacketScriptGlobalFloat
) )
add_component_dir (fallback add_component_dir (fallback

@ -8,6 +8,7 @@
#include "../Packets/Actor/PacketActorCellChange.hpp" #include "../Packets/Actor/PacketActorCellChange.hpp"
#include "../Packets/Actor/PacketActorDeath.hpp" #include "../Packets/Actor/PacketActorDeath.hpp"
#include "../Packets/Actor/PacketActorEquipment.hpp" #include "../Packets/Actor/PacketActorEquipment.hpp"
#include "../Packets/Actor/PacketActorInteraction.hpp"
#include "../Packets/Actor/PacketActorPosition.hpp" #include "../Packets/Actor/PacketActorPosition.hpp"
#include "../Packets/Actor/PacketActorStatsDynamic.hpp" #include "../Packets/Actor/PacketActorStatsDynamic.hpp"
#include "../Packets/Actor/PacketActorSpeech.hpp" #include "../Packets/Actor/PacketActorSpeech.hpp"
@ -36,6 +37,7 @@ mwmp::ActorPacketController::ActorPacketController(RakNet::RakPeerInterface *pee
AddPacket<PacketActorCellChange>(&packets, peer); AddPacket<PacketActorCellChange>(&packets, peer);
AddPacket<PacketActorDeath>(&packets, peer); AddPacket<PacketActorDeath>(&packets, peer);
AddPacket<PacketActorEquipment>(&packets, peer); AddPacket<PacketActorEquipment>(&packets, peer);
AddPacket<PacketActorInteraction>(&packets, peer);
AddPacket<PacketActorPosition>(&packets, peer); AddPacket<PacketActorPosition>(&packets, peer);
AddPacket<PacketActorSpeech>(&packets, peer); AddPacket<PacketActorSpeech>(&packets, peer);
AddPacket<PacketActorStatsDynamic>(&packets, peer); AddPacket<PacketActorStatsDynamic>(&packets, peer);

@ -5,15 +5,18 @@
#include "../Packets/Player/PacketGUIBoxes.hpp" #include "../Packets/Player/PacketGUIBoxes.hpp"
#include "../Packets/Player/PacketGUIWindow.hpp" #include "../Packets/Player/PacketGUIWindow.hpp"
#include "../Packets/Player/PacketLoaded.hpp" #include "../Packets/Player/PacketLoaded.hpp"
#include "../Packets/Player/PacketCellCreate.hpp"
#include "../Packets/Player/PacketRecordDynamic.hpp"
#include "../Packets/Player/PacketGameSettings.hpp" #include "../Packets/Player/PacketGameSettings.hpp"
#include "../Packets/Player/PacketGameTime.hpp" #include "../Packets/Player/PacketGameTime.hpp"
#include "../Packets/Player/PacketGameWeather.hpp" #include "../Packets/Player/PacketGameWeather.hpp"
#include "../Packets/Player/PacketPlayerActiveSkills.hpp" #include "../Packets/Player/PacketPlayerActiveSkills.hpp"
#include "../Packets/Player/PacketPlayerBaseInfo.hpp"
#include "../Packets/Player/PacketPlayerAnimFlags.hpp" #include "../Packets/Player/PacketPlayerAnimFlags.hpp"
#include "../Packets/Player/PacketPlayerAnimPlay.hpp" #include "../Packets/Player/PacketPlayerAnimPlay.hpp"
#include "../Packets/Player/PacketPlayerAttack.hpp" #include "../Packets/Player/PacketPlayerAttack.hpp"
#include "../Packets/Player/PacketPlayerAttribute.hpp" #include "../Packets/Player/PacketPlayerAttribute.hpp"
#include "../Packets/Player/PacketPlayerBaseInfo.hpp"
#include "../Packets/Player/PacketPlayerBehavior.hpp"
#include "../Packets/Player/PacketPlayerBook.hpp" #include "../Packets/Player/PacketPlayerBook.hpp"
#include "../Packets/Player/PacketPlayerBounty.hpp" #include "../Packets/Player/PacketPlayerBounty.hpp"
#include "../Packets/Player/PacketPlayerCellChange.hpp" #include "../Packets/Player/PacketPlayerCellChange.hpp"
@ -22,15 +25,18 @@
#include "../Packets/Player/PacketPlayerDeath.hpp" #include "../Packets/Player/PacketPlayerDeath.hpp"
#include "../Packets/Player/PacketPlayerEquipment.hpp" #include "../Packets/Player/PacketPlayerEquipment.hpp"
#include "../Packets/Player/PacketPlayerFaction.hpp" #include "../Packets/Player/PacketPlayerFaction.hpp"
#include "../Packets/Player/PacketPlayerInteraction.hpp"
#include "../Packets/Player/PacketPlayerInventory.hpp" #include "../Packets/Player/PacketPlayerInventory.hpp"
#include "../Packets/Player/PacketPlayerJail.hpp" #include "../Packets/Player/PacketPlayerJail.hpp"
#include "../Packets/Player/PacketPlayerJournal.hpp" #include "../Packets/Player/PacketPlayerJournal.hpp"
#include "../Packets/Player/PacketPlayerKillCount.hpp" #include "../Packets/Player/PacketPlayerKillCount.hpp"
#include "../Packets/Player/PacketPlayerLevel.hpp" #include "../Packets/Player/PacketPlayerLevel.hpp"
#include "../Packets/Player/PacketPlayerMap.hpp" #include "../Packets/Player/PacketPlayerMap.hpp"
#include "../Packets/Player/PacketPlayerMiscellaneous.hpp"
#include "../Packets/Player/PacketPlayerPosition.hpp" #include "../Packets/Player/PacketPlayerPosition.hpp"
#include "../Packets/Player/PacketPlayerQuickKeys.hpp" #include "../Packets/Player/PacketPlayerQuickKeys.hpp"
#include "../Packets/Player/PacketPlayerRegionAuthority.hpp" #include "../Packets/Player/PacketPlayerRegionAuthority.hpp"
#include "../Packets/Player/PacketPlayerReputation.hpp"
#include "../Packets/Player/PacketPlayerRest.hpp" #include "../Packets/Player/PacketPlayerRest.hpp"
#include "../Packets/Player/PacketPlayerResurrect.hpp" #include "../Packets/Player/PacketPlayerResurrect.hpp"
#include "../Packets/Player/PacketPlayerShapeshift.hpp" #include "../Packets/Player/PacketPlayerShapeshift.hpp"
@ -59,34 +65,40 @@ mwmp::PlayerPacketController::PlayerPacketController(RakNet::RakPeerInterface *p
AddPacket<PacketGUIBoxes>(&packets, peer); AddPacket<PacketGUIBoxes>(&packets, peer);
AddPacket<PacketGUIWindow>(&packets, peer); AddPacket<PacketGUIWindow>(&packets, peer);
AddPacket<PacketLoaded>(&packets, peer); AddPacket<PacketLoaded>(&packets, peer);
AddPacket<PacketCellCreate>(&packets, peer);
AddPacket<PacketRecordDynamic>(&packets, peer);
AddPacket<PacketGameSettings>(&packets, peer); AddPacket<PacketGameSettings>(&packets, peer);
AddPacket<PacketGameTime>(&packets, peer); AddPacket<PacketGameTime>(&packets, peer);
AddPacket<PacketGameWeather>(&packets, peer); AddPacket<PacketGameWeather>(&packets, peer);
AddPacket<PacketPlayerActiveSkills>(&packets, peer); AddPacket<PacketPlayerActiveSkills>(&packets, peer);
AddPacket<PacketPlayerBaseInfo>(&packets, peer);
AddPacket<PacketPlayerCharGen>(&packets, peer);
AddPacket<PacketPlayerAnimFlags>(&packets, peer); AddPacket<PacketPlayerAnimFlags>(&packets, peer);
AddPacket<PacketPlayerAnimPlay>(&packets, peer); AddPacket<PacketPlayerAnimPlay>(&packets, peer);
AddPacket<PacketPlayerAttack>(&packets, peer); AddPacket<PacketPlayerAttack>(&packets, peer);
AddPacket<PacketPlayerAttribute>(&packets, peer); AddPacket<PacketPlayerAttribute>(&packets, peer);
AddPacket<PacketPlayerBaseInfo>(&packets, peer);
AddPacket<PacketPlayerBehavior>(&packets, peer);
AddPacket<PacketPlayerBook>(&packets, peer); AddPacket<PacketPlayerBook>(&packets, peer);
AddPacket<PacketPlayerBounty>(&packets, peer); AddPacket<PacketPlayerBounty>(&packets, peer);
AddPacket<PacketPlayerCellChange>(&packets, peer); AddPacket<PacketPlayerCellChange>(&packets, peer);
AddPacket<PacketPlayerCellState>(&packets, peer); AddPacket<PacketPlayerCellState>(&packets, peer);
AddPacket<PacketPlayerCharGen>(&packets, peer);
AddPacket<PacketPlayerClass>(&packets, peer); AddPacket<PacketPlayerClass>(&packets, peer);
AddPacket<PacketPlayerDeath>(&packets, peer); AddPacket<PacketPlayerDeath>(&packets, peer);
AddPacket<PacketPlayerEquipment>(&packets, peer); AddPacket<PacketPlayerEquipment>(&packets, peer);
AddPacket<PacketPlayerFaction>(&packets, peer); AddPacket<PacketPlayerFaction>(&packets, peer);
AddPacket<PacketPlayerInteraction>(&packets, peer);
AddPacket<PacketPlayerInventory>(&packets, peer); AddPacket<PacketPlayerInventory>(&packets, peer);
AddPacket<PacketPlayerJail>(&packets, peer); AddPacket<PacketPlayerJail>(&packets, peer);
AddPacket<PacketPlayerJournal>(&packets, peer); AddPacket<PacketPlayerJournal>(&packets, peer);
AddPacket<PacketPlayerKillCount>(&packets, peer); AddPacket<PacketPlayerKillCount>(&packets, peer);
AddPacket<PacketPlayerLevel>(&packets, peer); AddPacket<PacketPlayerLevel>(&packets, peer);
AddPacket<PacketPlayerMap>(&packets, peer); AddPacket<PacketPlayerMap>(&packets, peer);
AddPacket<PacketPlayerMiscellaneous>(&packets, peer);
AddPacket<PacketPlayerPosition>(&packets, peer); AddPacket<PacketPlayerPosition>(&packets, peer);
AddPacket<PacketPlayerQuickKeys>(&packets, peer); AddPacket<PacketPlayerQuickKeys>(&packets, peer);
AddPacket<PacketPlayerRegionAuthority>(&packets, peer); AddPacket<PacketPlayerRegionAuthority>(&packets, peer);
AddPacket<PacketPlayerReputation>(&packets, peer);
AddPacket<PacketPlayerRest>(&packets, peer); AddPacket<PacketPlayerRest>(&packets, peer);
AddPacket<PacketPlayerResurrect>(&packets, peer); AddPacket<PacketPlayerResurrect>(&packets, peer);
AddPacket<PacketPlayerShapeshift>(&packets, peer); AddPacket<PacketPlayerShapeshift>(&packets, peer);

@ -3,6 +3,7 @@
#include "../Packets/World/PacketObjectLock.hpp" #include "../Packets/World/PacketObjectLock.hpp"
#include "../Packets/World/PacketObjectMove.hpp" #include "../Packets/World/PacketObjectMove.hpp"
#include "../Packets/World/PacketObjectPlace.hpp" #include "../Packets/World/PacketObjectPlace.hpp"
#include "../Packets/World/PacketObjectReset.hpp"
#include "../Packets/World/PacketObjectRotate.hpp" #include "../Packets/World/PacketObjectRotate.hpp"
#include "../Packets/World/PacketObjectScale.hpp" #include "../Packets/World/PacketObjectScale.hpp"
#include "../Packets/World/PacketObjectSpawn.hpp" #include "../Packets/World/PacketObjectSpawn.hpp"
@ -10,6 +11,7 @@
#include "../Packets/World/PacketObjectTrap.hpp" #include "../Packets/World/PacketObjectTrap.hpp"
#include "../Packets/World/PacketContainer.hpp" #include "../Packets/World/PacketContainer.hpp"
#include "../Packets/World/PacketDoorDestination.hpp"
#include "../Packets/World/PacketDoorState.hpp" #include "../Packets/World/PacketDoorState.hpp"
#include "../Packets/World/PacketMusicPlay.hpp" #include "../Packets/World/PacketMusicPlay.hpp"
#include "../Packets/World/PacketVideoPlay.hpp" #include "../Packets/World/PacketVideoPlay.hpp"
@ -18,7 +20,9 @@
#include "../Packets/World/PacketScriptLocalShort.hpp" #include "../Packets/World/PacketScriptLocalShort.hpp"
#include "../Packets/World/PacketScriptLocalFloat.hpp" #include "../Packets/World/PacketScriptLocalFloat.hpp"
#include "../Packets/World/PacketScriptMemberShort.hpp" #include "../Packets/World/PacketScriptMemberShort.hpp"
#include "../Packets/World/PacketScriptMemberFloat.hpp"
#include "../Packets/World/PacketScriptGlobalShort.hpp" #include "../Packets/World/PacketScriptGlobalShort.hpp"
#include "../Packets/World/PacketScriptGlobalFloat.hpp"
#include "WorldPacketController.hpp" #include "WorldPacketController.hpp"
@ -38,6 +42,7 @@ mwmp::WorldPacketController::WorldPacketController(RakNet::RakPeerInterface *pee
AddPacket<PacketObjectLock>(&packets, peer); AddPacket<PacketObjectLock>(&packets, peer);
AddPacket<PacketObjectMove>(&packets, peer); AddPacket<PacketObjectMove>(&packets, peer);
AddPacket<PacketObjectPlace>(&packets, peer); AddPacket<PacketObjectPlace>(&packets, peer);
AddPacket<PacketObjectReset>(&packets, peer);
AddPacket<PacketObjectRotate>(&packets, peer); AddPacket<PacketObjectRotate>(&packets, peer);
AddPacket<PacketObjectScale>(&packets, peer); AddPacket<PacketObjectScale>(&packets, peer);
AddPacket<PacketObjectSpawn>(&packets, peer); AddPacket<PacketObjectSpawn>(&packets, peer);
@ -45,6 +50,7 @@ mwmp::WorldPacketController::WorldPacketController(RakNet::RakPeerInterface *pee
AddPacket<PacketObjectTrap>(&packets, peer); AddPacket<PacketObjectTrap>(&packets, peer);
AddPacket<PacketContainer>(&packets, peer); AddPacket<PacketContainer>(&packets, peer);
AddPacket<PacketDoorDestination>(&packets, peer);
AddPacket<PacketDoorState>(&packets, peer); AddPacket<PacketDoorState>(&packets, peer);
AddPacket<PacketMusicPlay>(&packets, peer); AddPacket<PacketMusicPlay>(&packets, peer);
AddPacket<PacketVideoPlay>(&packets, peer); AddPacket<PacketVideoPlay>(&packets, peer);
@ -53,7 +59,9 @@ mwmp::WorldPacketController::WorldPacketController(RakNet::RakPeerInterface *pee
AddPacket<PacketScriptLocalShort>(&packets, peer); AddPacket<PacketScriptLocalShort>(&packets, peer);
AddPacket<PacketScriptLocalFloat>(&packets, peer); AddPacket<PacketScriptLocalFloat>(&packets, peer);
AddPacket<PacketScriptMemberShort>(&packets, peer); AddPacket<PacketScriptMemberShort>(&packets, peer);
AddPacket<PacketScriptMemberFloat>(&packets, peer);
AddPacket<PacketScriptGlobalShort>(&packets, peer); AddPacket<PacketScriptGlobalShort>(&packets, peer);
AddPacket<PacketScriptGlobalFloat>(&packets, peer);
} }

@ -23,6 +23,7 @@ enum GameMessages
ID_GAME_WEATHER, ID_GAME_WEATHER,
ID_PLAYER_BASEINFO, ID_PLAYER_BASEINFO,
ID_PLAYER_BEHAVIOR,
ID_PLAYER_CHARGEN, ID_PLAYER_CHARGEN,
ID_PLAYER_ACTIVESKILLS, ID_PLAYER_ACTIVESKILLS,
ID_PLAYER_ANIM_FLAGS, ID_PLAYER_ANIM_FLAGS,
@ -38,15 +39,18 @@ enum GameMessages
ID_PLAYER_DISPOSITION, ID_PLAYER_DISPOSITION,
ID_PLAYER_EQUIPMENT, ID_PLAYER_EQUIPMENT,
ID_PLAYER_FACTION, ID_PLAYER_FACTION,
ID_PLAYER_INTERACTION,
ID_PLAYER_INVENTORY, ID_PLAYER_INVENTORY,
ID_PLAYER_JAIL, ID_PLAYER_JAIL,
ID_PLAYER_JOURNAL, ID_PLAYER_JOURNAL,
ID_PLAYER_KILL_COUNT, ID_PLAYER_KILL_COUNT,
ID_PLAYER_LEVEL, ID_PLAYER_LEVEL,
ID_PLAYER_MAP, ID_PLAYER_MAP,
ID_PLAYER_MISCELLANEOUS,
ID_PLAYER_POSITION, ID_PLAYER_POSITION,
ID_PLAYER_QUICKKEYS, ID_PLAYER_QUICKKEYS,
ID_PLAYER_REGION_AUTHORITY, ID_PLAYER_REGION_AUTHORITY,
ID_PLAYER_REPUTATION,
ID_PLAYER_RESURRECT, ID_PLAYER_RESURRECT,
ID_PLAYER_REST, ID_PLAYER_REST,
ID_PLAYER_SHAPESHIFT, ID_PLAYER_SHAPESHIFT,
@ -66,6 +70,7 @@ enum GameMessages
ID_ACTOR_CELL_CHANGE, ID_ACTOR_CELL_CHANGE,
ID_ACTOR_DEATH, ID_ACTOR_DEATH,
ID_ACTOR_EQUIPMENT, ID_ACTOR_EQUIPMENT,
ID_ACTOR_INTERACTION,
ID_ACTOR_POSITION, ID_ACTOR_POSITION,
ID_ACTOR_SPEECH, ID_ACTOR_SPEECH,
ID_ACTOR_STATS_DYNAMIC, ID_ACTOR_STATS_DYNAMIC,
@ -75,14 +80,19 @@ enum GameMessages
ID_OBJECT_LOCK, ID_OBJECT_LOCK,
ID_OBJECT_MOVE, ID_OBJECT_MOVE,
ID_OBJECT_PLACE, ID_OBJECT_PLACE,
ID_OBJECT_RESET,
ID_OBJECT_ROTATE, ID_OBJECT_ROTATE,
ID_OBJECT_SCALE, ID_OBJECT_SCALE,
ID_OBJECT_SPAWN, ID_OBJECT_SPAWN,
ID_OBJECT_STATE, ID_OBJECT_STATE,
ID_OBJECT_TRAP, ID_OBJECT_TRAP,
ID_CELL_CREATE,
ID_RECORD_DYNAMIC,
ID_CONSOLE_COMMAND, ID_CONSOLE_COMMAND,
ID_CONTAINER, ID_CONTAINER,
ID_DOOR_DESTINATION,
ID_DOOR_STATE, ID_DOOR_STATE,
ID_MUSIC_PLAY, ID_MUSIC_PLAY,
ID_VIDEO_PLAY, ID_VIDEO_PLAY,
@ -90,7 +100,9 @@ enum GameMessages
ID_SCRIPT_LOCAL_SHORT, ID_SCRIPT_LOCAL_SHORT,
ID_SCRIPT_LOCAL_FLOAT, ID_SCRIPT_LOCAL_FLOAT,
ID_SCRIPT_MEMBER_SHORT, ID_SCRIPT_MEMBER_SHORT,
ID_SCRIPT_MEMBER_FLOAT,
ID_SCRIPT_GLOBAL_SHORT, ID_SCRIPT_GLOBAL_SHORT,
ID_SCRIPT_GLOBAL_FLOAT,
ID_GAME_SETTINGS, ID_GAME_SETTINGS,
ID_GAME_PREINIT ID_GAME_PREINIT

@ -0,0 +1,15 @@
#include <components/openmw-mp/NetworkMessages.hpp>
#include <components/openmw-mp/Log.hpp>
#include "PacketActorInteraction.hpp"
using namespace mwmp;
PacketActorInteraction::PacketActorInteraction(RakNet::RakPeerInterface *peer) : ActorPacket(peer)
{
packetID = ID_ACTOR_INTERACTION;
}
void PacketActorInteraction::Actor(BaseActor &actor, bool send)
{
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETACTORINTERACTION_HPP
#define OPENMW_PACKETACTORINTERACTION_HPP
#include <components/openmw-mp/Packets/Actor/ActorPacket.hpp>
namespace mwmp
{
class PacketActorInteraction : public ActorPacket
{
public:
PacketActorInteraction(RakNet::RakPeerInterface *peer);
virtual void Actor(BaseActor &actor, bool send);
};
}
#endif //OPENMW_PACKETACTORINTERACTION_HPP

@ -0,0 +1,17 @@
#include "PacketCellCreate.hpp"
#include <components/openmw-mp/NetworkMessages.hpp>
using namespace mwmp;
PacketCellCreate::PacketCellCreate(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_CELL_CREATE;
orderChannel = CHANNEL_SYSTEM;
}
void PacketCellCreate::Packet(RakNet::BitStream *bs, bool send)
{
PlayerPacket::Packet(bs, send);
// Placeholder
}

@ -0,0 +1,18 @@
#ifndef OPENMW_PACKETCELLCREATE_HPP
#define OPENMW_PACKETCELLCREATE_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
#include <components/openmw-mp/NetworkMessages.hpp>
namespace mwmp
{
class PacketCellCreate: public PlayerPacket
{
public:
PacketCellCreate(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, bool send);
};
}
#endif //OPENMW_PACKETCELLCREATE_HPP

@ -0,0 +1,16 @@
#include "PacketPlayerBehavior.hpp"
#include <components/openmw-mp/NetworkMessages.hpp>
using namespace mwmp;
PacketPlayerBehavior::PacketPlayerBehavior(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_PLAYER_BEHAVIOR;
}
void PacketPlayerBehavior::Packet(RakNet::BitStream *bs, bool send)
{
PlayerPacket::Packet(bs, send);
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETPLAYERBEHAVIOR_HPP
#define OPENMW_PACKETPLAYERBEHAVIOR_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
namespace mwmp
{
class PacketPlayerBehavior : public PlayerPacket
{
public:
PacketPlayerBehavior(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, bool send);
};
}
#endif //OPENMW_PACKETPLAYERBEHAVIOR_HPP

@ -0,0 +1,16 @@
#include "PacketPlayerInteraction.hpp"
#include <components/openmw-mp/NetworkMessages.hpp>
using namespace mwmp;
PacketPlayerInteraction::PacketPlayerInteraction(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_PLAYER_INTERACTION;
}
void PacketPlayerInteraction::Packet(RakNet::BitStream *bs, bool send)
{
PlayerPacket::Packet(bs, send);
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETPLAYERINTERACTION_HPP
#define OPENMW_PACKETPLAYERINTERACTION_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
namespace mwmp
{
class PacketPlayerInteraction : public PlayerPacket
{
public:
PacketPlayerInteraction(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, bool send);
};
}
#endif //OPENMW_PACKETPLAYERINTERACTION_HPP

@ -0,0 +1,16 @@
#include "PacketPlayerMiscellaneous.hpp"
#include <components/openmw-mp/NetworkMessages.hpp>
using namespace mwmp;
PacketPlayerMiscellaneous::PacketPlayerMiscellaneous(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_PLAYER_MISCELLANEOUS;
}
void PacketPlayerMiscellaneous::Packet(RakNet::BitStream *bs, bool send)
{
PlayerPacket::Packet(bs, send);
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETPLAYERMISCELLANEOUS_HPP
#define OPENMW_PACKETPLAYERMISCELLANEOUS_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
namespace mwmp
{
class PacketPlayerMiscellaneous : public PlayerPacket
{
public:
PacketPlayerMiscellaneous(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, bool send);
};
}
#endif //OPENMW_PACKETPLAYERMISCELLANEOUS_HPP

@ -0,0 +1,16 @@
#include "PacketPlayerReputation.hpp"
#include <components/openmw-mp/NetworkMessages.hpp>
using namespace mwmp;
PacketPlayerReputation::PacketPlayerReputation(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_PLAYER_REPUTATION;
}
void PacketPlayerReputation::Packet(RakNet::BitStream *bs, bool send)
{
PlayerPacket::Packet(bs, send);
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETPLAYERREPUTATION_HPP
#define OPENMW_PACKETPLAYERREPUTATION_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
namespace mwmp
{
class PacketPlayerReputation : public PlayerPacket
{
public:
PacketPlayerReputation(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, bool send);
};
}
#endif //OPENMW_PACKETPLAYERREPUTATION_HPP

@ -0,0 +1,17 @@
#include "PacketRecordDynamic.hpp"
#include <components/openmw-mp/NetworkMessages.hpp>
using namespace mwmp;
PacketRecordDynamic::PacketRecordDynamic(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_RECORD_DYNAMIC;
orderChannel = CHANNEL_SYSTEM;
}
void PacketRecordDynamic::Packet(RakNet::BitStream *bs, bool send)
{
PlayerPacket::Packet(bs, send);
// Placeholder
}

@ -0,0 +1,18 @@
#ifndef OPENMW_PACKETRECORDDYNAMIC_HPP
#define OPENMW_PACKETRECORDDYNAMIC_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
#include <components/openmw-mp/NetworkMessages.hpp>
namespace mwmp
{
class PacketRecordDynamic: public PlayerPacket
{
public:
PacketRecordDynamic(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, bool send);
};
}
#endif //OPENMW_PACKETRECORDDYNAMIC_HPP

@ -0,0 +1,16 @@
#include <components/openmw-mp/NetworkMessages.hpp>
#include "PacketDoorDestination.hpp"
using namespace mwmp;
PacketDoorDestination::PacketDoorDestination(RakNet::RakPeerInterface *peer) : WorldPacket(peer)
{
packetID = ID_DOOR_DESTINATION;
hasCellData = true;
}
void PacketDoorDestination::Object(WorldObject &worldObject, bool send)
{
WorldPacket::Object(worldObject, send);
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETDOORDESTINATION_HPP
#define OPENMW_PACKETDOORDESTINATION_HPP
#include <components/openmw-mp/Packets/World/WorldPacket.hpp>
namespace mwmp
{
class PacketDoorDestination : public WorldPacket
{
public:
PacketDoorDestination(RakNet::RakPeerInterface *peer);
virtual void Object(WorldObject &worldObject, bool send);
};
}
#endif //OPENMW_PACKETDOORDESTINATION_HPP

@ -0,0 +1,16 @@
#include <components/openmw-mp/NetworkMessages.hpp>
#include "PacketObjectReset.hpp"
using namespace mwmp;
PacketObjectReset::PacketObjectReset(RakNet::RakPeerInterface *peer) : WorldPacket(peer)
{
packetID = ID_OBJECT_RESET;
hasCellData = true;
}
void PacketObjectReset::Object(WorldObject &worldObject, bool send)
{
WorldPacket::Object(worldObject, send);
// Placeholder
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETOBJECTRESET_HPP
#define OPENMW_PACKETOBJECTRESET_HPP
#include <components/openmw-mp/Packets/World/WorldPacket.hpp>
namespace mwmp
{
class PacketObjectReset : public WorldPacket
{
public:
PacketObjectReset(RakNet::RakPeerInterface *peer);
virtual void Object(WorldObject &worldObject, bool send);
};
}
#endif //OPENMW_PACKETOBJECTRESET_HPP

@ -0,0 +1,15 @@
#include <components/openmw-mp/NetworkMessages.hpp>
#include "PacketScriptGlobalFloat.hpp"
using namespace mwmp;
PacketScriptGlobalFloat::PacketScriptGlobalFloat(RakNet::RakPeerInterface *peer) : WorldPacket(peer)
{
packetID = ID_SCRIPT_GLOBAL_FLOAT;
}
void PacketScriptGlobalFloat::Object(WorldObject &worldObject, bool send)
{
RW(worldObject.varName, send);
RW(worldObject.floatVal, send);
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETSCRIPTGLOBALFLOAT_HPP
#define OPENMW_PACKETSCRIPTGLOBALFLOAT_HPP
#include <components/openmw-mp/Packets/World/WorldPacket.hpp>
namespace mwmp
{
class PacketScriptGlobalFloat : public WorldPacket
{
public:
PacketScriptGlobalFloat(RakNet::RakPeerInterface *peer);
virtual void Object(WorldObject &worldObject, bool send);
};
}
#endif //OPENMW_PACKETSCRIPTGLOBALFLOAT_HPP

@ -0,0 +1,16 @@
#include <components/openmw-mp/NetworkMessages.hpp>
#include "PacketScriptMemberFloat.hpp"
using namespace mwmp;
PacketScriptMemberFloat::PacketScriptMemberFloat(RakNet::RakPeerInterface *peer) : WorldPacket(peer)
{
packetID = ID_SCRIPT_MEMBER_FLOAT;
}
void PacketScriptMemberFloat::Object(WorldObject &worldObject, bool send)
{
RW(worldObject.refId, send);
RW(worldObject.index, send);
RW(worldObject.floatVal, send);
}

@ -0,0 +1,17 @@
#ifndef OPENMW_PACKETSCRIPTMEMBERFLOAT_HPP
#define OPENMW_PACKETSCRIPTMEMBERFLOAT_HPP
#include <components/openmw-mp/Packets/World/WorldPacket.hpp>
namespace mwmp
{
class PacketScriptMemberFloat : public WorldPacket
{
public:
PacketScriptMemberFloat(RakNet::RakPeerInterface *peer);
virtual void Object(WorldObject &obj, bool send);
};
}
#endif //OPENMW_PACKETSCRIPTMEMBERFLOAT_HPP

@ -800,6 +800,13 @@ bool Optimizer::RemoveRedundantNodesVisitor::isOperationPermissible(osg::Node& n
isOperationPermissibleForObject(&node); isOperationPermissibleForObject(&node);
} }
void Optimizer::RemoveRedundantNodesVisitor::apply(osg::LOD& lod)
{
// don't remove any direct children of the LOD because they are used to define each LOD level.
for (unsigned int i=0; i<lod.getNumChildren(); ++i)
traverse(*lod.getChild(i));
}
void Optimizer::RemoveRedundantNodesVisitor::apply(osg::Group& group) void Optimizer::RemoveRedundantNodesVisitor::apply(osg::Group& group)
{ {
if (typeid(group)==typeid(osg::Group) && if (typeid(group)==typeid(osg::Group) &&
@ -1849,6 +1856,12 @@ bool Optimizer::MergeGroupsVisitor::isOperationPermissible(osg::Group& node)
isOperationPermissibleForObject(&node); isOperationPermissibleForObject(&node);
} }
void Optimizer::MergeGroupsVisitor::apply(osg::LOD &lod)
{
// don't merge the direct children of the LOD because they are used to define each LOD level.
traverse(lod);
}
void Optimizer::MergeGroupsVisitor::apply(osg::Group &group) void Optimizer::MergeGroupsVisitor::apply(osg::Group &group)
{ {
if (group.getNumChildren() <= 1) if (group.getNumChildren() <= 1)

@ -339,6 +339,7 @@ class Optimizer
virtual void apply(osg::Group& group); virtual void apply(osg::Group& group);
virtual void apply(osg::Transform& transform); virtual void apply(osg::Transform& transform);
virtual void apply(osg::LOD& lod);
bool isOperationPermissible(osg::Node& node); bool isOperationPermissible(osg::Node& node);
@ -358,6 +359,7 @@ class Optimizer
bool isOperationPermissible(osg::Group& node); bool isOperationPermissible(osg::Group& node);
virtual void apply(osg::Group& group); virtual void apply(osg::Group& group);
virtual void apply(osg::LOD& lod);
}; };
class MergeGeometryVisitor : public BaseOptimizerVisitor class MergeGeometryVisitor : public BaseOptimizerVisitor

Loading…
Cancel
Save