diff options
author | Jesusaves <cpntb1@ymail.com> | 2018-03-19 00:37:56 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2018-03-19 00:37:56 -0300 |
commit | db14a2c991658cd62879252a3753d2c5f9eb26f7 (patch) | |
tree | f59ff78988f5231239b5ab0b043819321d2561cc | |
parent | 7211e9f29ad00c381042aff1ffa839abf282d89b (diff) | |
download | tools-db14a2c991658cd62879252a3753d2c5f9eb26f7.tar.gz tools-db14a2c991658cd62879252a3753d2c5f9eb26f7.tar.bz2 tools-db14a2c991658cd62879252a3753d2c5f9eb26f7.tar.xz tools-db14a2c991658cd62879252a3753d2c5f9eb26f7.zip |
Restore Modes column.
-rwxr-xr-x | wiki/wikigen.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/wiki/wikigen.py b/wiki/wikigen.py index 5f6be54..44a67b3 100755 --- a/wiki/wikigen.py +++ b/wiki/wikigen.py @@ -149,7 +149,7 @@ def testMobs(): src.close() def stp(x): - return x.replace('\n', '').replace('|', '').replace('(int, defaults to ', '').replace(')', '').replace('basic experience', '').replace('"','').replace(" ","").replace('(string', '').replace('Name: ','').replace('AttackDelay: ', '').replace('MoveSpeed: ', '').replace('AttackRange: ', '').replace('ViewRange: ','').replace('Attack: ','').replace('ViewRange: ','').replace('Hp: ','').replace('Id: ','').replace('Lv: ','').replace('view range','').replace('attack range','').replace('move speed','').replace('health','').replace('(int','').replace('attack delay','atk delay') + return x.replace('\n', '').replace('|', '').replace('(int, defaults to ', '').replace(')', '').replace('basic experience', '').replace('"','').replace(" ","").replace('(string', '').replace('Name: ','').replace('AttackDelay: ', '').replace('MoveSpeed: ', '').replace('AttackRange: ', '').replace('ViewRange: ','').replace('Attack: ','').replace('ViewRange: ','').replace('Hp: ','').replace('Id: ','').replace('Lv: ','').replace('view range','').replace('attack range','').replace('move speed','').replace('health','').replace('(int','').replace('attack delay','atk.') def writeMob(): @@ -161,15 +161,15 @@ def writeMob(): wikib.write("## Aggressive Monsters\n\n") wikib.write("<table border=1>\n") - wikib.write("<tr><th>ID</th><th>Name</th><th>HP</th><th>Atk</th><th>Delay</th><th>View Range</th><th>Misc Info</th><th>Rewards</th><th>Drops</th></tr>\n") + wikib.write("<tr><th>ID</th><th>Name</th><th>HP</th><th>Atk</th><th>Delay</th><th>Modes</th><th>Misc Info</th><th>Rewards</th><th>Drops</th></tr>\n") for i in AggMobs: wikib.write('<tr><td>' + i.id +"</td><td>"+ i.name +"</td><td>HP: "+ i.hp +"</td><td>Atk: "+ i.atk +"</td><td>"+ - i.delay +" ms</td><td>View: "+ - i.view +"</td><td>"+ + i.delay +" ms</td><td>"+ + i.st +"</td><td>"+ mbdt('misc', mb_rdmisc(i)) +"</td><td>"+ mbdt('Exp\'s', mb_rdrw(i)) +"</td><td>"+ mbdt('drops', mb_rddrop(i)) +"</td></tr>\n" @@ -181,7 +181,7 @@ def writeMob(): wikib.write("## Normal Monsters\n\n") wikib.write("<table border=1>\n") - wikib.write("<tr><th>ID</th><th>Name</th><th>HP</th><th>Atk</th><th>Delay</th><th>Misc Info</th><th>Rewards</th><th>Drops</th></tr>\n") + wikib.write("<tr><th>ID</th><th>Name</th><th>HP</th><th>Atk</th><th>Delay</th><th>Modes</th><th>Misc Info</th><th>Rewards</th><th>Drops</th></tr>\n") for i in NrmMobs: wikib.write('<tr><td>' + i.id +"</td><td>"+ @@ -189,6 +189,7 @@ def writeMob(): i.hp +"</td><td>Atk: "+ i.atk +"</td><td>"+ i.delay +" ms</td><td>"+ + i.st +"</td><td>"+ mbdt('misc', mb_rdmisc(i)) +"</td><td>"+ mbdt('Exp\'s', mb_rdrw(i)) +"</td><td>"+ mbdt('drops', mb_rddrop(i)) +"</td></tr>\n" @@ -203,7 +204,8 @@ def mbdt(summary, content): def mb_rdmisc(mb): buff="" - buff+="Modes: %s\n" % (mb.st) # TODO: Move to table body + if "agr" in mb.st.lower(): + buff+="View Range: %s\n" % (mb.view) buff+="Attack Range: %s\n" % (mb.range) buff+="Move speed: %s ms\n" % (mb.move) return buff |