Browse Source

Unused parm in method interface removed.

master
MagicBot 2 years ago
parent
commit
da62046ce0
  1. 2
      src/engine/devcmd/cmds/AddNPCCmd.java
  2. 4
      src/engine/gameManager/BuildingManager.java
  3. 4
      src/engine/objects/NPC.java

2
src/engine/devcmd/cmds/AddNPCCmd.java

@ -83,7 +83,7 @@ public class AddNPCCmd extends AbstractDevCmd {
} }
NPC npc = NPC.createNPC(name, contractID, NPC npc = NPC.createNPC(name, contractID,
pc.getLoc(), null, true, zone, (short)level, true, null); pc.getLoc(), null, true, zone, (short) level, null);
if (npc != null) { if (npc != null) {
WorldGrid.addObject(npc, pc); WorldGrid.addObject(npc, pc);

4
src/engine/gameManager/BuildingManager.java

@ -467,7 +467,7 @@ public enum BuildingManager {
NPC npc = null; NPC npc = null;
npc = NPC.createNPC( pirateName, NpcID.getObjectUUID(), NpcLoc, null, false, zone, (short) rank, false, building); npc = NPC.createNPC(pirateName, NpcID.getObjectUUID(), NpcLoc, null, false, zone, (short) rank, building);
if (npc == null) if (npc == null)
return false; return false;
@ -522,7 +522,7 @@ public enum BuildingManager {
return true; return true;
} }
npc = NPC.createNPC(pirateName, contract.getObjectUUID(), Vector3fImmutable.ZERO, contractOwner.getGuild(), false, zone, (short) rank, false, building); npc = NPC.createNPC(pirateName, contract.getObjectUUID(), Vector3fImmutable.ZERO, contractOwner.getGuild(), false, zone, (short) rank, building);
if (npc == null) if (npc == null)
return false; return false;

4
src/engine/objects/NPC.java

@ -975,9 +975,7 @@ public class NPC extends AbstractCharacter {
return !this.isAlive(); return !this.isAlive();
} }
// *** Refactor : this has a useInit flag that can be removed public static NPC createNPC(String name, int contractID, Vector3fImmutable spawn, Guild guild, boolean isMob, Zone parent, short level, Building building) {
public static NPC createNPC(String name, int contractID, Vector3fImmutable spawn, Guild guild, boolean isMob, Zone parent, short level, boolean useInit, Building building) {
NPC npcWithoutID = new NPC(name, (short) 0, (short) 0, (short) 0, (short) 0, NPC npcWithoutID = new NPC(name, (short) 0, (short) 0, (short) 0, (short) 0,
(short) 0, (short) 1, 0, false, false, false, spawn, spawn, Vector3fImmutable.ZERO, (short) 0, (short) 1, 0, false, false, false, spawn, spawn, Vector3fImmutable.ZERO,

Loading…
Cancel
Save