Jump to content
View in the app

A better way to browse. Learn more.

OSBot :: 2007 OSRS Botting

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Get Skills (getDynamic)

Featured Replies

To get the current level of each skill and put in variables.

    int aglt;

    public int getAglt() {

        return aglt= skills.getDynamic(Skill.AGILITY);
    }

    public int setAglt(int aglt) {

        return this.aglt= skills.getDynamic(Skill.AGILITY);
    }

Work that way?

Best way to find out is to test it.

 

Out of curiosity, why are you passing in a parameter in setAglt when you aren't using it? Also, why are you setting the variable each time you call getAglt?

  • Author

Best way to find out is to test it.

 

Out of curiosity, why are you passing in a parameter in setAglt when you aren't using it? Also, why are you setting the variable each time you call getAglt?

 

That's what I was thinking of crazy things, I'm a little confused, but I want to get the current value of skill, so I want to understand how the getDynamic, how could get the current level or xp rest to evolve, something like that.

the lack of java knowledge is strong in this thread. 

 

getDynamic returns the dynamic level of the skill you want

 

ex: if your attack is 75/70 from a potion it will return 75

  • Author

the lack of java knowledge is strong in this thread. 

 

getDynamic returns the dynamic level of the skill you want

 

ex: if your attack is 75/70 from a potion it will return 75

 

How do I get the current level of skill?

  • Author

getDynamic for 1st level, getStatic for 2nd level

 

e.g.

 

75/99 hp

 

75 = getDynamic()

99 = getStatic()

 

Thanks perfect =D

 

And now how get (type)?

if (!str_said.contains(player)) {
					str_said.add(player);
					speak = getSpeak("strength");
					speak_finally = getSpeak("finally");
					if (speak != null && speak_finally!= null) {
						type(speak + skills.getStatic(Skill.STRENGTH)
								+ speak_finally);
					}
				}

Chatbox.MessageType 

 

is contains?

 

Or 

message.contains

???

Edited by Korn

Message m;

 

To get the message, you do m.getMessage()

 

String msg = m.getMessage();

 

To get the message type, you do m.getType()

 

message.getType() == MessageType.GAME for normal message (e.g. you catch some shrimp)

 

or 

 

message.getType() == MessageType.PLAYER for player messages (e.g. player says hello)

Edited by Czar

  • Author
if (!str_said.contains(player)) {
str_said.add(player);
speak= getSpeak("strength");
speak_finally = getSpeak("finally");
if (speak != null && speak_finally != null) {
message.contains(speak+ skills.getStatic(Skill.STRENGTH)
+  speak_finally);
}
}

corret?

Explain what you're trying to do and I will code it and post here

no spoon feedING.

To get the current level of each skill and put in variables.

int aglt;

    public int getAglt() {

        return aglt= skills.getDynamic(Skill.AGILITY);
    }

    public int setAglt(int aglt) {

        return this.aglt= skills.getDynamic(Skill.AGILITY);
    }
Work that way?
the set method should be a void method so it set the variable and not return the value

Message m;

 

To get the message, you do m.getMessage()

 

String msg = m.getMessage();

 

To get the message type, you do m.getType()

 

message.getType() == MessageType.GAME for normal message (e.g. you catch some shrimp)

 

or 

 

message.getType() == MessageType.PLAYER for player messages (e.g. player says hello)

use .eequal(object) and not ==

dude not to be rude, but your java naming and overall knowledge(being judged by your lack of knowledge in this thread) is horrible.  you should look at some java resources and not expect to be spoonfed 

Guest
This topic is now closed to further replies.

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.