Skip to content

Commit

Permalink
bump mantle, add in objectholder
Browse files Browse the repository at this point in the history
  • Loading branch information
progwml6 committed Jun 8, 2014
1 parent 6fb5b37 commit 1dc0499
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 62 deletions.
14 changes: 9 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ buildscript {

}
dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:1.1-SNAPSHOT'
classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
}
}

Expand All @@ -31,12 +31,16 @@ repositories {
url "http://chickenbones.net/maven/"
}
maven {
name "ProfMobius Maven FS"
url "http://mobiusstrip.eu/maven"
}
maven {
name 'DVS1 Maven FS'
url 'http://dvs1.progwml6.com/files/maven'
}
maven {
name 'ForgeFS'
url 'http://files.minecraftforge.net/maven'
}
maven {
name 'ForgeFS'
url 'http://files.minecraftforge.net/maven'
}
}

Expand Down
6 changes: 3 additions & 3 deletions build.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
minecraft_version=1.7.2
forge_version=10.12.0.1033
mantle_version=132.45b0b50
tconstruct_version=1.6.0.jenkins413
forge_version=10.12.1.1101
mantle_version=145.3a637c2
tconstruct_version=1.6.0.jenkins497
FMP_version=1.1.0.268
CCLIB_version=1.1.0.77
NEI_version=1.0.1
Expand Down
14 changes: 4 additions & 10 deletions src/main/java/mods/natura/Natura.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,15 @@ public class Natura
/* Proxies for sides, used for graphics processing */
@SidedProxy(clientSide = "mods.natura.client.NProxyClient", serverSide = "mods.natura.common.NProxyCommon")
public static NProxyCommon proxy;

public static final String modID = "Natura";
/* Instance of this mod, used for grabbing prototype fields */
@Instance("Natura")
@Instance(modID)
public static Natura instance;
public static Material cloud = new CloudMaterial();

public static Logger logger = LogManager.getLogger("Natura");
public static Logger logger = LogManager.getLogger(modID);

public static final ModuleController moduleLoader = new ModuleController("Natura-Dynamic.cfg", "Natura");
public static final ModuleController moduleLoader = new ModuleController("Natura-Dynamic.cfg", modID);

@EventHandler
public void preInit (FMLPreInitializationEvent evt)
Expand Down Expand Up @@ -97,7 +97,6 @@ public void init (FMLInitializationEvent evt)
GameRegistry.registerWorldGenerator(crops = new BaseCropWorldgen(), 20); // TODO 1.7 Find correct weight (param 2)
GameRegistry.registerWorldGenerator(clouds = new BaseCloudWorldgen(), 20); // TODO 1.7 Find correct weight (param 2)
GameRegistry.registerWorldGenerator(trees = new BaseTreeWorldgen(), 20); // TODO 1.7 Find correct weight (param 2)
//NaturaTab.init(NContent.wheatBag);

proxy.registerRenderer();
proxy.addNames();
Expand Down Expand Up @@ -137,11 +136,6 @@ public void bonemealEvent (BonemealEvent event)
{
if (!event.world.isRemote)
{
/*if (event.block == content.crops.blockID)
{
if (content.crops.boneFertilize(event.world, event.X, event.y, event.z, event.world.rand))
event.setResult(event.getResult().ALLOW);
}*/
if (event.block == NContent.glowshroom)
{
if (NContent.glowshroom.fertilizeMushroom(event.world, event.x, event.y, event.z, event.world.rand))
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/mods/natura/common/NContent.java
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,9 @@
import cpw.mods.fml.common.IFuelHandler;
import cpw.mods.fml.common.registry.EntityRegistry;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.common.registry.GameRegistry.ObjectHolder;

@ObjectHolder(Natura.modID)
public class NContent implements IFuelHandler
{

Expand Down
28 changes: 5 additions & 23 deletions src/main/java/mods/natura/common/PHNatura.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import java.io.File;

import cpw.mods.fml.common.Loader;
import mods.natura.Natura;
import net.minecraftforge.common.config.Configuration;

Expand All @@ -19,14 +20,8 @@ public static void initProps (File confFile)
Natura.retrogen = config.get("Retrogen", "Retroactive Generation", false).getBoolean(false);

boolean BoP = false;
try
{
Class c = Class.forName("biomesoplenty.BiomesOPlenty");
if(Loader.isModLoaded("BiomesOPlenty"))
BoP = true;
}
catch (Exception e)
{
}

babyHeatscarMinimum = config.get("Mob Changes", "Minimum Baby Heatscar Spiders on Spider Death", 2).getInt(2);
if (babyHeatscarMinimum < 0)
Expand Down Expand Up @@ -76,7 +71,7 @@ public static void initProps (File confFile)

try
{
Class c = Class.forName("chococraft.common.ModChocoCraft");
Class.forName("chococraft.common.ModChocoCraft");
enableWheatRecipe = config.get("Disabler", "Enable wheat to flour recipe", false).getBoolean(false);
}
catch (Exception e)
Expand Down Expand Up @@ -141,13 +136,13 @@ public static void initProps (File confFile)
seaLevel = config.get("general", "Sea level", 64).getInt(64);

/* Save the configuration file */
config.save();
if(config.hasChanged())
config.save();
}

/* Prototype fields, used elsewhere */

public static int seaLevel;
public static int spawnEgg;

//Overworld
public static boolean generateBarley;
Expand All @@ -163,13 +158,7 @@ public static void initProps (File confFile)
public static boolean generateSkyberries;
public static boolean generateStingberries;

public static int seedFood;

public static int saguaroSpawnRarity;
public static int saguaroSpawnHeight;
public static int saguaroSpawnRange;

public static int cactusJuice;

public static int raspSpawnRarity;
public static int raspSpawnRange;
Expand All @@ -189,12 +178,6 @@ public static void initProps (File confFile)
public static int stingSpawnRarity;
public static int stingSpawnRange;

public static int netherBerryItem;
public static int berryItemID;
public static int berryMedley;
public static int berryBlockID;
public static int netherBerryBlock;

public static int thornSpawnRarity;

//Clouds
Expand Down Expand Up @@ -243,7 +226,6 @@ public static void initProps (File confFile)
public static boolean canRespawnInNether;

public static int redwoodSpawnRarity;
public static int redwoodSpawnRange;
public static int bloodSpawnRarity;
public static int eucalyptusShortSpawnRarity;
public static int eucalyptusShortSpawnRange;
Expand Down
13 changes: 0 additions & 13 deletions src/main/java/mods/natura/worldgen/SakuraTreeGen.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,8 @@

public class SakuraTreeGen extends WorldGenAbstractTree
{
// JAVADOC FIELD $$ field_76507_a
static final byte[] otherCoordPairs = new byte[] {(byte)2, (byte)0, (byte)0, (byte)1, (byte)2, (byte)1};
// JAVADOC FIELD $$ field_76505_b
Random rand = new Random();
// JAVADOC FIELD $$ field_76506_c
World worldObj;
int[] basePos = new int[] {0, 0, 0};
int heightLimit;
Expand All @@ -29,13 +26,9 @@ public class SakuraTreeGen extends WorldGenAbstractTree
double branchSlope = 0.381D;
double scaleWidth = 1.0D;
double leafDensity = 1.0D;
// JAVADOC FIELD $$ field_76510_l
int trunkSize = 1;
// JAVADOC FIELD $$ field_76511_m
int heightLimitLimit = 12;
// JAVADOC FIELD $$ field_76508_n
int leafDistanceLimit = 4;
// JAVADOC FIELD $$ field_76509_o
int[][] leafNodes;

int metaWood;
Expand All @@ -52,7 +45,6 @@ public SakuraTreeGen(boolean par1, int mdwood, int mdleaves)
metaLeaves = mdleaves;
}

// JAVADOC METHOD $$ func_76489_a
void generateLeafNodeList()
{
this.height = (int)((double)this.heightLimit * this.heightAttenuation);
Expand Down Expand Up @@ -289,7 +281,6 @@ else if (l == i1)
}
}

// JAVADOC METHOD $$ func_76498_b
void generateLeaves()
{
int i = 0;
Expand All @@ -303,13 +294,11 @@ void generateLeaves()
}
}

// JAVADOC METHOD $$ func_76493_c
boolean leafNodeNeedsBase(int par1)
{
return (double)par1 >= (double)this.heightLimit * 0.2D;
}

// JAVADOC METHOD $$ func_76499_c
void generateTrunk()
{
int i = this.basePos[0];
Expand Down Expand Up @@ -401,7 +390,6 @@ int checkBlockLine(int[] par1ArrayOfInteger, int[] par2ArrayOfInteger)
aint3[b1] = par1ArrayOfInteger[b1] + i;
aint3[b2] = MathHelper.floor_double((double)par1ArrayOfInteger[b2] + (double)i * d0);
aint3[b3] = MathHelper.floor_double((double)par1ArrayOfInteger[b3] + (double)i * d1);
Block block = this.worldObj.getBlock(aint3[0], aint3[1], aint3[2]);

if (!this.isReplaceable(worldObj, aint3[0], aint3[1], aint3[2]))
{
Expand Down Expand Up @@ -445,7 +433,6 @@ else if (i < 6)
}
}

// JAVADOC METHOD $$ func_76487_a
public void setScale(double par1, double par3, double par5)
{
this.heightLimitLimit = (int)(par1 * 12.0D);
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/mods/natura/worldgen/retro/ChunkCoord.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

/**
* Standardized implementation for representing and manipulating Chunk Coordinates. Provides standard Java Collection interaction.
* From COFH LIB
* From COFH LIB(modified to use mantle's coordtuple instead)
* @author King Lemming
*
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,4 @@ public void onTick (WorldTickEvent event)
}
}

/* @Override
public String getLabel ()
{
return "NaturaWorld";
}*/

}

0 comments on commit 1dc0499

Please sign in to comment.