Processing custom strings for some properties, like skill-rand. https://d2mods.info/forum/kb/viewarticle?a=345. fixed

This commit is contained in:
Hash Borgir 2022-04-27 16:26:43 -06:00
parent c40f67545f
commit db3c6473ca

View File

@ -95,8 +95,6 @@ class D2ItemData {
// val = Prop1,Prop2 etc.
// for each propr, get all 7 stats in ISC
// for now only get stat1, and for else, use dgrp
// prop funcs
/*
* 1 - Applies a value to a stat, can use SetX parameter.
@ -175,12 +173,14 @@ class D2ItemData {
if ((!empty($v['desc']))) {
require_once 'D2ItemDesc.php';
$idesc = new D2ItemDesc();
$props[$k]['string'][] = ($idesc->getDesc($params));
if ($v['stat']['func1'] == '12'){
$props[$k]['string'] = "+{$params['par']} to a Random Skill";
}
ddump($props[$k]['string']);
// process all properties.txt func1 here, total 25 in comments above
//process property func 12, random skill
if ($v['stat']['func1'] == '12') {
$props[$k]['string'][] = "+{$params['par']} to Random Skill";
} else {
$props[$k]['string'][] = ($idesc->getDesc($params));
}
}
$counter++;
}
@ -259,4 +259,5 @@ class D2ItemData {
$this->strings[$v['prop']] = $v;
}
}
}