forked from teamnwah/openmw-tes3coop
9ab58b6708
Rename SendResurrect to Resurrect
19 lines
730 B
C++
19 lines
730 B
C++
#include "Death.hpp"
|
|
#include <apps/openmw-mp/Script/ScriptFunctions.hpp>
|
|
#include <components/openmw-mp/NetworkMessages.hpp>
|
|
#include <apps/openmw-mp/Networking.hpp>
|
|
#include <components/openmw-mp/Log.hpp>
|
|
|
|
#include <iostream>
|
|
using namespace std;
|
|
|
|
void DeathFunctions::Resurrect(unsigned short pid, unsigned int type) noexcept
|
|
{
|
|
Player *player;
|
|
GET_PLAYER(pid, player, );
|
|
|
|
player->resurrectType = type;
|
|
mwmp::Networking::get().getPlayerPacketController()->GetPacket(ID_PLAYER_RESURRECT)->setPlayer(player);
|
|
mwmp::Networking::get().getPlayerPacketController()->GetPacket(ID_PLAYER_RESURRECT)->Send(false);
|
|
mwmp::Networking::get().getPlayerPacketController()->GetPacket(ID_PLAYER_RESURRECT)->Send(true);
|
|
}
|