public int addGuildMember(MapleGuildCharacter mgc) { MapleGuild g = guilds.get(mgc.getGuildId()); if (g != null) { return g.addGuildMember(mgc); } return 0; }
public void disbandGuild(int gid) { synchronized (guilds) { MapleGuild g = guilds.get(gid); g.disbandGuild(); guilds.remove(gid); } }
public boolean increaseGuildCapacity(int gid) { MapleGuild g = guilds.get(gid); if (g != null) { return g.increaseCapacity(); } return false; }
public boolean setGuildAllianceId(int gId, int aId) { MapleGuild guild = guilds.get(gId); if (guild != null) { guild.setAllianceId(aId); return true; } return false; }
public void allianceMessage(int id, final byte[] packet, int exception, int guildex) { MapleAlliance alliance = alliances.get(id); if (alliance != null) { for (Integer gid : alliance.getGuilds()) { if (guildex == gid) { continue; } MapleGuild guild = guilds.get(gid); if (guild != null) { guild.broadcast(packet, exception); } } } }
public MapleGuild getGuild(int id, MapleGuildCharacter mgc) { synchronized (guilds) { if (guilds.get(id) != null) { return guilds.get(id); } if (mgc == null) { return null; } MapleGuild g = new MapleGuild(mgc); if (g.getId() == -1) { return null; } guilds.put(id, g); return g; } }
public void setGuildEmblem(int gid, short bg, byte bgcolor, short logo, byte logocolor) { MapleGuild g = guilds.get(gid); if (g != null) { g.setGuildEmblem(bg, bgcolor, logo, logocolor); } }
public void changeRankTitle(int gid, String[] ranks) { MapleGuild g = guilds.get(gid); if (g != null) { g.changeRankTitle(ranks); } }
public void memberLevelJobUpdate(MapleGuildCharacter mgc) { MapleGuild g = guilds.get(mgc.getGuildId()); if (g != null) { g.memberLevelJobUpdate(mgc); } }
public void setGuildNotice(int gid, String notice) { MapleGuild g = guilds.get(gid); if (g != null) { g.setGuildNotice(notice); } }
public void expelMember(MapleGuildCharacter initiator, String name, int cid) { MapleGuild g = guilds.get(initiator.getGuildId()); if (g != null) { g.expelMember(initiator, name, cid); } }
public int createGuild(int leaderId, String name) { return MapleGuild.createGuild(leaderId, name); }
public void guildChat(int gid, String name, int cid, String msg) { MapleGuild g = guilds.get(gid); if (g != null) { g.guildChat(name, cid, msg); } }
public void leaveGuild(MapleGuildCharacter mgc) { MapleGuild g = guilds.get(mgc.getGuildId()); if (g != null) { g.leaveGuild(mgc); } }
public void setGuildMemberOnline(MapleGuildCharacter mgc, boolean bOnline, int channel) { MapleGuild g = getGuild(mgc.getGuildId(), mgc); g.setOnline(mgc.getId(), bOnline, channel); }
public void gainGP(int gid, int amount) { MapleGuild g = guilds.get(gid); if (g != null) { g.gainGP(amount); } }
public void changeRank(int gid, int cid, int newRank) { MapleGuild g = guilds.get(gid); if (g != null) { g.changeRank(cid, newRank); } }