• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua get spell info by spell's name

andu

Sold 649 scripts, 25 maps and 9 events!
Joined
Aug 7, 2009
Messages
969
Solutions
17
Reaction score
354
GitHub
olrios
Twitch
olrios
For example we have Light spell, how to get how much it requires mana to cast via lua without doing loop and searching all spells by spell.name like it's in spellbook.lua?
Do we have in 1.2 lua function like getSpellInfoByName?
 
Solution
Nope. There's no problem doing it via loops anyways. In 1.3 we have the Spell metatable and you can do exactly what you're saying with it, but it uses a loop!!
Nope. There's no problem doing it via loops anyways. In 1.3 we have the Spell metatable and you can do exactly what you're saying with it, but it uses a loop!!
 
Last edited:
Solution
Back
Top