• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

MyAAC v0.8.13

I don't know how to change the permissions directly. Can someone please make a step by step guide for this?
The commands 'chmod 660 images/guilds' etc are for linux users? Anyways doens't do anything for me.

edit: To whom do I need to give acces on windows?

You don't need to set permissions when you're on windows. You can omit this part.

no engine version? 😭

you mean like TFS 1.2? No, because AAC don't have such information.
 
You don't need to set permissions when you're on windows. You can omit this part.



you mean like TFS 1.2? No, because AAC don't have such information.
I get this message when I try to load config:

Forbidden

You don't have permission to access /index.php on this server.
 
Installed apache2 on an ubuntu server and when I type localhost/install/index.php

I get this error.

PHP:
CACHE . 'twig/', 'auto_reload' => true )); // load installation status $step = isset($_POST['step']) ? $_POST['step'] : 'welcome'; $install_status = array(); if(file_exists(CACHE . 'install.txt')) { $install_status = unserialize(file_get_contents(CACHE . 'install.txt')); if(!isset($_POST['step'])) { $step = isset($install_status['step']) ? $install_status['step'] : ''; } } if(isset($_POST['vars'])) { foreach($_POST['vars'] as $key => $value) { $_SESSION['var_' . $key] = $value; $install_status[$key] = $value; } } else { foreach($install_status as $key => $value) { $_SESSION['var_' . $key] = $value; } } if($step == 'finish' && (!isset($config['installed']) || !$config['installed'])) { $step = 'welcome'; } // step verify $steps = array(1 => 'welcome', 2 => 'license', 3 => 'requirements', 4 => 'config', 5 => 'database', 6 => 'admin', 7 => 'finish'); if(!in_array($step, $steps)) // check if step is valid throw new RuntimeException('ERROR: Unknown step.'); $install_status['step'] = $step; $errors = array(); if($step == 'database') { foreach($_SESSION as $key => $value) { if(strpos($key, 'var_') === false) { continue; } $key = str_replace('var_', '', $key); if(in_array($key, array('account', 'password', 'email', 'player_name'))) { continue; } if($key != 'usage' && empty($value)) { $errors[] = $locale['please_fill_all']; break; } else if($key == 'server_path') { $config['server_path'] = $value; // take care of trailing slash at the end if($config['server_path'][strlen($config['server_path']) - 1] != '/') { $config['server_path'] .= '/'; } if(!file_exists($config['server_path'] . 'config.lua')) { $errors[] = $locale['step_database_error_config']; break; } } else if($key == 'mail_admin' && !Validator::email($value)) { $errors[] = $locale['step_config_mail_admin_error']; break; } else if($key == 'mail_address' && !Validator::email($value)) { $errors[] = $locale['step_config_mail_address_error']; break; } else if($key == 'timezone' && !in_array($value, DateTimeZone::listIdentifiers())) { $errors[] = $locale['step_config_timezone_error']; break; } else if($key == 'client' && !in_array($value, $config['clients'])) { $errors[] = $locale['step_config_client_error']; break; } } if(!empty($errors)) { $step = 'config'; } } else if($step == 'admin') { $config_failed = true; if(file_exists(BASE . 'config.local.php') && isset($config['installed']) && $config['installed'] && isset($_SESSION['saved'])) { $config_failed = false; } if($config_failed) { $step = 'database'; } } else if($step == 'finish') { $email = $_SESSION['var_email']; $password = $_SESSION['var_password']; $player_name = $_SESSION['var_player_name']; // email check if(empty($email)) { $errors[] = $locale['step_admin_email_error_empty']; } else if(!Validator::email($email)) { $errors[] = $locale['step_admin_email_error_format']; } // account check if(isset($_SESSION['var_account'])) { if(empty($_SESSION['var_account'])) { $errors[] = $locale['step_admin_account_error_empty']; } else if(!Validator::accountName($_SESSION['var_account'])) { $errors[] = $locale['step_admin_account_error_format']; } else if(strtoupper($_SESSION['var_account']) == strtoupper($password)) { $errors[] = $locale['step_admin_account_error_same']; } } else if(isset($_SESSION['var_account_id'])) { if(empty($_SESSION['var_account_id'])) { $errors[] = $locale['step_admin_account_id_error_empty']; } else if(!Validator::accountId($_SESSION['var_account_id'])) { $errors[] = $locale['step_admin_account_id_error_format']; } else if($_SESSION['var_account_id'] == $password) { $errors[] = $locale['step_admin_account_id_error_same']; } } // password check if(empty($password)) { $errors[] = $locale['step_admin_password_error_empty']; } else if(!Validator::password($password)) { $errors[] = $locale['step_admin_password_error_format']; } // player name check if(empty($player_name)) { $errors[] = $locale['step_admin_player_name_error_empty']; } else if(!Validator::characterName($player_name)) { $errors[] = $locale['step_admin_player_name_error_format']; } if(!empty($errors)) { $step = 'admin'; } } if(empty($errors)) { file_put_contents(CACHE . 'install.txt', serialize($install_status)); } $error = false; clearstatcache(); if(is_writable(CACHE) && (MYAAC_OS != 'WINDOWS' || win_is_writable(CACHE))) { if(!file_exists(BASE . 'install/ip.txt')) { $content = warning('AAC installation is disabled. To enable it make file ip.txt in install/ directory and put there your IP.
Your IP is:
' . $_SERVER['REMOTE_ADDR'] . '', true); } else { $file_content = trim(file_get_contents(BASE . 'install/ip.txt')); $allow = false; $listIP = preg_split('/\s+/', $file_content); foreach($listIP as $ip) { if($_SERVER['REMOTE_ADDR'] == $ip) { $allow = true; } } if(!$allow) { $content = warning('In file install/ip.txt must be your IP!
In file is:
' . nl2br($file_content) . '
Your IP is:
' . $_SERVER['REMOTE_ADDR'] . '', true); } else { ob_start(); $step_id = array_search($step, $steps); require 'steps/' . $step_id . '-' . $step . '.php'; $content = ob_get_contents(); ob_end_clean(); } } } else { $content = error(file_get_contents(BASE . 'install/includes/twig_error.html'), true); } // render require 'template/template.php'; //$_SESSION['laststep'] = $step;

