API Changes:

-Implemented interfaces for all jobs & roles.

ScriptPlayer:
-Added getData() function, which returns player data objects.

IPlayerData: New class that holds all player data for modification.
-Holds dialog, bank, quest, transport, faction, item giver, and mail data.
-Also holds companion data, with functions has/set/getCompanion, and a getCompanionID function to differentiate companions.
This commit is contained in:
Luis C.M committed 2022-06-12 01:26:23 -05:00
1 parent 587f63396f
commit 63a1525ee2
66 files changed
+1418 -207

No files matched your search

@@ -1,8 +1,10 @@
package noppes.npcs.controllers.data;
import net.minecraft.nbt.NBTTagCompound;
import noppes.npcs.controllers.TransportController;
import noppes.npcs.scripted.interfaces.handler.data.ITransportLocation;
public class TransportLocation {
public class TransportLocation implements ITransportLocation {
public int id = -1;
public String name = "default name";
public double posX;
@@ -41,4 +43,54 @@ public class TransportLocation {
public boolean isDefault() {
return type == 1;
}
public int getId() {
return id;
}
public void setName(String name) {
this.name = name;
}
public String getName() {
return name;
}
public void setDimension(int dimension) {
this.dimension = dimension;
}
public int getDimension() {
return dimension;
}
public void setType(int type) {
this.type = type;
}
public int getType() {
return type;
}
public void setPosition(int x, int y, int z) {
this.posX = x;
this.posY = y;
this.posZ = z;
}
public double getX() {
return posX;
}
public double getY() {
return posY;
}
public double getZ() {
return posZ;
}
public void save() {
TransportController.getInstance().saveLocation(this.category.id, this);
}
}