Help with Table - Regex

User avatar
demonnic
Posts: 886
Joined: Sat Dec 05, 2009 3:19 pm

Re: Help with Table - Regex

Post by demonnic »

Attaching what I've come up with. I tested this by rolling a quick toon and it seems to work, but I only have the newbie skills, so best to test it! Used child triggers a couple of different ways in this. Right now it's all ugly highlighting and it just creates and prints the table out (mySkills), so you will want to adjust as you need.
Attachments
lotj-skill-parser.xml
(4.5 KiB) Downloaded 506 times

User avatar
demonnic
Posts: 886
Joined: Sat Dec 05, 2009 3:19 pm

Re: Help with Table - Regex

Post by demonnic »

Any word? Curious as to how it worked out for you.

Deshanti
Posts: 10
Joined: Sat Feb 25, 2012 10:29 am

Re: Help with Table - Regex

Post by Deshanti »

Sorry for the delay, I tried your parser. When I wrote lua display(mySkills), it gave the entire list. Which is all good, but the problem is when we try to put those skills in a new table. Aside from that it all works out. I'm just not able to for instance use this;

function moveskills()
researchthese = {}
for i,v in pairs(mySkills) do
if (v<80) then
table.insert(researchthese,i)
end
end
end

And I need that because of this...
if matches[2] == "on" then
research = {}
research.skill = researchthese[1]
research.percent = tonumber(mySkills[researchthese[1]])
researching = true
send("research "..research.skill)
cecho("\n<green>Research Mode - Enabled")
elseif matches[2] == "off" then
researching = false
cecho("\n<red>Research Mode - Disabled")
end

Post Reply