Already added my public address and currently the ip.txt file has
127.0.0.1
127.0.0.2
::1
my.public.ip.adress

What am I doing wrong?


1590787192585.png
 
I get this message when I try to load config:

Forbidden

You don't have permission to access /index.php on this server.

That's not the problem with permissions. You have problem with configuration of your server. What server and OS are you using?

Installed apache2 on an ubuntu server and when I type localhost/install/index.php

I get this error.

PHP:
CACHE . 'twig/', 'auto_reload' => true )); // load installation status $step = isset($_POST['step']) ? $_POST['step'] : 'welcome'; $install_status = array(); if(file_exists(CACHE . 'install.txt')) { $install_status = unserialize(file_get_contents(CACHE . 'install.txt')); if(!isset($_POST['step'])) { $step = isset($install_status['step']) ? $install_status['step'] : ''; } } if(isset($_POST['vars'])) { foreach($_POST['vars'] as $key => $value) { $_SESSION['var_' . $key] = $value; $install_status[$key] = $value; } } else { foreach($install_status as $key => $value) { $_SESSION['var_' . $key] = $value; } } if($step == 'finish' && (!isset($config['installed']) || !$config['installed'])) { $step = 'welcome'; } // step verify $steps = array(1 => 'welcome', 2 => 'license', 3 => 'requirements', 4 => 'config', 5 => 'database', 6 => 'admin', 7 => 'finish'); if(!in_array($step, $steps)) // check if step is valid throw new RuntimeException('ERROR: Unknown step.'); $install_status['step'] = $step; $errors = array(); if($step == 'database') { foreach($_SESSION as $key => $value) { if(strpos($key, 'var_') === false) { continue; } $key = str_replace('var_', '', $key); if(in_array($key, array('account', 'password', 'email', 'player_name'))) { continue; } if($key != 'usage' && empty($value)) { $errors[] = $locale['please_fill_all']; break; } else if($key == 'server_path') { $config['server_path'] = $value; // take care of trailing slash at the end if($config['server_path'][strlen($config['server_path']) - 1] != '/') { $config['server_path'] .= '/'; } if(!file_exists($config['server_path'] . 'config.lua')) { $errors[] = $locale['step_database_error_config']; break; } } else if($key == 'mail_admin' && !Validator::email($value)) { $errors[] = $locale['step_config_mail_admin_error']; break; } else if($key == 'mail_address' && !Validator::email($value)) { $errors[] = $locale['step_config_mail_address_error']; break; } else if($key == 'timezone' && !in_array($value, DateTimeZone::listIdentifiers())) { $errors[] = $locale['step_config_timezone_error']; break; } else if($key == 'client' && !in_array($value, $config['clients'])) { $errors[] = $locale['step_config_client_error']; break; } } if(!empty($errors)) { $step = 'config'; } } else if($step == 'admin') { $config_failed = true; if(file_exists(BASE . 'config.local.php') && isset($config['installed']) && $config['installed'] && isset($_SESSION['saved'])) { $config_failed = false; } if($config_failed) { $step = 'database'; } } else if($step == 'finish') { $email = $_SESSION['var_email']; $password = $_SESSION['var_password']; $player_name = $_SESSION['var_player_name']; // email check if(empty($email)) { $errors[] = $locale['step_admin_email_error_empty']; } else if(!Validator::email($email)) { $errors[] = $locale['step_admin_email_error_format']; } // account check if(isset($_SESSION['var_account'])) { if(empty($_SESSION['var_account'])) { $errors[] = $locale['step_admin_account_error_empty']; } else if(!Validator::accountName($_SESSION['var_account'])) { $errors[] = $locale['step_admin_account_error_format']; } else if(strtoupper($_SESSION['var_account']) == strtoupper($password)) { $errors[] = $locale['step_admin_account_error_same']; } } else if(isset($_SESSION['var_account_id'])) { if(empty($_SESSION['var_account_id'])) { $errors[] = $locale['step_admin_account_id_error_empty']; } else if(!Validator::accountId($_SESSION['var_account_id'])) { $errors[] = $locale['step_admin_account_id_error_format']; } else if($_SESSION['var_account_id'] == $password) { $errors[] = $locale['step_admin_account_id_error_same']; } } // password check if(empty($password)) { $errors[] = $locale['step_admin_password_error_empty']; } else if(!Validator::password($password)) { $errors[] = $locale['step_admin_password_error_format']; } // player name check if(empty($player_name)) { $errors[] = $locale['step_admin_player_name_error_empty']; } else if(!Validator::characterName($player_name)) { $errors[] = $locale['step_admin_player_name_error_format']; } if(!empty($errors)) { $step = 'admin'; } } if(empty($errors)) { file_put_contents(CACHE . 'install.txt', serialize($install_status)); } $error = false; clearstatcache(); if(is_writable(CACHE) && (MYAAC_OS != 'WINDOWS' || win_is_writable(CACHE))) { if(!file_exists(BASE . 'install/ip.txt')) { $content = warning('AAC installation is disabled. To enable it make file ip.txt in install/ directory and put there your IP.
Your IP is:
' . $_SERVER['REMOTE_ADDR'] . '', true); } else { $file_content = trim(file_get_contents(BASE . 'install/ip.txt')); $allow = false; $listIP = preg_split('/\s+/', $file_content); foreach($listIP as $ip) { if($_SERVER['REMOTE_ADDR'] == $ip) { $allow = true; } } if(!$allow) { $content = warning('In file install/ip.txt must be your IP!
In file is:
' . nl2br($file_content) . '
Your IP is:
' . $_SERVER['REMOTE_ADDR'] . '', true); } else { ob_start(); $step_id = array_search($step, $steps); require 'steps/' . $step_id . '-' . $step . '.php'; $content = ob_get_contents(); ob_end_clean(); } } } else { $content = error(file_get_contents(BASE . 'install/includes/twig_error.html'), true); } // render require 'template/template.php'; //$_SESSION['laststep'] = $step;

