The basic php script used for private servers to submit information about their server to the Ashita backend services. (Used to display private server information within the Ashita launcher.)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

96 lines
3.6 KiB

<?php
/**
* Ashita Private Server Collection API - Copyright (c) 2018 atom0s [[email protected]]
*
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.
* To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to
* Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
*
* By using this script, you agree to the above license and its terms.
*
* Attribution - You must give appropriate credit, provide a link to the license and indicate if changes were
* made. You must do so in any reasonable manner, but not in any way that suggests the licensor
* endorses you or your use.
*
* Non-Commercial - You may not use the material (this script) for commercial purposes.
*
* No-Derivatives - If you remix, transform, or build upon the material (this script), you may not distribute the
* modified material. You are, however, allowed to submit the modified works back to the original
* Ashita Private Server Collection API project in attempt to have it added to the original project.
*
* You may not apply legal terms or technological measures that legally restrict others
* from doing anything the license permits.
*
* You may contact me, atom0s, at [email protected] for more information or if you are seeking commercial use.
*
* No warranties are given.
*/
// Prevent hack attempts..
if (!defined('ASHITA_PSCAPI')) { exit; }
/**
* Database Configurations
*
* host (string)
* The MySQL server host name to connect to.
*
* port (string)
* The MySQL server port to connect on.
*
* user (string)
* The MySQL username of the account to login with.
*
* pass (string)
* The MySQL password of the account to login with.
*
* name (string)
* The MySQL database name to query informaton from.
*/
$config['db']['host'] = 'localhost';
$config['db']['port'] = '3306';
$config['db']['user'] = 'root';
$config['db']['pass'] = 'root';
$config['db']['name'] = 'dspdb';
/**
* Cache Configurations
*
* lifetime (number)
* The amount of time, in seconds, the cache.json file should be used to retain information.
* This is used so that the database is not queried constantly each attempt this script is ran.
*/
$config['cache']['lifetime'] = 300;
/**
* Server Configurations
*
* lifetime
* The amount of time, in seconds, Ashita's server should hold onto your servers cached data
* before it will attempt to query your server again for new information. This is used so that
* Ashita's server does not constantly request information from your server.
*
* name
* The name of the server that will be displayed in the server list.
*
* levelcap
* The maximum level players can reach on your server.
*
* ip
* The connection string / IP used to connect to your server.
*
* website
* The home website for your server. (Can be left blank.)
*
* discord
* The Discord invite code for your servers general chat that players can use to join and chat
* to other players of your server. (This should be JUST the invite code, not the full url.)
*/
$config['server']['lifetime'] = 300;
$config['server']['name'] = 'MyServerName';
$config['server']['levelcap'] = 75;
$config['server']['ip'] = '127.0.0.1';
$config['server']['website'] = 'https://www.google.com/';
$config['server']['discord'] = 'CfZu6Ya';