* added faq management - add/edit/move/hide/delete from website

* moved install pages to twig
* load monsters and spells on installation of the AAC
This commit is contained in:
slawkens
2017-10-12 17:40:02 +02:00
parent 315e0400ff
commit f84ae88aa4
27 changed files with 683 additions and 361 deletions

View File

@@ -1057,6 +1057,26 @@ function get_templates()
return $ret;
}
/**
* Generates list of installed plugins
* @return array $plugins
*/
function get_plugins()
{
$ret = array();
$path = PLUGINS;
foreach(scandir($path) as $file) {
$file_ext = pathinfo($file, PATHINFO_EXTENSION);
$file_name = pathinfo($file, PATHINFO_FILENAME);
if ($file == '.' || $file == '..' || $file == 'disabled' || $file == 'example.json' || is_dir($path . $file) || $file_ext != 'json')
continue;
$ret[] = str_replace('.json', '', $file_name);
}
return $ret;
}
function getWorldName($id)
{
global $config;