dev #41

Merged
lopar merged 29 commits from dev into master 2021-05-25 15:28:14 +00:00
3 changed files with 48 additions and 24 deletions
Showing only changes of commit 9a75e9d949 - Show all commits

View File

@ -40,8 +40,8 @@ class UserInfo extends UserStats
}
echo '<div class="slot-image">';
if ($isBattle) {
$sh = '<img src="/i/shadow/%s" alt="%s" class="tip"><span class="tiptext"><b>%s</b>Уровень: %s<br>Сила: %s<br>Ловкость: %s<br>Интуиция: %s<br>Выносливость: %s<br>Интеллект: %s<br>Мудрость: %s</span>';
echo sprintf($sh, $this->shadow, $this->login, $this->login, $this->level, $this->strength, $this->dexterity, $this->intuition, $this->endurance, $this->intelligence, $this->wisdom);
echo sprintf('<img src="/i/shadow/%s" alt="%s" class="tip"><span class="tiptext"><b>%s</b>Уровень: %s<br>Сила: %s<br>Ловкость: %s<br>Интуиция: %s<br>Выносливость: %s<br>Интеллект: %s<br>Мудрость: %s</span>',
$this->shadow, $this->login, $this->login, $this->level, $this->strength, $this->dexterity, $this->intuition, $this->endurance, $this->intelligence, $this->wisdom);
unset($sh);
} else {
echo '<img src="/i/shadow/' . $this->shadow . '" alt="' . $this->login . '">';
@ -156,12 +156,8 @@ INFO;
echo '<hr><!-- Нижняя часть -->';
echo '<div class="user-info-container-lower">';
echo '<h2>Об игроке</h2>';
if ($this->realname) {
echo sprintf('Имя: %s<br>', $this->realname);
}
if ($this->info) {
echo nl2br($this->info);
}
echo $this->realname ? "Имя: $this->realname" : "";
echo $this->info ? "<br>" . nl2br($this->info) : "";
echo '</div><!-- user-info-container-lower -->';
echo $this->showPrivateData();
}

View File

@ -303,9 +303,40 @@ Template::header('Игра');
if (errk === 1) {
errkom = 'Нельзя использовать символы: /\:*?"<>|+%<br>';
}
document.getElementById("hint3").innerHTML = '<table width=100% cellspacing=1 cellpadding=0 bgcolor=CCC3AA><tr><td align=center><B>' + title + '</td><td width=20 align=right valign=top style="cursor: pointer" onclick="closehint3();"><BIG><B>x</td></tr><tr><td colspan=2>' +
'<form action="' + script + '" method=POST><table width=100% cellspacing=0 cellpadding=2 bgcolor=FFF6DD><tr><INPUT TYPE=hidden name=sd4 value="6"><td colspan=2><span class="error">' +
errkom + '</span>введите название предмета</TD></TR><TR><TD width=50% align=right><INPUT TYPE=text NAME="' + name + '" value="' + com + '"></TD><TD width=50%><INPUT TYPE="submit" value=" »» "></TD></TR></TABLE></FORM></td></tr></table>';
document.getElementById("hint3").innerHTML = `
<table width=100% cellspacing=1 cellpadding=0 bgcolor=CCC3AA>
<tr>
<td align=center>
<b>${title}</b>
</td>
<td width=20 align=right valign=top style='cursor: pointer' onclick='closehint3();'>
<BIG><B>x
</td>
</tr>
<tr>
<td colspan=2>
<form action="${script}" method=POST>
<table width=100% cellspacing=0 cellpadding=2 bgcolor=FFF6DD>
<tr>
<INPUT TYPE=hidden name=sd4 value='6'>
<td colspan=2>
<span class='error'>${errkom}</span> введите название предмета
</TD>
</TR>
<TR>
<TD width=50% align=right>
<INPUT TYPE=text NAME="${name}" value="${com}">
</TD>
<TD width=50%>
<INPUT TYPE='submit' value=' »» '>
</TD>
</TR>
</TABLE>
</FORM>
</td>
</tr>
</table>
`;
document.getElementById("hint3").style.visibility = "visible";
document.getElementById("hint3").style.left = '100';
document.getElementById("hint3").style.top = '100';
@ -314,13 +345,12 @@ Template::header('Игра');
}
</script>
<div id=hint3 class=ahint></div>
<div id="hint4" style="position: absolute;"></div>
<div id="chpassbank" style="display:none; position:absolute; top:50px; left:250px;"></div>
<table width=100%>
<table style="width: 100%">
<TR>
<td style="vertical-align: top; width: 350px">
<?php $userInfo->showUserDoll(0, 1); ?> <!-- Первый столбец -->
<div align="center">
<div style="text-align: center;">
<a href='main.php?edit=1&undress=all' class="button">Снять все</a><BR>
<div class="effectList" style="padding-top: 15px; max-height: 150px; width: 220px;">
<?= show_eff_inf($user->getId()) ?>
@ -377,7 +407,7 @@ Template::header('Игра');
</div>
</div>
</td>
<td valign=top>
<td style="vertical-align: top;">
<div class="button-container"> <!--Меню-кнопки-->
<FORM METHOD=POST ACTION="?edit=1" name=f1>
<?php if ($user->getShadow() == '0.gif' || $user->getAdmin() == 1): ?>
@ -396,16 +426,16 @@ Template::header('Игра');
</div>
</div>
<div> <!--рюкзак-->
<table BORDER=0 WIDTH=100% CELLSPACING="1" CELLPADDING="2" BGCOLOR="#A5A5A5">
<table style="border: 0; padding: 2px; border-spacing: 1px; width: 100%; background-color: #a5a5a5">
<caption>Рюкзак
(масса: <?= '?? /' . $userStats->getStrength() * 4 ?>)
</caption>
<?php
foreach ($iteminfo as $ii) {
echo "<tr><td width='100' align='center' bgcolor='#d3d3d3'>";
echo "<tr><td style='width: 100px; text-align: center; background-color: #d3d3d3'>";
$ii->printImage();
$ii->printControls();
echo "<td valign='top' bgcolor='#d3d3d3'>";
echo "<td style='vertical-align: top; background-color: #d3d3d3'>";
$ii->printInfo();
}
if (!$data) {

View File

@ -39,12 +39,10 @@ Template::header('Анкета');
<a href="main.php"> на главную</a>
<h1>Анкета персонажа <?= $user->getLogin() ?></h1>
<form method="post">
<input name="name" placeholder="Реальное имя" value="<?= $user->getRealname() ?>"><br>
<select name="color" id="color">
<option value="0" selected>Чёрный</option>
<option value="1">Синий</option>
<option value="2">Зелёный</option>
</select><label for="color"></label><br>
<label>
<input name="name" placeholder="Реальное имя" value="<?= $user->getRealname() ?>">
Реальное имя
</label><br>
<textarea name="hobbie" placeholder="Хобби"><?= $user->getInfo() ?></textarea><br>
<input name="submit" type="submit">
</form>