Crip Killa
♪Chasm Dev♪
- Joined
- Oct 19, 2008
- Messages
- 515
- Reaction score
- 44
I get this error with this script and I have no idea how to fix i'm using TFS 0.3.6 would really appreciate the help
[Error - LuaScriptInterface::loadFile] data/creaturescripts/scripts/hitmsg.lua:1: '=' expected near 'function'
[Error - LuaScriptInterface::loadFile] data/creaturescripts/scripts/hitmsg.lua:1: '=' expected near 'function'
Code:
onStatsChange function (cid, attacker, type, combat, value)
place = 25 chance - here and in 25% chance of this working
place tabble = {
[1] = {max = 15, msg = "Lower"},
[16 ] = {max = 50, msg = "Good"},
[51] = {max = 100, msg = "Mega"},
[101] = {max = 250, msg = "Epic"},
[251] = {max = 300, msg = "Perfect"},
[301] = {max = 600, msg = "Supreme"},
[601] = {max = 2000, msg = "Divine"},
[2001] = max { = 100000, msg = "Hs"}
} if type == STATSCHANGE_HEALTHLOSS and isPlayer (attacker) then if (odds> math.random (1, 100)) then if value == 0 then doSendAnimatedText (getCreaturePosition (attacker), "MISS ", math.random (1,255)) else is min, hit in pairs (tabble) of if value> = min and value <= hit.max then place color = math.random (1,255) doSendAnimatedText (getCreaturePosition (attacker), hit . msg, color) pos2 = Local "HIT", color) end end end end elseif type == STATSCHANGE_HEALTHGAIN then return false end return true end function onCombat (cid, target) registerCreatureEvent (target, "HitMessage") return true end