战力单位显示
This commit is contained in:
parent
8651c4f874
commit
b94954ac49
|
|
@ -4035,6 +4035,8 @@ public class MapleCharacter extends AbstractAnimatedMapleMapObject implements Se
|
||||||
statup.put(MapleStat.EXP, exp);
|
statup.put(MapleStat.EXP, exp);
|
||||||
statup.put(MapleStat.LEVEL, (long) level);
|
statup.put(MapleStat.LEVEL, (long) level);
|
||||||
this.client.sendPacket(MaplePacketCreator.updatePlayerStats(statup, this));
|
this.client.sendPacket(MaplePacketCreator.updatePlayerStats(statup, this));
|
||||||
|
|
||||||
|
c.getSession().write(MaplePacketCreator.fuckGuildInfo(c.getPlayer()));
|
||||||
}
|
}
|
||||||
public void levelUp() {
|
public void levelUp() {
|
||||||
if (this.getLevel() >= this.maxLevel) {
|
if (this.getLevel() >= this.maxLevel) {
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@ public class MapleMonster extends AbstractLoadedMapleLife {
|
||||||
private long hp;
|
private long hp;
|
||||||
private BigInteger bigIntHp;
|
private BigInteger bigIntHp;
|
||||||
|
|
||||||
private int bs = 1;
|
private BigInteger bs = BigInteger.ONE;
|
||||||
|
|
||||||
private BigInteger hpmax ;
|
private BigInteger hpmax ;
|
||||||
private long nextKill;
|
private long nextKill;
|
||||||
|
|
@ -205,9 +205,13 @@ public class MapleMonster extends AbstractLoadedMapleLife {
|
||||||
this.hpmax = this.bigIntHp;
|
this.hpmax = this.bigIntHp;
|
||||||
|
|
||||||
if (i1 > 0) {
|
if (i1 > 0) {
|
||||||
int i = bigIntHpstr.length() - 18;
|
int i2 = bigIntHpstr.length() - 18;
|
||||||
bs = (int) Math.pow(10, i - 1);
|
String bss = "1";
|
||||||
BigInteger divide = bigIntHp.divide(BigInteger.valueOf(bs));
|
for (int i = 0; i < i2; i++) {
|
||||||
|
bss += "0";
|
||||||
|
}
|
||||||
|
this.bs =new BigInteger(bss);
|
||||||
|
BigInteger divide = bigIntHp.divide(this.bs);
|
||||||
hp = divide.longValue();
|
hp = divide.longValue();
|
||||||
}else {
|
}else {
|
||||||
setHp(Long.parseLong(bigIntHpstr));
|
setHp(Long.parseLong(bigIntHpstr));
|
||||||
|
|
@ -316,7 +320,7 @@ public class MapleMonster extends AbstractLoadedMapleLife {
|
||||||
bigIntHp = bigIntHp.subtract(damage);
|
bigIntHp = bigIntHp.subtract(damage);
|
||||||
}
|
}
|
||||||
|
|
||||||
BigInteger divide = damage.divide(BigInteger.valueOf(bs));
|
BigInteger divide = damage.divide(bs);
|
||||||
int i1 = divide.compareTo(new BigInteger("9223372036854775807"));
|
int i1 = divide.compareTo(new BigInteger("9223372036854775807"));
|
||||||
if (i1 > 0){
|
if (i1 > 0){
|
||||||
divide =new BigInteger("9223372036854775806");
|
divide =new BigInteger("9223372036854775806");
|
||||||
|
|
|
||||||
|
|
@ -898,19 +898,33 @@ public class MaplePacketCreator {
|
||||||
xl = "[☆超级王者☆]";
|
xl = "[☆超级王者☆]";
|
||||||
else if (chr.getCombat() > 1100000)
|
else if (chr.getCombat() > 1100000)
|
||||||
xl = "[☆宇宙王者☆]";
|
xl = "[☆宇宙王者☆]";
|
||||||
|
|
||||||
|
|
||||||
|
String name="";
|
||||||
|
if (Start.zlkg == 1) {
|
||||||
|
int 转生次数 = chr.getAccountidLogByCid("飞升");
|
||||||
|
int cs = 转生次数;
|
||||||
|
name = "转生次数" + cs + "层";
|
||||||
|
for (ZLConfig zlConfig : Start.zlConfigs) {
|
||||||
|
if (zlConfig.getNum() <= 转生次数) {
|
||||||
|
name = zlConfig.getName() + (转生次数 - zlConfig.getNum()) + zlConfig.getName2();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (chr.getGuildId() <= 0) {
|
if (chr.getGuildId() <= 0) {
|
||||||
mplew.writeMapleAsciiString("战力:" + chr.getCombat());
|
mplew.writeMapleAsciiString("战力:" + chr.getCombat() +name);
|
||||||
mplew.writeZeroBytes(6);
|
mplew.writeZeroBytes(6);
|
||||||
} else {
|
} else {
|
||||||
final MapleGuild gs = Guild.getGuild(chr.getGuildId());
|
final MapleGuild gs = Guild.getGuild(chr.getGuildId());
|
||||||
if (gs != null) {
|
if (gs != null) {
|
||||||
mplew.writeMapleAsciiString("[" + gs.getName() + "] - 战力:" + chr.getCombat());
|
mplew.writeMapleAsciiString("[" + gs.getName() + "] - 战力:" + chr.getCombat()+name);
|
||||||
mplew.writeShort(gs.getLogoBG());
|
mplew.writeShort(gs.getLogoBG());
|
||||||
mplew.write(gs.getLogoBGColor());
|
mplew.write(gs.getLogoBGColor());
|
||||||
mplew.writeShort(gs.getLogo());
|
mplew.writeShort(gs.getLogo());
|
||||||
mplew.write(gs.getLogoColor());
|
mplew.write(gs.getLogoColor());
|
||||||
} else {
|
} else {
|
||||||
mplew.writeMapleAsciiString(" 战力:" + chr.getCombat());
|
mplew.writeMapleAsciiString("战力:" + chr.getCombat()+" "+name);
|
||||||
mplew.writeZeroBytes(6);
|
mplew.writeZeroBytes(6);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -2947,13 +2961,26 @@ public class MaplePacketCreator {
|
||||||
xl = "[☆超级王者☆]";
|
xl = "[☆超级王者☆]";
|
||||||
else if (c.getCombat() > 1100000)
|
else if (c.getCombat() > 1100000)
|
||||||
xl = "[☆宇宙王者☆]";
|
xl = "[☆宇宙王者☆]";
|
||||||
|
String name="";
|
||||||
|
if (Start.zlkg == 1) {
|
||||||
|
int 转生次数 = c.getAccountidLogByCid("飞升");
|
||||||
|
int cs = 转生次数;
|
||||||
|
name = "转生次数" + cs + "层";
|
||||||
|
for (ZLConfig zlConfig : Start.zlConfigs) {
|
||||||
|
if (zlConfig.getNum() <= 转生次数) {
|
||||||
|
name = zlConfig.getName() + (转生次数 - zlConfig.getNum()) + zlConfig.getName2();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (c != null) {
|
if (c != null) {
|
||||||
mplew.writeMapleAsciiString("[" + guild.getName() + "] - 战力:" + c.getCombat());
|
|
||||||
|
mplew.writeMapleAsciiString("[" + guild.getName() + "] - 战力:" + c.getCombat()+name);
|
||||||
} else {
|
} else {
|
||||||
mplew.writeMapleAsciiString("[" + guild.getName() + "] - 战力:" + c.getCombat());
|
mplew.writeMapleAsciiString("[" + guild.getName() + "] - 战力:" + c.getCombat() + name);
|
||||||
}
|
}
|
||||||
for (int i = 1; i <= 5; ++i) {
|
for (int i = 1; i <= 5; ++i) {
|
||||||
mplew.writeMapleAsciiString(guild.getRankTitle(i));
|
mplew.writeMapleAsciiString("战力:" + c.getCombat()+" "+name);
|
||||||
}
|
}
|
||||||
guild.addMemberData(mplew);
|
guild.addMemberData(mplew);
|
||||||
mplew.writeInt(guild.getCapacity());
|
mplew.writeInt(guild.getCapacity());
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue