PLMN Level 10
Брой мнения : 452 Join date : 27.12.2009 Местожителство : Варна
| Заглавие: [Release] Make WebShop GM Character Вто Май 31, 2011 11:20 am | |
| 1-рво правите 1 файл gm.php в който пишете - Код:
-
<?php iseedeadpeople(); switch (1) { default: if ($webshop['credits']['makegmchar']<1) { print phrase_blocked_module; break; } if ($_POST['cname']) { $query = mssql_query("!@#$%^ [ctlCode] from [Character] where [Name]='".$_POST['cname']."'"); $result = mssql_fetch_row($query); if ($result[0]!=$webshop['misc']['normalcode']) { print phrase_not_normal; break; } if ($webshop['credits']['makegmchar']>$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']['makegmchar']*-1).";"); mssql_query("update [Character] set [ctlCode]=8 where [Name]='".$_POST['cname']."'"); shoplog(phrase_gm_log.$_POST['cname']); print '<b>'.htmlspecialchars($_POST['cname']).'<font color=green>'.phrase_gamemaster.'</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;">Make Your Character GM!</legend> <form method="post" action=""> Make Your Character GM will cost <b>'.number_format($webshop['credits']['makegmchar']).'</b> credits<br><br> Character name <input type="text" name="cname" id="cname" maxlength="10" size="7"> <input type="submit" value="Make GM"> </fieldset> '; } ?> след това добавяте в wshmodules.php - Код:
-
define('gm', moddir.'/gm.php'); // since v0.1 След това добавяте в wshconf.php - Код:
-
$webshop['credits']['makegmchar'] = 1000; // ГМ в \lang\english.php - Код:
-
#GM 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_gamemaster', " Is Game Master"); define('phrase_menu_GM', "Get Admin Hero"); | |
|