mirror of
https://gitlab.com/hashborgir/d2tools.git
synced 2024-11-30 04:26:03 +00:00
Correct skill numbers from d2s stream now working
This commit is contained in:
parent
919cbc58e0
commit
7ba575ad1d
@ -146,19 +146,19 @@ foreach ($c->cData['Waypoints'] as $diff => $waypoints) {
|
||||
'col' => int 2
|
||||
'icon' => int 0
|
||||
*/
|
||||
$skillcounter = 1;
|
||||
foreach ($c->cData['skills']['skills'] as $k => $skill) {
|
||||
$skills .= "<input cmd='skills' style='width: 64px;' class='skill-$k skill' name='$skillcounter' type='number' min='0' max='255' value='{$skill['points']}'>: {$skill['skill']}<hr>";
|
||||
$skillcounter++;
|
||||
}
|
||||
// $skillcounter = 1;
|
||||
// foreach ($c->cData['skills']['skills'] as $k => $skill) {
|
||||
// $skills .= "<input cmd='skills' style='width: 64px;' class='skill-$k skill' name='$skillcounter' type='number' min='0' max='255' value='{$skill['points']}'>: {$skill['skill']}<hr>";
|
||||
// $skillcounter++;
|
||||
// }
|
||||
|
||||
$skillsByPage = array();
|
||||
foreach ($c->cData['skills']['skills'] as $skill) {
|
||||
foreach ($c->cData['skills']['skills'] as $skNum => $skill) {
|
||||
$page = $skill['page'];
|
||||
if (!isset($skillsByPage[$page])) {
|
||||
$skillsByPage[$page] = array();
|
||||
}
|
||||
$skillsByPage[$page][] = $skill;
|
||||
$skillsByPage[$page][$skNum] = $skill;
|
||||
}
|
||||
|
||||
$skillDivs = '';
|
||||
@ -177,9 +177,9 @@ foreach ($skillsByPage as $page => $skills) {
|
||||
|
||||
$skillDivs .= '<div id="' . $collapseId . '" class="collapse ' . $isExpanded . '" aria-labelledby="' . $headingId . '" data-parent="#accordionExample">';
|
||||
$skillDivs .= '<div class="card-body">';
|
||||
foreach ($skills as $skill) {
|
||||
$skillcounter++;
|
||||
$skillDivs .= "<input cmd='skills' style='width: 64px;' class='skill-$k skill' name='$skillcounter' type='number' min='0' max='255' value='{$skill['points']}'>: {$skill['skill']}<hr>";
|
||||
foreach ($skills as $skillNumber => $skill) {
|
||||
$skillNumber++;
|
||||
$skillDivs .= "<input cmd='skills' style='width: 64px;' class='skill-{$skill['id']} skill' name='$skillNumber' type='number' min='0' max='255' value='{$skill['points']}'>: {$skill['skill']}<hr>";
|
||||
}
|
||||
$skillDivs .= '</div>';
|
||||
$skillDivs .= '</div>';
|
||||
@ -320,58 +320,58 @@ $checkboxes
|
||||
<div class="form-row" style="background: #eed;">
|
||||
<div class="form-group col-md-3">
|
||||
<label for="strength">Strength:</label>
|
||||
<input type="number" class="form-control" id="strength" name="strength" min="1" max="255" value="{$c->cData['stats']['strength']}" required>
|
||||
<input type="number" class="form-control" id="strength" name="strength" min="1" max="511" value="{$c->cData['stats']['strength']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="dexterity">Dexterity:</label>
|
||||
<input type="number" class="form-control" id="dexterity" name="dexterity" min="1" max="255" value="{$c->cData['stats']['dexterity']}" required>
|
||||
<input type="number" class="form-control" id="dexterity" name="dexterity" min="1" max="511" value="{$c->cData['stats']['dexterity']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="vitality">Vitality:</label>
|
||||
<input type="number" class="form-control" id="vitality" name="vitality" min="1" max="255" value="{$c->cData['stats']['vitality']}" required>
|
||||
<input type="number" class="form-control" id="vitality" name="vitality" min="1" max="511" value="{$c->cData['stats']['vitality']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="energy">Energy:</label>
|
||||
<input type="number" class="form-control" id="energy" name="energy" min="1" max="255" value="{$c->cData['stats']['energy']}" required>
|
||||
<input type="number" class="form-control" id="energy" name="energy" min="1" max="511" value="{$c->cData['stats']['energy']}" required>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-row" style="background: #eee;">
|
||||
<div class="form-group col-md-3">
|
||||
<label for="hitpoints">Hitpoints:</label>
|
||||
<input type="number" class="form-control" id="hitpoints" name="hitpoints" min="1" max="255" value="{$c->cData['stats']['hitpoints']}" required>
|
||||
<input type="number" class="form-control" id="hitpoints" name="hitpoints" min="1" max="2097151" value="{$c->cData['stats']['hitpoints']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="maxhp">Max HP:</label>
|
||||
<input type="number" class="form-control" id="maxhp" name="maxhp" min="1" max="255" value="{$c->cData['stats']['maxhp']}" required>
|
||||
<input type="number" class="form-control" id="maxhp" name="maxhp" min="1" max="2097151" value="{$c->cData['stats']['maxhp']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="mana">Mana:</label>
|
||||
<input type="number" class="form-control" id="mana" name="mana" min="1" max="255" value="{$c->cData['stats']['mana']}" required>
|
||||
<input type="number" class="form-control" id="mana" name="mana" min="1" max="2097151" value="{$c->cData['stats']['mana']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="maxmana">Max Mana:</label>
|
||||
<input type="number" class="form-control" id="maxmana" name="maxmana" min="1" max="255" value="{$c->cData['stats']['maxmana']}" required>
|
||||
<input type="number" class="form-control" id="maxmana" name="maxmana" min="1" max="" value="{$c->cData['stats']['maxmana']}" required>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-row" style="background: #eed;">
|
||||
<div class="form-group col-md-6">
|
||||
<label for="stamina">Stamina:</label>
|
||||
<input type="number" class="form-control" id="stamina" name="stamina" min="1" max="255" value="{$c->cData['stats']['stamina']}" required>
|
||||
<input type="number" class="form-control" id="stamina" name="stamina" min="1" max="2097151" value="{$c->cData['stats']['stamina']}" required>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<label for="maxstamina">Max Stamina:</label>
|
||||
<input type="number" class="form-control" id="maxstamina" name="maxstamina" min="1" max="255" value="{$c->cData['stats']['maxstamina']}" required>
|
||||
<input type="number" class="form-control" id="maxstamina" name="maxstamina" min="1" max="2097151" value="{$c->cData['stats']['maxstamina']}" required>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<hr>
|
||||
<div style="background:;">
|
||||
<h3 style="text-align: center">Skills</h3>
|
||||
<div class="accordion" id="accordionExample">
|
||||
$skillDivs
|
||||
</div>
|
||||
<div class="accordion" id="accordionExample">
|
||||
$skillDivs
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col">
|
||||
|
Loading…
Reference in New Issue
Block a user