Already added my public address and currently the ip.txt file has
127.0.0.1
127.0.0.2
::1
my.public.ip.adress

What am I doing wrong?


View attachment 46140

Same here, that's not an error, that is file content of install/index.php, because your server doesn't recognize PHP scripts.

I suppose as you said you installed apache2 only, that you did not install apache2-mod-php?

Try:
Code:
sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql
 
That's not the problem with permissions. You have problem with configuration of your server. What server and OS are you using?



Same here, that's not an error, that is file content of install/index.php, because your server doesn't recognize PHP scripts.

I suppose as you said you installed apache2 only, that you did not install apache2-mod-php?

Try:
Code:
sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql
Yea just noticed I never installed php just shoot me in the head pls
Post automatically merged:

Yea just noticed I never installed php just shoot me in the head pls

When I try to create an admin account and player account this error pops up

1590791921658.png
 
Last edited:
Yea just noticed I never installed php just shoot me in the head pls
Post automatically merged:



When I try to create an admin account and player account this error pops up

View attachment 46144

If you are using Nostalrius, then change "number" to "name" in accounts table, then follow the installation again.
 
That's not the problem with permissions. You have problem with configuration of your server. What server and OS are you using?
I'm using otservbr-global-develop on windows 10, UniserverZ and myaac 0.8.0.
 
is it an older version of otservbr? as it doesn't have number in table structure.

