|
发表于 2011-9-14 13:39:22
|
显示全部楼层
研究第四个参数- ^【 精神 】\s*(\d+)\s*/\s*(\d+)\s*\[\s*(\d+)%\]\s*【 精力 】\s*(\d+)\s*/\s*(\d+)\s*\(\s*\+\s*(\d+)\).*$\n^【 气血 】\s*(\d+)\s*/\s*(\d+)\s*\[\s*(\d+)%\]\s*【 内力 】\s*(\d+)\s*/\s*(\d+)\s*\(\s*\+\s*(\d+)\)
复制代码- hp_stat_jing=function(n,l,w,s)
- world.Note ("n = "..n)
- world.Note ("l = "..l)
- world.Note ("---------------------------------------------------------")
- for k, v in pairs (w) do
- world.Note ("w["..k.."] = "..w[k])
- end
- world.Note ("---------------------------------------------------------")
- for m, t in pairs (s) do
- for am, at in pairs (s[m]) do
- world.Note ("s["..m.."]["..am.."] = "..s[m][am])
- end
- world.Note (".........................................................")
- end
- end
复制代码hp
≡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━≡
【 精神 】 1313 / 1313 [100%] 【 精力 】 2517 / 2517 (+ 0)
【 气血 】 2747 / 2747 [100%] 【 内力 】 3986 / 3986 (+ 0)
n = hp_stat_jing
l = 【 气血 】 2747 / 2747 [100%] 【 内力 】 3986 / 3986 (+ 0)
---------------------------------------------------------
w[1] = 1313
w[2] = 1313
w[3] = 100
w[4] = 2517
w[5] = 2517
w[6] = 0
w[7] = 2747
w[8] = 2747
w[9] = 100
w[10] = 3986
w[11] = 3986
w[12] = 0
w[0] = 【 精神 】 1313 / 1313 [100%] 【 精力 】 2517 / 2517 (+ 0)
【 气血 】 2747 / 2747 [100%] 【 内力 】 3986 / 3986 (+ 0)
---------------------------------------------------------
s[1][textcolour] = 12632256
s[1][backcolour] = 0
s[1][length] = 11
s[1][style] = 0
s[1][text] = 【 气血 】
.........................................................
s[2][textcolour] = 65280
s[2][backcolour] = 0
s[2][length] = 21
s[2][style] = 1
s[2][text] = 2747 / 2747 [100%]
.........................................................
s[3][textcolour] = 12632256
s[3][backcolour] = 0
s[3][length] = 13
s[3][style] = 0
s[3][text] = 【 内力 】
.........................................................
s[4][textcolour] = 65280
s[4][backcolour] = 0
s[4][length] = 21
s[4][style] = 1
s[4][text] = 3986 / 3986 (+ 0)
.........................................................
【 食物 】 0 / 410 [饥饿] 【 潜能 】 230.5K
[ 本帖最后由 onlinego 于 2011-9-14 01:53 PM 编辑 ] |
|