diff options
author | Bardur Arantsson <bardur@scientician.net> | 2015-02-23 09:11:55 +0100 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2015-02-23 09:11:55 +0100 |
commit | 692699f064b2d792b61a5aa448b6844e8c713248 (patch) | |
tree | 9e25e80c55c3e2fea86de4d7ccfd037fe64aabc4 /src/lua_bind.cc | |
parent | e63216657a9a2711483517e8eb5bed46215ae6dd (diff) |
Change spell_chance_device parameter to use spell_type pointer
There's no need to go through the extra indirection of the spell list.
Diffstat (limited to 'src/lua_bind.cc')
-rw-r--r-- | src/lua_bind.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lua_bind.cc b/src/lua_bind.cc index 1e4303b7..6b22e1d2 100644 --- a/src/lua_bind.cc +++ b/src/lua_bind.cc @@ -150,13 +150,12 @@ static s32b spell_chance_school(s32b s) return clamp_failure_chance(chance, minfail); } -s32b spell_chance_device(s32b s) +s32b spell_chance_device(spell_type *spell_ptr) { // Device parameters initialized? assert(get_level_use_stick > -1); // Calculate the chance. - auto spell_ptr = spell_at(s); int level = get_level_device_1(spell_ptr, 50, 1); s32b chance = spell_type_failure_rate(spell_ptr); |