Skip to content

Commit

Permalink
at least it boots now
Browse files Browse the repository at this point in the history
potion data is so fucked up man
  • Loading branch information
JRoy committed May 1, 2024
1 parent 3749402 commit 0decadb
Showing 1 changed file with 10 additions and 4 deletions.
Expand Up @@ -224,7 +224,8 @@ public Collection<String> listNames() {
public static class ItemData {
private Material material;
private String[] fallbacks = null;
private PotionMetaProvider.AbstractPotionData potionData = null;
// todo unfuck all of this
//private PotionMetaProvider.AbstractPotionData potionData = null;
private EntityType entity = null;

ItemData(final Material material) {
Expand All @@ -233,7 +234,7 @@ public static class ItemData {

ItemData(final Material material, final PotionMetaProvider.AbstractPotionData potionData) {
this.material = material;
this.potionData = potionData;
//this.potionData = potionData;
}

ItemData(final Material material, final EntityType entity) {
Expand All @@ -243,7 +244,8 @@ public static class ItemData {

@Override
public int hashCode() {
return (31 * material.hashCode()) ^ potionData.hashCode();
return 31 * material.hashCode();
//return (31 * material.hashCode()) ^ potionData.hashCode();
}

@Override
Expand All @@ -268,21 +270,25 @@ public Material getMaterial() {
}

public PotionMetaProvider.AbstractPotionData getPotionData() {
return this.potionData;
return null;
//return this.potionData;
}

public EntityType getEntity() {
return this.entity;
}

private boolean potionDataEquals(final ItemData o) {
return true;
/*
if (this.potionData == null && o.getPotionData() == null) {
return true;
} else if (this.potionData != null && o.getPotionData() != null) {
return this.potionData.equals(o.getPotionData());
} else {
return false;
}
*/
}

private boolean entityEquals(final ItemData o) {
Expand Down

0 comments on commit 0decadb

Please sign in to comment.