2moons Bank Mod

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • судя по коду все рабочее, нужно просто смотреть ошибки и допилить немножко
    Кто к нам с чем зачем, тот от того и того! :D
  • я это ' BANK' => DB_PREFIX.'bank', не могу поместить в dbtables.php, выдает сразу белый экран с ошыбками
  • USER ERROR
    Message: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '%%BANK%% WHERE user_id = '1'' at line 1

    Query-Code:SELECT * FROM %%BANK%% WHERE user_id = 1 ;
    File: /includes/classes/Database.class.php
    Line: 123
    URL: skywars.kl.com.ua/game.php?page=bank
    PHP-Version: 5.5.38
    PHP-API: fpm-fcgi
    MySQL-Client-Version: mysqlnd 5.0.11-dev - 20120503 - $Id: 15d5c781cfcad91193dceae1d2cdd127674ddb3e $
    2Moons Version: 1.8.git
    Debug Backtrace:
    #0 /includes/classes/Database.class.php(199): Database->_query('SELECT * FROM %...', Array, 'select')
    #1 /includes/pages/game/ShowBankPage.class.php(50): Database->selectSingle('SELECT * FROM %...', Array)
    #2 /game.php(57): ShowBankPage->show()
    #3 {main}
  • Потому что нужно добавлять define('BANK' , DB_PREFIX.'bank');
    Кто к нам с чем зачем, тот от того и того! :D

    The post was edited 1 time, last by aurum79 ().

  • я добавил define('BANK' , DB_PREFIX.'bank'); в dbtables но всё равно не работает пишет
    USER ERROR
    Message: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '%%BANK%% WHERE user_id = '1'' at line 1

    Query-Code:SELECT * FROM %%BANK%% WHERE user_id = 1 ;
    File: /includes/classes/Database.class.php
    Line: 123
    URL: skywars.kl.com.ua/game.php?page=bank
    PHP-Version: 5.5.38
    PHP-API: fpm-fcgi
    MySQL-Client-Version: mysqlnd 5.0.11-dev - 20120503 - $Id: 15d5c781cfcad91193dceae1d2cdd127674ddb3e $
    2Moons Version: 1.8.git
    Debug Backtrace:
    #0 /includes/classes/Database.class.php(199): Database->_query('SELECT * FROM %...', Array, 'select')
    #1 /includes/pages/game/ShowBankPage.class.php(50): Database->selectSingle('SELECT * FROM %...', Array)
    #2 /game.php(57): ShowBankPage->show()
    #3 {main}
  • The database has

    CREATE TABLE `uni1_bank` (
    `Id` int (11) unsigned NOT NULL AUTO_INCREMENT,
    `User_id` int (11) unsigned NOT NULL DEFAULT '0',
    `Bank_metal` DOUBLE (100, 0) unsigned NOT NULL DEFAULT '0',
    `Bank_cristal` DOUBLE (100, 0) unsigned NOT NULL DEFAULT '0',
    `Bank_deuterium` DOUBLE (100, 0) unsigned NOT NULL DEFAULT '0',
    `Bank_time_update` int (11) unsigned NOT NULL DEFAULT '0',
    `Bank_time_retrait` int (11) unsigned NOT NULL DEFAULT '0',
    PRIMARY KEY (`id`)
    ) ENGINE = MyISAM DEFAULT CHARSET = utf8;
  • Hey i got this error
    Undefined variable: depot_crital
    File: /includes/pages/game/class.ShowBankPage.php (Line 144)

    on line 143-145
    $PLANET['metal'] -= $depot_metal;
    $PLANET['crystal'] -= $depot_crital;
    $PLANET['deuterium'] -= $depot_deuterium;
  • yes

    /!\ Edit `uni01_bank` for database

    SQL-Query

    1. CREATE TABLE IF NOT EXISTS `uni01_bank` (
    2. `id` int(11) unsigned NOT NULL,
    3. `user_id` int(11) unsigned NOT NULL DEFAULT '0',
    4. `bank_metal` double(100,0) unsigned NOT NULL DEFAULT '0',
    5. `bank_cristal` double(100,0) unsigned NOT NULL DEFAULT '0',
    6. `bank_deuterium` double(100,0) unsigned NOT NULL DEFAULT '0',
    7. `bank_darkmatter` double(100,0) NOT NULL DEFAULT '0',
    8. `bank_time_update` int(11) unsigned NOT NULL DEFAULT '0',
    9. `bank_time_retrait` int(11) unsigned NOT NULL DEFAULT '0'
    10. ) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8;


    +

    Update files

    The post was edited 2 times, last by JudgeDead ().