diff options
author | Adam Borowski <kilobyte@angband.pl> | 2013-11-29 22:27:51 +0100 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2013-11-29 22:27:51 +0100 |
commit | ecd341db79458137d3e97836d11830735c141623 (patch) | |
tree | c6473ea5460dd9b68c2652f54f001da19038b1c6 /crawl-ref/source/l_you.cc | |
parent | 49a6c400b1dd53744d817d698f9107b76c0110f5 (diff) | |
download | crawl-ref-ecd341db79458137d3e97836d11830735c141623.tar.gz crawl-ref-ecd341db79458137d3e97836d11830735c141623.zip |
Allow setting you.gold(x) in dlua.
Even if the game is not in wizmode, like vaults could want to.
Diffstat (limited to 'crawl-ref/source/l_you.cc')
-rw-r--r-- | crawl-ref/source/l_you.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crawl-ref/source/l_you.cc b/crawl-ref/source/l_you.cc index 3a095cc052..bb2404a20b 100644 --- a/crawl-ref/source/l_you.cc +++ b/crawl-ref/source/l_you.cc @@ -313,7 +313,7 @@ static int l_you_abil_table(lua_State *ls) static int you_gold(lua_State *ls) { - if (lua_gettop(ls) >= 1 && you.wizard) + if (lua_gettop(ls) >= 1 && !CLua::get_vm(ls).managed_vm) { const int new_gold = luaL_checkint(ls, 1); const int old_gold = you.gold; |