mirror of
https://github.com/2006-Scape/Parabot-317-API-Minified.git
synced 2026-07-03 08:39:09 +00:00
Merge branch 'development' into feature/accept-trade
This commit is contained in:
@@ -30,8 +30,6 @@ public interface Client {
|
||||
|
||||
int getBackDialogId();
|
||||
|
||||
int getInputDialogState();
|
||||
|
||||
int getPlane();
|
||||
|
||||
int[] getMenuActionId();
|
||||
@@ -62,4 +60,12 @@ public interface Client {
|
||||
int[] getSettings();
|
||||
|
||||
boolean isLoggedIn();
|
||||
|
||||
int getInputDialogState();
|
||||
|
||||
long[] getFriendsListAsLong();
|
||||
|
||||
void addFriend(long id);
|
||||
|
||||
void deleteFriend(long id);
|
||||
}
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
package org.rev317.min.api.methods;
|
||||
|
||||
import org.parabot.api.misc.TextUtils;
|
||||
import org.parabot.environment.api.utils.Time;
|
||||
import org.parabot.environment.scripts.framework.SleepCondition;
|
||||
import org.rev317.min.Loader;
|
||||
|
||||
/**
|
||||
* @author Everel, JKetelaar
|
||||
* @author Everel, JKetelaar, EmmaStone
|
||||
*/
|
||||
public class Game {
|
||||
|
||||
@@ -77,6 +78,15 @@ public class Game {
|
||||
return Loader.getClient().getPlane();
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the friends list long values
|
||||
*
|
||||
* @return long values of friends list
|
||||
*/
|
||||
public static long[] getFriendsListAsLong() {
|
||||
return Loader.getClient().getFriendsListAsLong();
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines whether this client has action 4 hooked
|
||||
*
|
||||
@@ -160,4 +170,20 @@ public class Game {
|
||||
public static void login(String username, String password) {
|
||||
login(username, password, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds friend
|
||||
* @param username String
|
||||
*/
|
||||
public static void addFriend(String username) {
|
||||
Loader.getClient().addFriend(TextUtils.longForName(TextUtils.fixName(username)));
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes friend
|
||||
* @param username String
|
||||
*/
|
||||
public static void deleteFriend(String username) {
|
||||
Loader.getClient().deleteFriend(TextUtils.longForName(TextUtils.fixName(username)));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user