SQL:
CREATE TABLE IF NOT EXISTS `accounts` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(32) NOT NULL,
  `password` char(40) NOT NULL,
  `secret` char(16) DEFAULT NULL,
  `type` int(11) NOT NULL DEFAULT '1',
  `premdays` int(11) NOT NULL DEFAULT '0',
  `coins` int(12) NOT NULL DEFAULT '0',
  `lastday` int(10) UNSIGNED NOT NULL DEFAULT '0',
  `email` varchar(255) NOT NULL DEFAULT '',
  `creation` int(11) NOT NULL DEFAULT '0',
  `passed` int(11) NOT NULL DEFAULT '0',
  `block` int(11) NOT NULL DEFAULT '0',
  `refresh` int(11) NOT NULL DEFAULT '0',
  `authToken` varchar(100) NOT NULL DEFAULT '',
  CONSTRAINT `accounts_pk` PRIMARY KEY (`id`),
  CONSTRAINT `accounts_unique` UNIQUE (`name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
 
is it an older version of otservbr? as it doesn't have number in table structure.
I'm using the latest version from github, I've seen in the c++ file definitions.h:
static constexpr auto CLIENT_VERSION_MIN = 1200;
static constexpr auto CLIENT_VERSION_MAX = 1200;
static constexpr auto CLIENT_VERSION_STR = "12.00";
 
I'm using the latest version from github, I've seen in the c++ file definitions.h:
static constexpr auto CLIENT_VERSION_MIN = 1200;
static constexpr auto CLIENT_VERSION_MAX = 1200;
static constexpr auto CLIENT_VERSION_STR = "12.00";
Well you aren't using the original schema from the github i posted.
Ensure your database matches, if you are using otservbr it needs the name column in the table.
so just alter your table and add name varchar(32) NOT NULL, and make it unique.

As slawkens said you need to replace number with name.
But you may have more issues after if you don't use the schema.
Link the database schema you are using.
 
Well you aren't using the original schema from the github i posted.
Ensure your database matches, if you are using otservbr it needs the name column in the table.
so just alter your table and add name varchar(32) NOT NULL, and make it unique.

As slawkens said you need to replace number with name.
But you may have more issues after if you don't use the schema.
Link the database schema you are using.
I've started from scratch, used Xampp this time, and it works like a charm so far, thanks for the time you put into this!
 
Hello,

I tried to edit the skills of knight, sorc, druid, pally sample in phpmyadmin, but it only works for the magic level when I create new chars.
Something I forgot for distance, sword, club, axe, shielding? Or is it easier to just give skills on first login?

Thanks in advance
 
First of all, thank you for bring in this contribution for the community.

I have some doubts about details that aren't really important:
1 - It's possible to add the featured article at news?
2 - I found a topic for most powerful guilds for 1.2, is there any for 1.3?
3 - Is there any Guild Wars for myaac? I couldn't find anything.
 
1. You mean this?
1591130086893.png
## [0.7.0 - 20.11.2017]
* added featured article to tibiacom template (you can add them with add news button)
In newest version just use the admin panel news editor. Last column

2. I believe the code is exactly the same for most powerful guild between those 2 versions?
Try that and see if it works.

3. not at the moment, I had started on one but never got around to getting it functional.
 
Hello,

I have a problem with character_samples, it's enabled in config.php, and when I create a new character it works as intended, it gives the equipment, level, outfit, mlvl, everything but not the skills: fist, sword, club, axe, distance, shielding.

example:
I edit the knight_sample in database
level : 20
maglevel : 1
skill_club : 35
skill_sword : 35
skill_axe : 35
skill_shielding : 25

On creating a knight he will be level 20 with 1 magic level and 10 sword/axe/club/shield

Can someone give me a little help here?

Thanks in advance
 
This looks awesome, will give it a try.
6d31aaa71a4b817e91ead8aa987c4fa9.png

Lua:
Unable to create the cache directory (/var/www/html/system/cache/twig/c2).


[B]Backtrace:[/B]

#0 /var/www/html/system/libs/Twig/Environment.php(487): Twig\Cache\FilesystemCache->write('/var/www/html/s...', ' #1 /var/www/html/system/libs/Twig/Environment.php(445): Twig\Environment->loadClass('__TwigTemplate_...', 'account.login.h...', NULL)
#2 /var/www/html/system/libs/Twig/Environment.php(423): Twig\Environment->loadTemplate('account.login.h...')
#3 /var/www/html/system/libs/Twig/Environment.php(399): Twig\Environment->load('account.login.h...')
#4 /var/www/html/system/pages/accountmanagement.php(41): Twig\Environment->display('account.login.h...', Array)
#5 /var/www/html/index.php(360): require('/var/www/html/s...')
#6 {main}
 
Last edited:
A funny issue in the install sequence - it assumes you are accessing /install from localhost, and resolves the IP that it wants you to add to /install/ip.txt from your accessing connection, which is incorrect if you are accessing it remotely. It won't let you past unless the IP's match.

I got around this by tunnelling my connection through the server real quick 😂
I'd suggest changing the way this works or adding a skip button
 
Back
Top