mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 13:06:59 -04:00
Also init dependencies of non rule form expand_keywords
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@989 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -232,6 +232,10 @@ ScriptValueP Context::getVariable(Variable var) {
|
||||
if (variables[var].value) return variables[var].value;
|
||||
throw ScriptError(_("Variable not set: ") + variable_to_string(var));
|
||||
}
|
||||
ScriptValueP Context::getVariableInScopeOpt(Variable var) {
|
||||
if (variables[var].level == level) return variables[var].value;
|
||||
else return ScriptValueP();
|
||||
}
|
||||
int Context::getVariableScope(Variable var) {
|
||||
if (variables[var].value) return level - variables[var].level;
|
||||
else return -1;
|
||||
|
||||
Reference in New Issue
Block a user