- Joined
- Apr 1, 2009
- Messages
- 1,220
- Reaction score
- 1,281
Без Command(DL)
Отивате в webshop/modules/ и правите нов файл с име: rs.php в който слагате това:
след това отивате в webshop/ и слагате в wshconf.php това:
след това отивате в webshop/ и слагате в wshmodules.php това:
след това отивате в webshop/ и слагате в Menu_Config.inc това:
Дойде време и за езиците отивате в webshop/lang и във всички файлове добавяте това:
Тествано е и работи.
С Command(DL)
Отивате в webshop/modules/ и правите нов файл с име: rs.php в който слагате това:
след това отивате в webshop/ и слагате в wshconf.php това:
след това отивате в webshop/ и слагате в wshmodules.php това:
след това отивате в webshop/ и слагате в Menu_Config.inc това:
Дойде време и за езиците отивате в webshop/lang и във всички файлове добавяте това:
Не е Тествано и най-вероятно работи.
Направено за: AirwaveS
Моля използвайте
Отивате в webshop/modules/ и правите нов файл с име: rs.php в който слагате това:
PHP:
<?php
$query1 = mssql_query("select [Strength],[Dexterity],[Vitality],[Energy],[LevelUpPoint],[AccountID] from [Character] where [Name]='".$_POST['cname']."'");
$result1 = mssql_fetch_row($query1);
$newstats = $result1[0]+$result1[1]+$result1[2]+$result1[3]+$result1[4];
$acc1 = $result1[5];
switch (1) {
default:
if ($webshop['credits']['rs']<1) {
print phrase_blocked_module;
break;
}
if ($_POST['cname']) {
$query = mssql_query("select [AccountID],[LevelUpPoint],[Strength],[Dexterity],[Vitality],[Energy] from [Character] where where [Name]='".secure($_POST['cname'])."' and [AccountID]='".$GLOBALS['mu_user']."'");
$result = mssql_fetch_row($query);
if ($acc1!=$GLOBALS['mu_user']) {
print phrase_character;
break;
}
if ($result[0]!=$webshop['misc']['normalcode']) {
print phrase_not_normal;
break;
}
if ($webshop['credits']['rs']>$mycreds) {
print phrase_lack_credits;
break;
}
if (in_array(strtolower($_POST['cname']), explode(',', $webshop['misc']['solidbans']))) {
print phrase_permbancantgm;
break;
}
mssql_query("exec XCredits '".$GLOBALS['mu_user']."', ".($webshop['credits']['rs']*-1).";");
mssql_query("update [Character] set [Strength]=0, [Dexterity]=0, [Vitality]=0, [Energy]=0, [LevelUpPoint]='".($newstats)."' where [Name]='".$_POST['cname']."'");
shoplog(phrase_gm_log.$_POST['cname']);
print '<b>'.htmlspecialchars($_POST['cname']).'<font color=green>'.phrase_resetscore.' and '.$newstats.' Points</font></b><br><br>';
}
print '<fieldset style="width: 300px;background-color: #DDDDDD;border: 1px solid #000000; font-family: arial; font-size: 12px;"><legend class="mu_style2" style="padding: 3px;font-weight:bold;background-color: #DDDDDD;border: 1px solid #000000;border-bottom:0px;">RESET STATS</legend>
<form method="post" action="">
Reset Stats will cost <b>'.number_format($webshop['credits']['rs']).'</b> credits<br><br>
Character name <input type="text" name="cname" id="cname" maxlength="10" size="7">
<input type="submit" value="Reset Stats">
</fieldset>
';
}
?>
PHP:
$webshop['credits']['rs'] = 50;
PHP:
define('rs', moddir.'/rs.php'); //
PHP:
// reset score
if ($webshop['credits']['rs']) $menu -> item(phrase_menu_resetscore, 'index.php?sy=rs');
PHP:
#resetscore
define('phrase_character', "Character is not Your");
define('phrase_not_normal', "Your Character Is Banned or GameMaster");
define('phrase_lack_credits', "You do not have enough credits to do that.");
define('phrase_resetscore', " is <font color=red>0 Strength</font> 0 Dexterity <font color = red>0 Vitality</font> 0 Energy");
define('phrase_menu_resetscore', "Reset Score");
С Command(DL)
Отивате в webshop/modules/ и правите нов файл с име: rs.php в който слагате това:
PHP:
<?php
$query1 = mssql_query("select [Strength],[Dexterity],[Vitality],[Energy],[LevelUpPoint],[Leadership],[AccountID] from [Character] where [Name]='".$_POST['cname']."'");
$result1 = mssql_fetch_row($query1);
$newstats = $result1[0]+$result1[1]+$result1[2]+$result1[3]+$result1[4]+$result1[5];
$acc1 = $result1[6];
switch (1) {
default:
if ($webshop['credits']['rs']<1) {
print phrase_blocked_module;
break;
}
if ($_POST['cname']) {
$query = mssql_query("select [AccountID],[LevelUpPoint],[Strength],[Dexterity],[Vitality],[Energy],[Leadership] from [Character] where where [Name]='".secure($_POST['cname'])."' and [AccountID]='".$GLOBALS['mu_user']."'");
$result = mssql_fetch_row($query);
if ($acc1!=$GLOBALS['mu_user']) {
print phrase_character;
break;
}
if ($result[0]!=$webshop['misc']['normalcode']) {
print phrase_not_normal;
break;
}
if ($webshop['credits']['rs']>$mycreds) {
print phrase_lack_credits;
break;
}
if (in_array(strtolower($_POST['cname']), explode(',', $webshop['misc']['solidbans']))) {
print phrase_permbancantgm;
break;
}
mssql_query("exec XCredits '".$GLOBALS['mu_user']."', ".($webshop['credits']['rs']*-1).";");
mssql_query("update [Character] set [Strength]=0, [Dexterity]=0, [Vitality]=0, [Energy]=0, [LevelUpPoint]='".($newstats)."' where [Name]='".$_POST['cname']."'");
shoplog(phrase_gm_log.$_POST['cname']);
print '<b>'.htmlspecialchars($_POST['cname']).'<font color=green>'.phrase_resetscore.' and '.$newstats.' Points</font></b><br><br>';
}
print '<fieldset style="width: 300px;background-color: #DDDDDD;border: 1px solid #000000; font-family: arial; font-size: 12px;"><legend class="mu_style2" style="padding: 3px;font-weight:bold;background-color: #DDDDDD;border: 1px solid #000000;border-bottom:0px;">RESET STATS</legend>
<form method="post" action="">
Reset Stats will cost <b>'.number_format($webshop['credits']['rs']).'</b> credits<br><br>
Character name <input type="text" name="cname" id="cname" maxlength="10" size="7">
<input type="submit" value="Reset Stats">
</fieldset>
';
}
?>
PHP:
$webshop['credits']['rs'] = 50;
PHP:
define('rs', moddir.'/rs.php'); //
PHP:
// reset score
if ($webshop['credits']['rs']) $menu -> item(phrase_menu_resetscore, 'index.php?sy=rs');
PHP:
#resetscore
define('phrase_character', "Character is not Your");
define('phrase_not_normal', "Your Character Is Banned or GameMaster");
define('phrase_lack_credits', "You do not have enough credits to do that.");
define('phrase_resetscore', " is <font color=red>0 Strength</font> 0 Dexterity <font color = red>0 Vitality</font> 0 Energy <font color = red>0 Command</font>");
define('phrase_menu_resetscore', "Reset Score");
Направено за: AirwaveS
Моля използвайте
Last edited: