mirror of
https://github.com/2006-Scape/Parabot.git
synced 2026-07-06 00:37:52 +00:00
Merge pull request #83 from Parabot/bugfix/new-randoms-url
Bugfix/new randoms url
This commit is contained in:
@@ -8,7 +8,6 @@ import org.parabot.environment.api.utils.Version;
|
|||||||
* @author Everel
|
* @author Everel
|
||||||
*/
|
*/
|
||||||
public class Configuration {
|
public class Configuration {
|
||||||
// public static final String LOGIN_SERVER = "https://www.parabot.org/community/api/login.php?username=%s&password=%s";
|
|
||||||
public static final String LOGIN_SERVER = "http://bdn.parabot.org/api/v2/users/login";
|
public static final String LOGIN_SERVER = "http://bdn.parabot.org/api/v2/users/login";
|
||||||
public static final String GET_SCRIPTS = "http://bdn.parabot.org/api/get.php?action=scripts_scripts&server=";
|
public static final String GET_SCRIPTS = "http://bdn.parabot.org/api/get.php?action=scripts_scripts&server=";
|
||||||
public static final String GET_SCRIPT = "http://bdn.parabot.org/api/get.php?action=scripts_script&id=";
|
public static final String GET_SCRIPT = "http://bdn.parabot.org/api/get.php?action=scripts_script&id=";
|
||||||
@@ -16,14 +15,13 @@ public class Configuration {
|
|||||||
public static final String GET_SERVER_PROVIDER = "http://bdn.parabot.org/api/get.php?action=server_provider&name=";
|
public static final String GET_SERVER_PROVIDER = "http://bdn.parabot.org/api/get.php?action=server_provider&name=";
|
||||||
public static final String GET_SERVER_PROVIDER_INFO = "http://bdn.parabot.org/api/get.php?action=server_information&name=";
|
public static final String GET_SERVER_PROVIDER_INFO = "http://bdn.parabot.org/api/get.php?action=server_information&name=";
|
||||||
public static final String GET_SERVER_SETTINGS = "http://bdn.parabot.org/api/get.php?action=get_settings";
|
public static final String GET_SERVER_SETTINGS = "http://bdn.parabot.org/api/get.php?action=get_settings";
|
||||||
public static final String GET_BOT_VERSION = "http://bdn.parabot.org/api/v2/bot/version";
|
public static final String GET_BOT_VERSION = "http://v3.bdn.parabot.org/api/bot/list/client?latest=true";
|
||||||
public static final String API_DOWNLOAD_BOT = "http://bdn.parabot.org/api/v2/bot/download/client/";
|
public static final String API_DOWNLOAD_BOT = "http://bdn.parabot.org/api/v2/bot/download/client/";
|
||||||
public static final String DOWNLOAD_BOT = "http://bdn.parabot.org/versions/";
|
public static final String DOWNLOAD_BOT = "http://bdn.parabot.org/versions/";
|
||||||
public static final String REGISTRATION_PAGE = "https://www.parabot.org/community/register/";
|
public static final String REGISTRATION_PAGE = "https://www.parabot.org/community/register/";
|
||||||
public static final String GET_RANDOMS = "http://bdn.parabot.org/api/get.php?action=randoms";
|
public static final String GET_RANDOMS = "http://v3.bdn.parabot.org/api/bot/download/randoms";
|
||||||
public static final String DATA_API = "http://bdn.parabot.org/api/v2/data/";
|
public static final String DATA_API = "http://bdn.parabot.org/api/v2/data/";
|
||||||
public static final String ITEM_API = DATA_API + "items/";
|
public static final String ITEM_API = DATA_API + "items/";
|
||||||
public static final String BUGSNAG_API = "d79752cf94dd4beb24c3d312a8609f53";
|
|
||||||
|
|
||||||
public static final Version BOT_VERSION = ProjectProperties.getProjectVersion();
|
public static final Version BOT_VERSION = ProjectProperties.getProjectVersion();
|
||||||
|
|
||||||
|
|||||||
@@ -220,7 +220,7 @@ public class Core {
|
|||||||
latestVersion = null;
|
latestVersion = null;
|
||||||
if (br != null) {
|
if (br != null) {
|
||||||
JSONObject object = (JSONObject) WebUtil.getJsonParser().parse(br);
|
JSONObject object = (JSONObject) WebUtil.getJsonParser().parse(br);
|
||||||
latestVersion = new Version((String) object.get("result"));
|
latestVersion = new Version((String) object.get("version"));
|
||||||
}
|
}
|
||||||
if (latestVersion != null) {
|
if (latestVersion != null) {
|
||||||
if (Configuration.BOT_VERSION.compareTo(latestVersion) < 0) {
|
if (Configuration.BOT_VERSION.compareTo(latestVersion) < 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user