forked from mirror/openmw-tes3mp
blocked using of locked doors (keys are not considered yet)
This commit is contained in:
parent
459dd82896
commit
61c4fa0630
1 changed files with 10 additions and 1 deletions
|
@ -15,6 +15,8 @@
|
||||||
|
|
||||||
#include "../mwrender/cellimp.hpp"
|
#include "../mwrender/cellimp.hpp"
|
||||||
|
|
||||||
|
#include <iostream>
|
||||||
|
|
||||||
namespace MWClass
|
namespace MWClass
|
||||||
{
|
{
|
||||||
void Door::insertObj (const MWWorld::Ptr& ptr, MWRender::CellRenderImp& cellRender,
|
void Door::insertObj (const MWWorld::Ptr& ptr, MWRender::CellRenderImp& cellRender,
|
||||||
|
@ -50,7 +52,14 @@ namespace MWClass
|
||||||
ESMS::LiveCellRef<ESM::Door, MWWorld::RefData> *ref =
|
ESMS::LiveCellRef<ESM::Door, MWWorld::RefData> *ref =
|
||||||
ptr.get<ESM::Door>();
|
ptr.get<ESM::Door>();
|
||||||
|
|
||||||
// TODO check lock
|
if (ptr.getCellRef().lockLevel>0)
|
||||||
|
{
|
||||||
|
// TODO check for key
|
||||||
|
// TODO report failure to player (message, sound?). Look up behaviour of original MW.
|
||||||
|
std::cout << "Locked!" << std::endl;
|
||||||
|
return boost::shared_ptr<MWWorld::Action> (new MWWorld::NullAction);
|
||||||
|
}
|
||||||
|
|
||||||
// TODO check trap
|
// TODO check trap
|
||||||
|
|
||||||
if (ref->ref.teleport)
|
if (ref->ref.teleport)
|
||||||
|
|
Loading…
Reference in a new issue