- Joined
- Nov 17, 2010
- Messages
- 6,834
- Solutions
- 585
- Reaction score
- 5,424
Short and sweet, I've been searching for a few hours and not having much luck.
Wanted Result;
Player says
console prints
I have this in spells.xml (assuming it's required, as spells such as levitate use it)
Everything I've tried thus far either prints nothing, or throws errors.
'attempt to index a number value'
'attempt to concatenate a local 'text' (a nil value)'
among others.
I'm not even sure what to try at this point.
Can someone point me in the right direction?
Xikini
Wanted Result;
Player says
Code:
test_spell test
test_spell 'test
test_spell "test
Code:
test
test
test
I have this in spells.xml (assuming it's required, as spells such as levitate use it)
Lua:
params="1"
Lua:
<instant name="test_spell" words="test_spell" mana="0" exhaustion="1000" groups="4,1000" icon="57" params="1" needlearn="0" event="script" value="test_spell.lua">
</instant>
Lua:
function onCastSpell(cid, var)
local text = var.type
--local text = var.number
--local text = var.text
--local text = variantToString(var.type)
--local text = variantToString(var.number)
--local text = variantToString(var.text)
print(text)
return true
end
'attempt to index a number value'
'attempt to concatenate a local 'text' (a nil value)'
among others.
I'm not even sure what to try at this point.
Can someone point me in the right direction?
Xikini