75 lines
2.8 KiB
PHP
75 lines
2.8 KiB
PHP
<h2>Edit <?= $monster['name'] ?></h2>
|
|
|
|
<form action="/admin/monsters/<?= $monster['id'] ?>"
|
|
method="post"
|
|
hx-post="/admin/monsters/<?= $monster['id'] ?>"
|
|
hx-target="#main">
|
|
<table>
|
|
<colgroup><col><col></colgroup>
|
|
<tbody>
|
|
<tr>
|
|
<td>ID</td>
|
|
<td><?= $monster['id'] ?></td>
|
|
</tr>
|
|
<tr>
|
|
<td>Name</td>
|
|
<td><input type="text" name="name" value="<?= $monster['name'] ?>"></td>
|
|
</tr>
|
|
<tr>
|
|
<td>Max HP</td>
|
|
<td><input type="number" name="maxhp" value="<?= $monster['maxhp'] ?>"></td>
|
|
</tr>
|
|
<tr>
|
|
<td>Max Damage</td>
|
|
<td>
|
|
<input type="number" name="maxdam" value="<?= $monster['maxdam'] ?>"><br>
|
|
<span class="small">Compares to player's attack power.</span>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Armor</td>
|
|
<td>
|
|
<input type="number" name="armor" value="<?= $monster['armor'] ?>"><br>
|
|
<span class="small">Compares to player's defense power.</span>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Monster Level</td>
|
|
<td>
|
|
<input type="number" name="level" value="<?= $monster['level'] ?>"><br>
|
|
<span class="small">Determines spawn location and item drops.</span>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Max EXP</td>
|
|
<td>
|
|
<input type="number" name="maxexp" value="<?= $monster['maxexp'] ?>"><br>
|
|
<span class="small">Max experience gained from defeating monster.</span>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Max Gold</td>
|
|
<td>
|
|
<input type="number" name="maxgold" value="<?= $monster['maxgold'] ?>"><br>
|
|
<span class="small">Max gold gained from defeating monster.</span>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Immunity</td>
|
|
<td>
|
|
<select name="immune">
|
|
<option value="0" <?= $monster['immune'] == 0 ? 'selected' : '' ?>>None</option>
|
|
<option value="1" <?= $monster['immune'] == 1 ? 'selected' : '' ?>>Hurt Spells</option>
|
|
<option value="2" <?= $monster['immune'] == 2 ? 'selected' : '' ?>>Hurt & Sleep Spells</option>
|
|
</select>
|
|
<br>
|
|
<span class="small">Some monsters may not be hurt by certain spells.</span>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<button type="submit">Save</button>
|
|
<button type="reset">Reset</button>
|
|
</form>
|