From 717b5fdd155715c4e4ec98c021137a9a552189f3 Mon Sep 17 00:00:00 2001 From: slawkens Date: Mon, 12 Sep 2022 14:16:36 +0200 Subject: [PATCH] Add compat Gesior classes To allow more custom pages be used with myaac --- index.php | 6 ++++-- system/{compat.php => compat/base.php} | 0 system/compat/classes.php | 15 +++++++++++++++ system/{compat_pages.php => compat/pages.php} | 0 system/functions.php | 2 +- 5 files changed, 20 insertions(+), 3 deletions(-) rename system/{compat.php => compat/base.php} (100%) create mode 100644 system/compat/classes.php rename system/{compat_pages.php => compat/pages.php} (100%) diff --git a/index.php b/index.php index 3ce40bb5..cb273f17 100644 --- a/index.php +++ b/index.php @@ -314,8 +314,10 @@ if($load_it) if(SITE_CLOSED && admin()) $content .= '

Site is under maintenance (closed mode). Only privileged users can see it.

'; - if($config['backward_support']) - require SYSTEM . 'compat_pages.php'; + if($config['backward_support']) { + require SYSTEM . 'compat/pages.php'; + require SYSTEM . 'compat/classes.php'; + } $ignore = false; diff --git a/system/compat.php b/system/compat/base.php similarity index 100% rename from system/compat.php rename to system/compat/base.php diff --git a/system/compat/classes.php b/system/compat/classes.php new file mode 100644 index 00000000..051fbdf2 --- /dev/null +++ b/system/compat/classes.php @@ -0,0 +1,15 @@ + + * @copyright 2022 MyAAC + * @link https://my-aac.org + */ +defined('MYAAC') or die('Direct access not allowed!'); + +class Player extends OTS_Player {} +class Guild extends OTS_Guild {} +class GuildRank extends OTS_GuildRank {} +class House extends OTS_House {} diff --git a/system/compat_pages.php b/system/compat/pages.php similarity index 100% rename from system/compat_pages.php rename to system/compat/pages.php diff --git a/system/functions.php b/system/functions.php index fbed8384..363d7795 100644 --- a/system/functions.php +++ b/system/functions.php @@ -1486,7 +1486,7 @@ function getAccountLoginByLabel() // validator functions require_once LIBS . 'validator.php'; -require_once SYSTEM . 'compat.php'; +require_once SYSTEM . 'compat/base.php'; // custom functions require SYSTEM . 'functions_custom.php';