mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-29 17:15:32 +00:00
remote local variable access was always using variable with index 1 instead of the index specified by the access request (Fixes #1739)
This commit is contained in:
parent
736ab76f68
commit
52f6a2ec7b
2 changed files with 4 additions and 4 deletions
|
@ -111,7 +111,7 @@ namespace MWScript
|
|||
const std::string& name, char type) const
|
||||
{
|
||||
int index = MWBase::Environment::get().getScriptManager()->getLocals (scriptId).
|
||||
search (type, name);
|
||||
searchIndex (type, name);
|
||||
|
||||
if (index!=-1)
|
||||
return index;
|
||||
|
|
|
@ -15,8 +15,6 @@ namespace Compiler
|
|||
std::vector<std::string> mLongs;
|
||||
std::vector<std::string> mFloats;
|
||||
|
||||
int searchIndex (char type, const std::string& name) const;
|
||||
|
||||
std::vector<std::string>& get (char type);
|
||||
|
||||
public:
|
||||
|
@ -27,9 +25,11 @@ namespace Compiler
|
|||
int getIndex (const std::string& name) const;
|
||||
///< return index for local variable \a name (-1: does not exist).
|
||||
|
||||
bool search (char type, const std::string& name) const;
|
||||
|
||||
/// Return index for local variable \a name of type \a type (-1: variable does not
|
||||
/// exit).
|
||||
bool search (char type, const std::string& name) const;
|
||||
int searchIndex (char type, const std::string& name) const;
|
||||
|
||||
const std::vector<std::string>& get (char type) const;
|
||||
|
||||
|
|
Loading…
Reference in a new issue