mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-31 16:15:35 +00:00
Remove lua action
This commit is contained in:
parent
f4d349070c
commit
3e31142c0b
1 changed files with 1 additions and 2 deletions
|
@ -148,8 +148,7 @@ namespace MWLua
|
|||
throw std::runtime_error("The argument must be a player.");
|
||||
if (dynamic_cast<const LObject*>(&player) && !dynamic_cast<const SelfObject*>(&player))
|
||||
throw std::runtime_error("Only player and global scripts can toggle teleportation.");
|
||||
context.mLuaManager->addAction([state] { MWBase::Environment::get().getWorld()->enableTeleporting(state); },
|
||||
"toggleTeleportingAction");
|
||||
MWBase::Environment::get().getWorld()->enableTeleporting(state);
|
||||
};
|
||||
player["setControlSwitch"] = [input](const Object& player, std::string_view key, bool v) {
|
||||
if (player.ptr() != MWBase::Environment::get().getWorld()->getPlayerPtr())
|
||||
|
|
Loading…
Reference in a new issue