mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-06 00:55:50 +00:00
Fix minor doc error, throw error when attempting to assign a value to a non-existing global variable in lua
This commit is contained in:
parent
6f4e7ed5dc
commit
dd87d01f06
@ -140,7 +140,7 @@ namespace MWLua
|
||||
= sol::overload([](const GlobalStore& store, std::string_view globalId, float val) {
|
||||
auto g = store.search(ESM::RefId::deserializeText(globalId));
|
||||
if (g == nullptr)
|
||||
return;
|
||||
throw std::runtime_error("No variable \"" + std::string(globalId) + "\" in GlobalStore");
|
||||
char varType = MWBase::Environment::get().getWorld()->getGlobalVariableType(globalId);
|
||||
if (varType == 's' || varType == 'l')
|
||||
{
|
||||
|
@ -930,7 +930,6 @@
|
||||
-- Whether teleportation for this player is enabled.
|
||||
-- @function [parent=#Player] isTeleportingEnabled
|
||||
-- @param openmw.core#GameObject player
|
||||
-- @param #boolean player
|
||||
-- @return #boolean
|
||||
|
||||
---
|
||||
|
Loading…
Reference in New Issue
Block a user