Dragon-Knight/templates/show_char.php
Valithor Obsidion 4d5c345528 functions.php
2025-08-14 15:47:25 -04:00

39 lines
2.1 KiB
PHP

<div class="title"><img src="/img/button_character.gif" alt="Character" title="Character"></div>
<b><?php echo $char->username ?></b><br><br>
Class: <?php echo match ($char->charclass) {
1 => DragonKnight\env('class_1_name'),
2 => DragonKnight\env('class_2_name'),
3 => DragonKnight\env('class_3_name')
}; ?><br><br>
Level: <?php echo $char->level ?><br>
Experience: <?php echo number_format($char->experience) ?>
<?php if ($char->expbonus !== 0): ?> <span class="light">(<?php echo $char->expbonus > 0 ? '+' : '' ?>) <?php echo $char->expbonus ?>%)</span> <?php endif; ?><br>
Next Level: <?php if ($char->level < 99) {
echo number_format($level[$char->charclass.'_exp']);
} else { ?> <span class="light">None</span> <?php } ?><br>
Gold: <?php echo number_format($char->gold) ?>
<?php if ($char->goldbonus !== 0): ?> <span class="light">(<?php echo $char->goldbonus > 0 ? '+' : '' ?>) <?php echo $char->goldbonus ?>%)</span> <?php endif; ?><br>
Hit Points: <?php echo number_format($char->currenthp) ?> / <?php echo number_format($char->maxhp) ?><br>
Magic Points: <?php echo number_format($char->currentmp) ?> / <?php echo number_format($char->maxmp) ?><br>
Travel Points: <?php echo number_format($char->currenttp) ?> / <?php echo number_format($char->maxtp) ?><br><br>
Strength: <?php echo number_format($char->strength) ?><br>
Dexterity: <?php echo number_format($char->dexterity) ?><br>
Attack Power: <?php echo number_format($char->attackpower) ?><br>
Defense Power: <?php echo number_format($char->defensepower) ?><br>
<br>
<div class="title"><img src="/img/button_inventory.gif" alt="Inventory" title="Inventory"></div>
<img src="/img/icon_weapon.gif" alt="Weapon" title="Weapon"> <?php echo $char->weaponname ?><br>
<img src="/img/icon_armor.gif" alt="Armor" title="Armor"> <?php echo $char->armorname ?><br>
<img src="/img/icon_shield.gif" alt="Shield" title="Shield"> <?php echo $char->shieldname ?><br>
Slot 1: <?php echo $char->slot1name ?><br>
Slot 2: <?php echo $char->slot2name ?><br>
Slot 3: <?php echo $char->slot3name ?>
<br>
<div class="title"><img src="/img/button_spells.gif" alt="Spells" title="Spells"></div>
<?php echo $magic_list ?>