base mod created

This commit is contained in:
Mohammad-Ali Minaie
2018-10-08 09:07:47 -04:00
parent 0a7700c356
commit b86dedad2f
7848 changed files with 584664 additions and 1 deletions

View File

@@ -0,0 +1,73 @@
package net.minecraft.realms;
import net.minecraft.world.storage.WorldSummary;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
@SideOnly(Side.CLIENT)
public class RealmsLevelSummary implements Comparable<RealmsLevelSummary>
{
private final WorldSummary levelSummary;
public RealmsLevelSummary(WorldSummary levelSummaryIn)
{
this.levelSummary = levelSummaryIn;
}
public int getGameMode()
{
return this.levelSummary.getEnumGameType().getID();
}
public String getLevelId()
{
return this.levelSummary.getFileName();
}
public boolean hasCheats()
{
return this.levelSummary.getCheatsEnabled();
}
public boolean isHardcore()
{
return this.levelSummary.isHardcoreModeEnabled();
}
public boolean isRequiresConversion()
{
return this.levelSummary.requiresConversion();
}
public String getLevelName()
{
return this.levelSummary.getDisplayName();
}
public long getLastPlayed()
{
return this.levelSummary.getLastTimePlayed();
}
public int compareTo(WorldSummary p_compareTo_1_)
{
return this.levelSummary.compareTo(p_compareTo_1_);
}
public long getSizeOnDisk()
{
return this.levelSummary.getSizeOnDisk();
}
public int compareTo(RealmsLevelSummary p_compareTo_1_)
{
if (this.levelSummary.getLastTimePlayed() < p_compareTo_1_.getLastPlayed())
{
return 1;
}
else
{
return this.levelSummary.getLastTimePlayed() > p_compareTo_1_.getLastPlayed() ? -1 : this.levelSummary.getFileName().compareTo(p_compareTo_1_.getLevelId());
}
}
}