Blood BlvD Ot
Member
- Joined
- Jun 12, 2010
- Messages
- 243
- Reaction score
- 7
[23/12/2010 01:08:42] [Error - TalkAction Interface]
[23/12/2010 01:08:42] data/talkactions/scripts/mathLogs.luanSay
[23/12/2010 01:08:42] Description:
[23/12/2010 01:08:42] data/talkactions/scripts/mathLogs.lua:12: attempt to index global 'Math' (a nil value)
[23/12/2010 01:08:42] stack traceback:
[23/12/2010 01:08:42] data/talkactions/scripts/mathLogs.lua:12: in function <data/talkactions/scripts/mathLogs.lua:2>
Code:
function onSay(cid, words, param, channel)
-- A^aX+b = B^cX+d --
-- x = (Log B * d) - (Log A * b) / (Log A * a) - (Log B * c) --
-------mathConfig--------
local A = 4
local B = 9
local a = 2
local b = 3
local c = 4
local d = 5
local x = (((Math.LOG10(B)) * d) - ((Math.LOG10(A)) * b) / ((Math.LOG10(A)) * a) - ((Math.LOG10(B)) * c))
-------/mathConfig-------
if isPlayer(cid) then
doCreatureSay(cid, "The Answer to ".. A .."^".. a .."X+".. b .." = ".. B .."^".. c .."X+".. d .." is X = ".. x .."", TALKTYPE_ORANGE_1)
end
return true
end