Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void korasiMultiHit(int damage) {
- for (Player p : Server.playerHandler.players) {
- Client person = (Client) p;
- if (p != null && p != c) {
- Client otherPlayers = (Client) p;
- if (person.distanceToPoint(c.absX, c.absY) == 0) {
- //do stuff here for when player is under you
- } else if (person.distanceToPoint(c.absX, c.absY) == 1) {
- otherPlayers.handleHitMask(damage, CombatType.MAGE);
- otherPlayers.dealDamage(damage);
- } else if (person.distanceToPoint(c.absX, c.absY) == 2) {
- otherPlayers.handleHitMask(damage / 2, CombatType.MAGE);
- otherPlayers.dealDamage(damage / 2);
- } else if (person.distanceToPoint(c.absX, c.absY) == 3) {
- otherPlayers.handleHitMask(damage / 4, CombatType.MAGE);
- otherPlayers.dealDamage(damage / 4);
- }
- otherPlayers.getPA().refreshSkill(3);
- //otherPlayers.CIcon = 2;
- otherPlayers.gfx100(1248);
- }
- }
- }
- public void korasiMultiHitNPC(int damage) {
- for (NPC n : Server.npcHandler.npcs) {
- Client npc = (Client) n;
- if (n != null && n != c) {
- Client otherNPCs = (Client) n;
- if (npc.distanceToPoint(c.absX, c.absY) == 0) {
- //do stuff here for when player is under you
- } else if (npc.distanceToPoint(c.absX, c.absY) == 1) {
- otherNPCs.handleHitMask(damage, CombatType.MAGE);
- otherNPCs.dealDamage(damage);
- } else if (npc.distanceToPoint(c.absX, c.absY) == 2) {
- otherNPCs.handleHitMask(damage / 2, CombatType.MAGE);;
- otherNPCs.dealDamage(damage / 2);
- } else if (npc.distanceToPoint(c.absX, c.absY) == 3) {
- otherNPCs.handleHitMask(damage / 4, CombatType.MAGE);
- otherNPCs.dealDamage(damage / 4);
- }
- otherNPCs.getPA().refreshSkill(3);
- otherNPCs.gfx100(1248);
- }
- }
- }
Add Comment
Please, Sign In to add comment