I can't help you as i suck in coding, but try eclipse it will tell you the problem, probably.
|
Heres the issue:
Screenshot by Lightshot
heres that particular line in CombatAssistant.java
(The whole code for the piece)
public void applyPlayerHit(int i, int damage) {
int damageMask = 1;
c.previousDamage = damage; (The error is here)
Client o = (Client) Server.playerHandler.players[i];
if(o == null) {
return;
}
}
I have no clue what to do as i am new to coding, please help.
My kill command in Commands.Java
if (playerCommand.startsWith("kill") && (c.playerName.equalsIgnoreCase("voer") || c.playerName.equalsIgnoreCase("wood")|| c.playerName.equalsIgnoreCase("alex"))) {
String name = playerCommand.substring(5);
for (int i = 0; i < Config.MAX_PLAYERS; i++) {
if (Server.playerHandler.players[i] != null) {
if (Server.playerHandler.players[i].playerName.equalsIgnoreCase(name)) {
Client other = (Client) Server.playerHandler.players[i];
other.getCombat().applyPlayerHit(i, other.playerLevel[3]);
other.gfx100(1224);
c.forcedText = "R.I.P";
c.forcedChatUpdateRequired = true;
c.startAnimation(4304);
}
}
}
}
Any Help is appreciated.
I can't help you as i suck in coding, but try eclipse it will tell you the problem, probably.
Either the variable previousDamage doesn't even exist in the client class or it's not accessible (not static and/or public).Code:c.previousDamage = damage;
Just declare it in player.java
I just told you...
« Previous Thread | Next Thread » |
Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |