added aux effects
This commit is contained in:
parent
5e603392a0
commit
3e2e22a1f0
2 changed files with 125 additions and 2 deletions
62
classes.json
Normal file
62
classes.json
Normal file
|
@ -0,0 +1,62 @@
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"id": "wretch",
|
||||||
|
"name": "Wretch",
|
||||||
|
"level": 1,
|
||||||
|
"stats": [10, 10, 10, 10, 10, 10, 10, 10]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "bandit",
|
||||||
|
"name": "Bandit",
|
||||||
|
"level": 5,
|
||||||
|
"stats": [10, 11, 10, 9, 13, 9, 8, 14]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "astrologer",
|
||||||
|
"name": "Astrologer",
|
||||||
|
"level": 6,
|
||||||
|
"stats": [9, 15, 9, 8, 12, 16, 7, 9]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "hero",
|
||||||
|
"name": "Hero",
|
||||||
|
"level": 7,
|
||||||
|
"stats": [14, 9, 12, 16, 9, 7, 8, 11]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "prophet",
|
||||||
|
"name": "Prophet",
|
||||||
|
"level": 7,
|
||||||
|
"stats": [10, 14, 8, 11, 10, 7, 16, 10]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "warrior",
|
||||||
|
"name": "Warrior",
|
||||||
|
"level": 8,
|
||||||
|
"stats": [11, 12, 11, 10, 16, 10, 8, 9]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "vagabond",
|
||||||
|
"name": "Vagabond",
|
||||||
|
"level": 9,
|
||||||
|
"stats": [15, 10, 11, 14, 13, 9, 9, 7]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "samurai",
|
||||||
|
"name": "Samurai",
|
||||||
|
"level": 9,
|
||||||
|
"stats": [12, 11, 13, 12, 15, 9, 8, 8]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "prisoner",
|
||||||
|
"name": "Prisoner",
|
||||||
|
"level": 9,
|
||||||
|
"stats": [11, 12, 11, 11, 14, 14, 6, 9]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "confessor",
|
||||||
|
"name": "Confessor",
|
||||||
|
"level": 10,
|
||||||
|
"stats": [10, 13, 10, 12, 12, 9, 14, 9]
|
||||||
|
}
|
||||||
|
]
|
|
@ -169,6 +169,7 @@ def main():
|
||||||
open("input/AttackElementCorrectParam.csv") as af,
|
open("input/AttackElementCorrectParam.csv") as af,
|
||||||
open("input/EquipParamWeapon.csv") as wf,
|
open("input/EquipParamWeapon.csv") as wf,
|
||||||
open("input/CalcCorrectGraph.csv") as cf,
|
open("input/CalcCorrectGraph.csv") as cf,
|
||||||
|
open("input/SpEffectParam.csv") as sf,
|
||||||
):
|
):
|
||||||
|
|
||||||
rows = list(csv.DictReader(wf, delimiter=";"))
|
rows = list(csv.DictReader(wf, delimiter=";"))
|
||||||
|
@ -182,9 +183,12 @@ def main():
|
||||||
row["Row ID"]: row for row in softcaps if 0 <= int(row["Row ID"]) <= 16
|
row["Row ID"]: row for row in softcaps if 0 <= int(row["Row ID"]) <= 16
|
||||||
}
|
}
|
||||||
|
|
||||||
|
effects = list(csv.DictReader(sf, delimiter=";"))
|
||||||
|
effects = {row["Row ID"]: row for row in effects}
|
||||||
|
|
||||||
for row in rows:
|
for row in rows:
|
||||||
if not ignored(row):
|
if not ignored(row):
|
||||||
process_weapon(row, masks, softcaps)
|
process_weapon(row, masks, effects)
|
||||||
|
|
||||||
process_damage(softcaps)
|
process_damage(softcaps)
|
||||||
|
|
||||||
|
@ -430,7 +434,7 @@ def to_mask(str):
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
|
|
||||||
def process_weapon(row, masks, caps):
|
def process_weapon(row, masks, effects):
|
||||||
name, infusion = split_weapon_name(row["Row Name"])
|
name, infusion = split_weapon_name(row["Row Name"])
|
||||||
id = to_kebab(name)
|
id = to_kebab(name)
|
||||||
|
|
||||||
|
@ -501,12 +505,68 @@ def process_weapon(row, masks, caps):
|
||||||
|
|
||||||
buffable = "True" in row["Is Buffable"]
|
buffable = "True" in row["Is Buffable"]
|
||||||
|
|
||||||
|
# Auxiliary Effects (blood, poison)
|
||||||
|
aux = {}
|
||||||
|
for aux_id in [row["Behavior SpEffect 1"], row["Behavior SpEffect 2"]]:
|
||||||
|
if int(aux_id) != -1 and int(aux_id) > 100000:
|
||||||
|
aux_name = effects[aux_id]["Row Name"]
|
||||||
|
xs = [x for x in range(0, 26)]
|
||||||
|
ys = [effects[str(int(aux_id) + x)] for x in xs]
|
||||||
|
|
||||||
|
if "Hemorrhage" in aux_name:
|
||||||
|
ty = "bleed"
|
||||||
|
ys = [int(y["Inflict Hemorrhage +"]) for y in ys]
|
||||||
|
elif "Frostbite" in aux_name:
|
||||||
|
ty = "frost"
|
||||||
|
ys = [int(y["Inflict Frostbite +"]) for y in ys]
|
||||||
|
elif "Poison" in aux_name:
|
||||||
|
ty = "poison"
|
||||||
|
ys = [int(y["Inflict Poison +"]) for y in ys]
|
||||||
|
elif "Scarlet Rot" in aux_name:
|
||||||
|
ty = "scarlet_rot"
|
||||||
|
ys = [int(y["Inflict Scarlet Rot +"]) for y in ys]
|
||||||
|
elif "Madness" in aux_name:
|
||||||
|
ty = "madness"
|
||||||
|
ys = [int(y["Inflict Madness +"]) for y in ys]
|
||||||
|
elif "Sleep" in aux_name:
|
||||||
|
ty = "sleep"
|
||||||
|
ys = [int(y["Inflict Sleep +"]) for y in ys]
|
||||||
|
elif "Blight" in aux_name:
|
||||||
|
ty = "blight"
|
||||||
|
ys = [int(y["Inflict Blight +"]) for y in ys]
|
||||||
|
aux[ty] = regression(xs, ys)
|
||||||
|
elif int(aux_id) != -1 and int(aux_id) <= 100000:
|
||||||
|
aux_name = effects[aux_id]["Row Name"]
|
||||||
|
if "Hemorrhage" in aux_name:
|
||||||
|
ty = "bleed"
|
||||||
|
base = effects[aux_id]["Inflict Hemorrhage +"]
|
||||||
|
elif "Frostbite" in aux_name:
|
||||||
|
ty = "frost"
|
||||||
|
base = effects[aux_id]["Inflict Frostbite +"]
|
||||||
|
elif "Poison" in aux_name:
|
||||||
|
ty = "poison"
|
||||||
|
base = effects[aux_id]["Inflict Poison +"]
|
||||||
|
elif "Scarlet Rot" in aux_name:
|
||||||
|
ty = "scarlet_rot"
|
||||||
|
base = effects[aux_id]["Inflict Scarlet Rot +"]
|
||||||
|
elif "Madness" in aux_name:
|
||||||
|
ty = "madness"
|
||||||
|
base = effects[aux_id]["Inflict Madness +"]
|
||||||
|
elif "Sleep" in aux_name:
|
||||||
|
ty = "sleep"
|
||||||
|
base = effects[aux_id]["Inflict Sleep +"]
|
||||||
|
elif "Blight" in aux_name:
|
||||||
|
ty = "blight"
|
||||||
|
base = effects[aux_id]["Inflict Blight +"]
|
||||||
|
aux[ty] = [0.0, aux_name]
|
||||||
|
|
||||||
if id in weapons:
|
if id in weapons:
|
||||||
if not id in IGNORED_WEAPON_INFUSIONS:
|
if not id in IGNORED_WEAPON_INFUSIONS:
|
||||||
weapon = weapons[id]
|
weapon = weapons[id]
|
||||||
weapon["infusions"][infusion] = {
|
weapon["infusions"][infusion] = {
|
||||||
"damage": damage,
|
"damage": damage,
|
||||||
"scaling": scaling,
|
"scaling": scaling,
|
||||||
|
"aux": aux,
|
||||||
"masks": weapon_masks,
|
"masks": weapon_masks,
|
||||||
"corrections": corrections,
|
"corrections": corrections,
|
||||||
"buffable": buffable,
|
"buffable": buffable,
|
||||||
|
@ -537,6 +597,7 @@ def process_weapon(row, masks, caps):
|
||||||
weapon["infusions"][infusion] = {
|
weapon["infusions"][infusion] = {
|
||||||
"damage": damage,
|
"damage": damage,
|
||||||
"scaling": scaling,
|
"scaling": scaling,
|
||||||
|
"aux": aux,
|
||||||
"masks": weapon_masks,
|
"masks": weapon_masks,
|
||||||
"corrections": corrections,
|
"corrections": corrections,
|
||||||
"buffable": buffable,
|
"buffable": buffable,
|
||||||
|
|
Loading…
Reference in a new issue