Revert Forstride's derp

This commit is contained in:
Adubbz 2013-05-03 23:00:44 +10:00
parent e23f98cac5
commit a508261cf8
857 changed files with 83716 additions and 0 deletions

View file

@ -0,0 +1,92 @@
package Adubbz.CPGen;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import javax.swing.JFileChooser;
import javax.swing.JOptionPane;
public class ActionHandler implements ActionListener {
public static File importConfigSelectedFile = null;
public static File outputPatchSelectedFile = null;
public void actionPerformed(ActionEvent event)
{
if (event.getSource() == Gui.btnImportConfig)
{
JFileChooser importFileChooser = new JFileChooser();
importFileChooser.setDialogTitle("Select Pre-0.5.2 Config File");
importFileChooser.setFileFilter(new ConfigFileFilter());
importFileChooser.setAcceptAllFileFilterUsed(false);
int importChecker = importFileChooser.showOpenDialog(null);
importConfigSelectedFile = importFileChooser.getSelectedFile();
if (importChecker == JFileChooser.APPROVE_OPTION)
{
System.out.println("Found file at " + importConfigSelectedFile.toString());
Gui.textFieldImportConfig.setText(importConfigSelectedFile.toString());
}
}
if (event.getSource() == Gui.btnOutputPatch)
{
JFileChooser outputFileChooser = new JFileChooser();
outputFileChooser.setDialogTitle("Select Directory to Output to");
outputFileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
outputFileChooser.setFileFilter(new DirectoryFileFilter());
outputFileChooser.setAcceptAllFileFilterUsed(false);
int outputChecker = outputFileChooser.showOpenDialog(null);
outputPatchSelectedFile = outputFileChooser.getSelectedFile();
if (outputChecker == JFileChooser.APPROVE_OPTION)
{
System.out.println("Found folder at " + outputPatchSelectedFile);
Gui.textFieldOutputPatch.setText(outputPatchSelectedFile.toString());
}
}
if (event.getSource() == Gui.btnStart)
{
Gui.progressBar.setValue(0);
Gui.progressBar.setVisible(true);
if (importConfigSelectedFile != null)
{
Gui.progressBar.setValue(17);
if (outputPatchSelectedFile != null)
{
try
{
Gui.progressBar.setValue(34);
ConfigFileReader.read();
}
catch (Exception e)
{
e.printStackTrace();
}
}
else
{
JOptionPane.showMessageDialog(null, "You must select an Output Folder!", "Error", JOptionPane.ERROR_MESSAGE);
}
}
else
{
JOptionPane.showMessageDialog(null, "You must select a Config File!", "Error", JOptionPane.ERROR_MESSAGE);
}
}
}
}

View file

@ -0,0 +1,48 @@
package Adubbz.CPGen;
import java.io.File;
import javax.swing.filechooser.FileFilter;
public class ConfigFileFilter extends FileFilter {
private String ImageFormat = "CFG";
private char DotIndex = '.';
public boolean accept(File file)
{
if (file.isDirectory())
{
return true;
}
else if (extension(file).equalsIgnoreCase(ImageFormat))
{
return true;
}
else
{
return false;
}
}
@Override
public String getDescription()
{
return "Config Files Only";
}
public String extension(File file)
{
String FileName = file.getName();
int IndexFile = FileName.lastIndexOf(DotIndex);
if (IndexFile > 0 && IndexFile < FileName.length() - 1)
{
return FileName.substring(IndexFile + 1);
}
else
{
return "";
}
}
}

View file

@ -0,0 +1,48 @@
package Adubbz.CPGen;
import java.io.BufferedReader;
import java.io.FileReader;
public class ConfigFileReader {
public static String text = "";
public static void read() throws Exception
{
FileReader file = new FileReader(ActionHandler.importConfigSelectedFile.toString());
BufferedReader reader = new BufferedReader(file);
String line = reader.readLine();
boolean foundBlock = false;
boolean endBlock = false;
while (line != null)
{
String currentLineText = line;
if (foundBlock && currentLineText.contains("}"))
{
endBlock = true;
}
if (foundBlock && !endBlock)
{
text += line;
}
if (currentLineText.contains("block {"))
{
foundBlock = true;
}
line = reader.readLine();
}
reader.close();
Gui.progressBar.setValue(51);
ConfigTextFilter.filter();
}
}

View file

@ -0,0 +1,176 @@
package Adubbz.CPGen;
public class ConfigTextFilter {
public static String[] splitString;
public static void filter()
{
splitString = ConfigFileReader.text.split("I:");
for (int i = 1; i < 141; ++i)
{
//splitString[i] = splitString[i].replaceAll( "[^\\d]", "" );
splitString[i] = splitString[i].replaceFirst(".*?(?=[a-z]?=)", "");
splitString[i] = splitString[i].replace("=", "");
splitString[i] = splitString[i].replace(" ", "");
splitString[i] = splitString[i] + " -> ";
}
splitString[1] = splitString[1] + "1948";
splitString[2] = splitString[2] + "1962";
splitString[3] = splitString[3] + "1933";
splitString[4] = splitString[4] + "1947";
splitString[5] = splitString[5] + "1938";
splitString[6] = splitString[6] + "1949";
splitString[7] = splitString[7] + "1952";
splitString[8] = splitString[8] + "1925";
splitString[9] = splitString[9] + "1942";
splitString[10] = splitString[10] + "1921:9";
splitString[11] = splitString[11] + "1926:3";
splitString[12] = splitString[12] + "1937";
splitString[13] = splitString[13] + "1927";
splitString[14] = splitString[14] + "1923:1";
splitString[15] = splitString[15] + "1937:2";
splitString[16] = splitString[16] + "1947:10";
splitString[17] = splitString[17] + "1920:6";
splitString[18] = splitString[18] + "1942:1";
splitString[19] = splitString[19] + "1925:4";
splitString[20] = splitString[20] + "1920:7";
splitString[21] = splitString[21] + "1948:1";
splitString[22] = splitString[22] + "1933:1";
splitString[23] = splitString[23] + "1947:1";
splitString[24] = splitString[24] + "1949:1";
splitString[25] = splitString[25] + "1953";
splitString[26] = splitString[26] + "1921";
splitString[27] = splitString[27] + "1921:5";
splitString[28] = splitString[28] + "1948:2";
splitString[29] = splitString[29] + "1923:3";
splitString[30] = splitString[30] + "1933:2";
splitString[31] = splitString[31] + "1947:2";
splitString[32] = splitString[32] + "1937:4";
splitString[33] = splitString[33] + "1949:2";
splitString[34] = splitString[34] + "1954";
splitString[35] = splitString[35] + "1920";
splitString[36] = splitString[36] + "1935:2";
splitString[37] = splitString[37] + "1921:2";
splitString[38] = splitString[38] + "1920:1";
splitString[39] = splitString[39] + "1920:2";
splitString[40] = splitString[40] + "1920:3";
splitString[41] = splitString[41] + "1920:3";
splitString[42] = splitString[42] + "1923:4";
splitString[43] = splitString[43] + "1937:5";
splitString[44] = splitString[44] + "1948:3";
splitString[45] = splitString[45] + "1923:5";
splitString[46] = splitString[46] + "1947:3";
splitString[47] = splitString[47] + "1937:6";
splitString[48] = splitString[48] + "1949:3";
splitString[49] = splitString[49] + "1926";
splitString[51] = splitString[51] + "1935:3";
splitString[52] = splitString[52] + "1936";
splitString[53] = splitString[53] + "1936:1";
splitString[54] = splitString[54] + "1921:3";
splitString[55] = splitString[55] + "1925:3";
splitString[56] = splitString[56] + "1925:6";
splitString[57] = splitString[57] + "1948:4";
splitString[58] = splitString[58] + "1923:6";
splitString[59] = splitString[59] + "1934";
splitString[60] = splitString[60] + "1947:4";
splitString[61] = splitString[61] + "1937:7";
splitString[62] = splitString[62] + "1949:4";
splitString[63] = splitString[63] + "1956";
splitString[64] = splitString[64] + "1920:4";
splitString[65] = splitString[65] + "1921:4";
splitString[66] = splitString[66] + "1948:5";
splitString[67] = splitString[67] + "1923:2";
splitString[68] = splitString[68] + "1934:1";
splitString[69] = splitString[69] + "1947:5";
splitString[70] = splitString[70] + "1937:3";
splitString[71] = splitString[71] + "1949:5";
splitString[72] = splitString[72] + "1957";
splitString[73] = splitString[73] + "1948:6";
splitString[74] = splitString[74] + "1962:1";
splitString[75] = splitString[75] + "1934:2";
splitString[76] = splitString[76] + "1947:6";
splitString[77] = splitString[77] + "1938:1";
splitString[78] = splitString[78] + "1949:6";
splitString[79] = splitString[79] + "1958"; //Correct
splitString[80] = splitString[80] + "1924:2";
splitString[81] = splitString[81] + "1937:11";
splitString[82] = splitString[82] + "1925:2";
splitString[83] = splitString[83] + "4095";
splitString[84] = splitString[84] + "1930:2";
splitString[85] = splitString[85] + "1931:2";
splitString[86] = splitString[86] + "1929";
splitString[87] = splitString[87] + "1928";
splitString[88] = splitString[88] + "1923:7";
splitString[89] = splitString[89] + "1937:8";
splitString[90] = splitString[90] + "1924";
splitString[91] = splitString[91] + "1937:9";
splitString[92] = splitString[92] + "1948:7";
splitString[93] = splitString[93] + "1962:2";
splitString[94] = splitString[94] + "1934:3";
splitString[95] = splitString[95] + "1947:7";
splitString[96] = splitString[96] + "1938:2";
splitString[97] = splitString[97] + "1949:7";
splitString[98] = splitString[98] + "1959";
splitString[99] = splitString[99] + "1924:1";
splitString[100] = splitString[100] + "1937:10";
splitString[101] = splitString[101] + "1921:6";
splitString[102] = splitString[102] + "1941";
splitString[103] = splitString[103] + "160:1";
splitString[104] = splitString[104] + "1930:1";
splitString[105] = splitString[105] + "1931:1";
splitString[106] = splitString[106] + "1940";
splitString[107] = splitString[107] + "162:2";
splitString[108] = splitString[108] + "1930";
splitString[109] = splitString[109] + "162:1";
splitString[110] = splitString[110] + "1931";
splitString[111] = splitString[111] + "1939";
splitString[112] = splitString[112] + "1950";
splitString[113] = splitString[113] + "1962:3";
splitString[114] = splitString[114] + "1935";
splitString[115] = splitString[115] + "1947:8";
splitString[116] = splitString[116] + "1938:3";
splitString[117] = splitString[117] + "1951";
splitString[118] = splitString[118] + "1960";
splitString[119] = splitString[119] + "1925:1";
splitString[120] = splitString[120] + "169:1";
splitString[121] = splitString[121] + "1925:5";
splitString[122] = splitString[122] + "1921:1";
splitString[123] = splitString[123] + "1920:5";
splitString[124] = splitString[124] + "1921:11";
splitString[125] = splitString[125] + "1921:10";
splitString[126] = splitString[126] + "1932";
splitString[127] = splitString[127] + "1921:8";
splitString[128] = splitString[128] + "1924:3";
splitString[129] = splitString[129] + "1937:12";
splitString[130] = splitString[130] + "1921:7";
splitString[131] = splitString[131] + "1950:1";
splitString[132] = splitString[132] + "1922";
splitString[133] = splitString[133] + "1962:4";
splitString[134] = splitString[134] + "1935:1";
splitString[135] = splitString[135] + "1947:9";
splitString[136] = splitString[136] + "1938:4";
splitString[137] = splitString[137] + "1951:1";
splitString[138] = splitString[138] + "1961";
splitString[139] = splitString[139] + "1923";
splitString[140] = splitString[140] + "1937:1";
for (int i = 1; i < 141; ++i)
{
System.out.println(splitString[i]);
}
try
{
Gui.progressBar.setValue(68);
TextFileWriter.write();
}
catch (Exception e)
{
e.printStackTrace();
}
}
}

View file

@ -0,0 +1,26 @@
package Adubbz.CPGen;
import java.io.File;
import javax.swing.filechooser.FileFilter;
public class DirectoryFileFilter extends FileFilter {
public boolean accept(File file)
{
if (file.isDirectory())
{
return true;
}
else
{
return false;
}
}
@Override
public String getDescription()
{
return "Directories Only";
}
}

View file

@ -0,0 +1,73 @@
package Adubbz.CPGen;
import java.awt.BorderLayout;
import java.awt.Component;
import java.awt.FlowLayout;
import java.awt.Font;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JTextField;
import javax.swing.SwingConstants;
import javax.swing.JProgressBar;
import javax.swing.JLabel;
import com.jgoodies.forms.factories.DefaultComponentFactory;
public class Gui extends JFrame {
public static JFrame frame;
public static JTextField textFieldImportConfig;
public static JTextField textFieldOutputPatch;
public static JButton btnImportConfig = new JButton("Import Config");
public static JButton btnOutputPatch = new JButton("Output Patch");
public static JButton btnStart = new JButton("Start");
public static JProgressBar progressBar = new JProgressBar();
public Gui() {
getContentPane().setLayout(new BorderLayout());
frame = new JFrame("BOP Converter Patch Generator");
frame.setBounds(100, 100, 556, 141);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setResizable(false);
frame.getContentPane().setLayout(null);
btnImportConfig.setBounds(425, 11, 115, 23);
frame.getContentPane().add(btnImportConfig);
btnOutputPatch.setBounds(425, 45, 115, 23);
frame.getContentPane().add(btnOutputPatch);
textFieldImportConfig = new JTextField();
textFieldImportConfig.setBounds(10, 12, 405, 20);
frame.getContentPane().add(textFieldImportConfig);
textFieldImportConfig.setColumns(10);
textFieldImportConfig.setEditable(false);
textFieldOutputPatch = new JTextField();
textFieldOutputPatch.setBounds(10, 46, 405, 20);
frame.getContentPane().add(textFieldOutputPatch);
textFieldOutputPatch.setColumns(10);
textFieldOutputPatch.setEditable(false);
btnStart.setBounds(425, 79, 115, 23);
frame.getContentPane().add(btnStart);
progressBar.setBounds(10, 77, 405, 25);
progressBar.setStringPainted(true);
progressBar.setVisible(false);
frame.getContentPane().add(progressBar);
ActionHandler handler = new ActionHandler();
btnImportConfig.addActionListener(handler);
btnOutputPatch.addActionListener(handler);
btnStart.addActionListener(handler);
}
}

View file

@ -0,0 +1,20 @@
package Adubbz.CPGen;
import java.awt.EventQueue;
public class Main {
public static void main(String args [])
{
EventQueue.invokeLater(new Runnable() {
public void run() {
try {
Gui window = new Gui();
window.frame.setVisible(true);
} catch (Exception e) {
e.printStackTrace();
}
}
});
}
}

View file

@ -0,0 +1,63 @@
package Adubbz.CPGen;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import javax.swing.JOptionPane;
public class TextFileWriter {
static int patchNo = 0;
static File newFile;
public static void write() throws Exception
{
if (patchNo == 0)
{
newFile = new File(ActionHandler.outputPatchSelectedFile.toString() + "/Patch.txt");
}
else
{
newFile = new File(ActionHandler.outputPatchSelectedFile.toString() + "/Patch" + patchNo + ".txt");
}
if (newFile.exists())
{
System.out.println("The file already exists, adding number...");
patchNo++;
write();
}
else
{
newFile.createNewFile();
create();
}
}
private static void create() throws Exception
{
Gui.progressBar.setValue(85);
FileWriter fileWriter = new FileWriter(newFile);
BufferedWriter bufferedWriter = new BufferedWriter(fileWriter);
for (int i = 1; i < 141; ++i)
{
bufferedWriter.write(ConfigTextFilter.splitString[i]);
bufferedWriter.newLine();
}
bufferedWriter.close();
Gui.progressBar.setValue(100);
System.out.println("File Written to " + newFile);
JOptionPane.showMessageDialog(null, "Done!", null, JOptionPane.INFORMATION_MESSAGE);
if (JOptionPane.OK_OPTION == 1);
{
Gui.progressBar.setVisible(false);
}
}
}

150
README.md Normal file
View file

@ -0,0 +1,150 @@
## Authors
- **Adubbz** - Madman
- **Amnet** - Foreign Affairs
- **ted80** - Biome Fanatic
## Credits ##
- **Forstride** - Original creator
- **gamax92**
- **enchilado**
- **Tim Rurkowski** - Music author
## World Conversion##
As of Biomes O Plenty 0.5.2, changes have been made so that the number of block ids used by the mod are drastically reduced. However, as a side-effect of these changes, existing worlds will no longer work.
However, thanks to a little Java application I (Adubbz) whipped up, as well as the lovely folks who made Midas gold, this should hopefully be easy.
----------
1. Backup your world
2. Grab a copy of the Converter Patch Generator from here:
[https://github.com/ted80/BiomesOPlenty/tree/master/BOP%20Converter%20Patch%20Generator](https://github.com/ted80/BiomesOPlenty/tree/master/BOP%20Converter%20Patch%20Generator) (Click on the jar file and then 'View Raw' to download it)
3. Grab a copy of Midas Gold from here:
[https://code.google.com/p/midas-gold/downloads/list](https://code.google.com/p/midas-gold/downloads/list)
4. Extract Midas Gold.
5. Launch the Converter Patch Generator.
6. Click on "Import Config" and select your old Biomes O Plenty config file.
7. Click on "Output Patch" and choose where you want the patch file to be outputted to.
8. Hit "Start".
9. Launch the Midas Gold jar file.
10. Click on "Add Savegame" and select the folder of the world you want converted.
11. Click on "Load Patch File" and select the patch file created by the Converter Patch Generator.
12. Hit start!
13. You're done :)
----------
## Changelog ##
Version 0.5.2 (Unreleased)
- Added an API for other mod developers
- Added support for Biomes O Plenty woods in Thermal Expansion sawmills
- Significantly compressed the amount of Block IDs used, however breaks existing worlds
- Updated to the latest Forge
- Changed various things to use IShearable
- Changed default biome ids to be compatible with Mo Creatures
- Made a proper fix for achievements and made them enabled by default (The config option is still there though for those that want it)
- Added Better World Generation 4 support
- Made shears instantly destroy Biomes O Plenty leaves
- Adjusted high grass hitbox to cover both blocks
- Fixed an issue causing sound files to be created on the desktop
- Biomes O Plenty saplings now work in the Forestry fermenter
- Biomes O Plenty flowers can now be used with bees
- Gave the different types Autumn and Cherry Leaves their own names
- Added Biome Dictionary support
- Added seeds on destroyed Biomes O Plenty grasses
- Carrots and potatoes now have a chance (1%) to be dropped from sprouts
- Added a random drop of apples when destroying apple leaves
- Added flowers to plants created on bonemeal use
- Tweaked the recipe for bamboo thatching
- Bamboo now acts as sticks
- Hopefully fixed saplings once and for all
- Added hardcoded foliage colours
- Added configurable spawn distance between villages in the BOP world type
- Added more biomes for villages to spawn in
- Tweaked cattail generation
- Renamed the texture files to reflect the in-game names
- You can now have different textures for the heart of every log
- Added Thaumcraft compatibility
- Updated the regular BOP music disc file (courtesy of Forstride), may require deleting the old bopdisc.ogg to take effect
- Allowed Forestry beehives to spawn on Biomes O Plenty certain blocks
- Fixed registering biomes for world types - BOP biomes now accessible in Large Biomes World Type
Version 0.5.1 '17-04-2013'
- Fixed server crash with mudballs
- Fixed Forestry beehives spawning, as well as giving biomes appropriate temperatures
- Removed wrong recipe for mossy cobblestone
- Added bamboo saplings
- Bonemeal now creates the appropriate giant flowers when used on red and yellow flowers
- Changed default biome ids
- Fixed sapling bugs
Version 0.5.0 '09-04-2013'
- Desert sprouts and Dune Grass now require shears to be harvested
- Added alpha beaches to origin valley biome
- You can now throw Mudballs to deal 1/2 heart of damage
- Entities get the slowness potion effect when hit by mudballs
- Mud balls can now be fired from dispensers
- Resources now only install client-side
- Fixed bonemeal on Origin Saplings
- Bonemeal now only reacts to mangrove saplings when they are on sand
- Fixed bonemeal and holy grass dependancies on Holy and Magic saplings
- Changed the leaves blocks to use the IShearable interface
- Made the enderporter only work in the overworld
- Fixed the textures for logs to display according to their orientation
- Adding Leaves, Saplings, Stairs and Slabs to Ore Dictionary
- Fixed crash on right clicking on slabs with nothing in your hand
- Fixed trees not generating in the Mystic grove
- Fixed placing Moss, TreeMoss and Willow
- Fixed a bug with Promised Lands not using the ID from the config file
Version 0.4.9 '03-04-2013'
- Tools actually have the properties of the tools they are meant to be (they used to all think they are swords)
- Ore dictionary support for wood
- Added a temporary fix for the Ach Flower issue in the form of a config option for achievements
- Fancier message upon creation of The Promised Lands
- No more duplicate chat messages on creating the Promised Lands
- You can no longer create an infinite endstone supply from spamming Promised Lands portals
- Holy Tall grass no longer drops itself without using shears
- Fixed things wrongly having wooden footstep sounds
- Saplings now use the new bonemeal system added by Minecraft 1.5
- Bonemeal now creates Holy Tall Grass when used on Holy Grass
- Fixed slabs not stacking
- Fixed leaf decay
- Fixed tool effectiveness on various blocks
- Gave smoldering grass and ash their expected behaviours; burn on contact (smoldering grass) and slowness (ash)
- Holy and magic saplings will only grow on Holy Grass
- Holy Grass burns up into Soulsand in the Nether
- Fixed axe recipes
- Removed unnecessary recipes for hoes
Version 0.4.8 '31-03-2013'
- Fixed smoldering grass texture
- Fixed flower achievement?
- Fixed Giant red flower texture
Version 0.4.7 '30-03-2013'
- Updated to Minecraft 1.5.1

View file

@ -0,0 +1,5 @@
1. Thaumcraft - In Progress
2. Ars Magica
3. Thermal Expansion - Woods in sawmill - DONE
4. Forestry - Wood in backpacks - In Progress
5. Better World Generation 4 - In Progress

View file

@ -0,0 +1,138 @@
package biomesoplenty;
import java.io.File;
import java.io.FileOutputStream;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.logging.Level;
import net.minecraft.client.Minecraft;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraftforge.common.DimensionManager;
import net.minecraftforge.common.MinecraftForge;
import biomesoplenty.api.BlockReferences;
import biomesoplenty.configuration.BOPBiomes;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.configuration.BOPCrafting;
import biomesoplenty.configuration.BOPEntities;
import biomesoplenty.configuration.BOPItems;
import biomesoplenty.configuration.BOPVanillaCompat;
import biomesoplenty.helpers.AchievementHelper;
import biomesoplenty.helpers.BonemealUse;
import biomesoplenty.helpers.CreativeTabsBOP;
import biomesoplenty.helpers.WorldProviderPromised;
import biomesoplenty.helpers.WorldTypeSize;
import biomesoplenty.integration.BOPCrossIntegration;
import biomesoplenty.integration.ThaumcraftIntegration;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.Init;
import cpw.mods.fml.common.Mod.Instance;
import cpw.mods.fml.common.Mod.PreInit;
import cpw.mods.fml.common.SidedProxy;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
import cpw.mods.fml.common.network.NetworkMod;
import cpw.mods.fml.common.registry.LanguageRegistry;
@Mod(modid="BiomesOPlenty", name="Biomes O' Plenty", version="0.5.2")
@NetworkMod(clientSideRequired=true, serverSideRequired=false)
public class BiomesOPlenty
{
//The rudder moves when I turn the wheel
// The instance of your mod that Forge uses.
@Instance("BiomesOPlenty")
public static BiomesOPlenty instance;
// Says where the client and server 'proxy' code is loaded.
@SidedProxy(clientSide="biomesoplenty.ClientProxy", serverSide="biomesoplenty.CommonProxy")
public static CommonProxy proxy;
public static CreativeTabs tabBiomesOPlenty;
@PreInit
public void preInit(FMLPreInitializationEvent event)
{
boolean isClient = proxy instanceof ClientProxy;
String[] soundFiles = { "bopdisc.ogg", "bopdiscmud.ogg"};
if (isClient)
{
for (String soundFile : soundFiles) try
{
File file = new File(Minecraft.getMinecraftDir().getAbsolutePath() + "/resources/mod/streaming/" + soundFile);
if (!file.exists()) {
System.out.println("[BiomesOPlenty] " + soundFile + " doesn't exist, creating...");
file.getParentFile().mkdirs();
file.createNewFile();
InputStream istream = getClass().getResourceAsStream("/mods/BiomesOPlenty/audio/" + soundFile);
OutputStream out = new FileOutputStream(file);
byte[] buf = new byte[1024];
int size = 0;
int len;
while ((len = istream.read(buf)) > 0) {
out.write(buf, 0, len);
size += len;
}
out.close();
istream.close();
if (size == 0) file.delete();
}
}
catch (Exception e)
{
FMLCommonHandler.instance().getFMLLogger().log(Level.WARNING, "[BiomesOPlenty] Failed to load sound file: " + soundFile);
e.printStackTrace();
}
}
BOPConfiguration.init(event.getSuggestedConfigurationFile());
tabBiomesOPlenty = new CreativeTabsBOP(CreativeTabs.getNextID(),"tabBiomesOPlenty");
BOPBlocks.init();
BOPItems.init();
BOPCrafting.init();
BOPBiomes.init();
BOPEntities.init();
BOPVanillaCompat.init();
// Achievement declaration
if (BOPConfiguration.achievements == true)
{
AchievementHelper.init();
}
}
@Init
public void load(FMLInitializationEvent event)
{
LanguageRegistry.instance().addStringLocalization("itemGroup.tabBiomesOPlenty", "en_US", "Biomes O\' Plenty");
LanguageRegistry.instance().addStringLocalization("generator.BIOMESOP", "en_US", "Biomes O\' Plenty");
// Add helpers for compatibility
MinecraftForge.TERRAIN_GEN_BUS.register(new WorldTypeSize());
MinecraftForge.EVENT_BUS.register(new AchievementHelper());
MinecraftForge.EVENT_BUS.register(new BonemealUse());
proxy.registerRenderers();
DimensionManager.registerProviderType(BOPConfiguration.promisedLandDimID, WorldProviderPromised.class, false);
DimensionManager.registerDimension(BOPConfiguration.promisedLandDimID, BOPConfiguration.promisedLandDimID);
BOPCrossIntegration.init();
}
public void postInit(FMLPostInitializationEvent event)
{
}
}

View file

@ -0,0 +1,47 @@
package biomesoplenty;
import net.minecraft.client.Minecraft;
import net.minecraft.client.particle.EntityBreakingFX;
import net.minecraft.client.particle.EntityFX;
import net.minecraft.client.renderer.entity.RenderSnowball;
import net.minecraft.world.World;
import net.minecraftforge.client.MinecraftForgeClient;
import biomesoplenty.api.Items;
import biomesoplenty.blocks.renderers.FoliageRenderer;
import biomesoplenty.blocks.renderers.PlantsRenderer;
import biomesoplenty.items.projectiles.EntityMudball;
import cpw.mods.fml.client.registry.RenderingRegistry;
public class ClientProxy extends CommonProxy {
public static Minecraft mc = Minecraft.getMinecraft();
@Override
public void registerRenderers()
{
MinecraftForgeClient.preloadTexture(ARMOR_MUD1_PNG);
MinecraftForgeClient.preloadTexture(ARMOR_MUD2_PNG);
MinecraftForgeClient.preloadTexture(ARMOR_AMETHYST1_PNG);
MinecraftForgeClient.preloadTexture(ARMOR_AMETHYST2_PNG);
RenderingRegistry.registerEntityRenderingHandler(EntityMudball.class, new RenderSnowball(Items.mudball.get(), 0));
RenderingRegistry.registerBlockHandler(new FoliageRenderer());
RenderingRegistry.registerBlockHandler(new PlantsRenderer());
}
@Override
public void spawnMud(World world, double x, double y, double z, double xVel, double yVel, double zVel)
{
EntityFX entityfx = null;
entityfx = new EntityBreakingFX(mc.theWorld, x, y, z, Items.mudball.get(), mc.renderEngine);
mc.effectRenderer.addEffect(entityfx);
}
@Override
public int addArmor(String armor)
{
return RenderingRegistry.addNewArmourRendererPrefix(armor);
}
}

View file

@ -0,0 +1,25 @@
package biomesoplenty;
import net.minecraft.world.World;
public class CommonProxy {
public static String ARMOR_MUD1_PNG = "/mods/BiomesOPlenty/textures/armor/mud_1.png";
public static String ARMOR_MUD2_PNG = "/mods/BiomesOPlenty/textures/armor/mud_2.png";
public static String ARMOR_AMETHYST1_PNG = "/mods/BiomesOPlenty/textures/armor/amethyst_1.png";
public static String ARMOR_AMETHYST2_PNG = "/mods/BiomesOPlenty/textures/armor/amethyst_2.png";
// Client stuff
public void registerRenderers() {
// Nothing here as the server doesn't render graphics!
}
public int addArmor(String armor)
{
return 0;
}
public void spawnMud(World world, double x, double y, double z, double xVel, double yVel, double zVel)
{
}
}

View file

@ -0,0 +1,89 @@
package biomesoplenty.api;
import net.minecraft.world.biome.BiomeGenBase;
import com.google.common.base.Optional;
public class Biomes
{
public static Optional<? extends BiomeGenBase> alps = Optional.absent();
public static Optional<? extends BiomeGenBase> arctic = Optional.absent();
public static Optional<? extends BiomeGenBase> badlands = Optional.absent();
public static Optional<? extends BiomeGenBase> bambooForest = Optional.absent();
public static Optional<? extends BiomeGenBase> bayou = Optional.absent();
public static Optional<? extends BiomeGenBase> birchForest = Optional.absent();
public static Optional<? extends BiomeGenBase> bog = Optional.absent();
public static Optional<? extends BiomeGenBase> borealForest = Optional.absent();
public static Optional<? extends BiomeGenBase> canyon = Optional.absent();
public static Optional<? extends BiomeGenBase> chaparral = Optional.absent();
public static Optional<? extends BiomeGenBase> cherryBlossomGrove = Optional.absent();
public static Optional<? extends BiomeGenBase> coniferousForest = Optional.absent();
public static Optional<? extends BiomeGenBase> crag = Optional.absent();
public static Optional<? extends BiomeGenBase> deadForest = Optional.absent();
public static Optional<? extends BiomeGenBase> deadSwamp = Optional.absent();
public static Optional<? extends BiomeGenBase> deadlands = Optional.absent();
public static Optional<? extends BiomeGenBase> deciduousForest = Optional.absent();
public static Optional<? extends BiomeGenBase> drylands = Optional.absent();
public static Optional<? extends BiomeGenBase> dunes = Optional.absent();
public static Optional<? extends BiomeGenBase> fen = Optional.absent();
public static Optional<? extends BiomeGenBase> field = Optional.absent();
public static Optional<? extends BiomeGenBase> frostForest = Optional.absent();
public static Optional<? extends BiomeGenBase> fungiForest = Optional.absent();
public static Optional<? extends BiomeGenBase> garden = Optional.absent();
public static Optional<? extends BiomeGenBase> glacier = Optional.absent();
public static Optional<? extends BiomeGenBase> grassland = Optional.absent();
public static Optional<? extends BiomeGenBase> grove = Optional.absent();
public static Optional<? extends BiomeGenBase> heathland = Optional.absent();
public static Optional<? extends BiomeGenBase> highland = Optional.absent();
public static Optional<? extends BiomeGenBase> iceSheet = Optional.absent();
public static Optional<? extends BiomeGenBase> icyHills = Optional.absent();
public static Optional<? extends BiomeGenBase> jadeCliffs = Optional.absent();
public static Optional<? extends BiomeGenBase> lushDesert = Optional.absent();
public static Optional<? extends BiomeGenBase> lushSwamp = Optional.absent();
public static Optional<? extends BiomeGenBase> mangrove = Optional.absent();
public static Optional<? extends BiomeGenBase> mapleWoods = Optional.absent();
public static Optional<? extends BiomeGenBase> marsh = Optional.absent();
public static Optional<? extends BiomeGenBase> meadow = Optional.absent();
public static Optional<? extends BiomeGenBase> mesa = Optional.absent();
public static Optional<? extends BiomeGenBase> moor = Optional.absent();
public static Optional<? extends BiomeGenBase> mountain = Optional.absent();
public static Optional<? extends BiomeGenBase> mysticGrove = Optional.absent();
public static Optional<? extends BiomeGenBase> oasis = Optional.absent();
public static Optional<? extends BiomeGenBase> ominousWoods = Optional.absent();
public static Optional<? extends BiomeGenBase> orchard = Optional.absent();
public static Optional<? extends BiomeGenBase> originValley = Optional.absent();
public static Optional<? extends BiomeGenBase> outback = Optional.absent();
public static Optional<? extends BiomeGenBase> pasture = Optional.absent();
public static Optional<? extends BiomeGenBase> prairie = Optional.absent();
public static Optional<? extends BiomeGenBase> promisedLand = Optional.absent();
public static Optional<? extends BiomeGenBase> quagmire = Optional.absent();
public static Optional<? extends BiomeGenBase> rainforest = Optional.absent();
public static Optional<? extends BiomeGenBase> redwoodForest = Optional.absent();
public static Optional<? extends BiomeGenBase> sacredSprings = Optional.absent();
public static Optional<? extends BiomeGenBase> savanna = Optional.absent();
public static Optional<? extends BiomeGenBase> scrubland = Optional.absent();
public static Optional<? extends BiomeGenBase> seasonalForest = Optional.absent();
public static Optional<? extends BiomeGenBase> shield = Optional.absent();
public static Optional<? extends BiomeGenBase> shore = Optional.absent();
public static Optional<? extends BiomeGenBase> shrubland = Optional.absent();
public static Optional<? extends BiomeGenBase> snowyWoods = Optional.absent();
public static Optional<? extends BiomeGenBase> spruceWoods = Optional.absent();
public static Optional<? extends BiomeGenBase> steppe = Optional.absent();
public static Optional<? extends BiomeGenBase> swampwoods = Optional.absent();
public static Optional<? extends BiomeGenBase> temperateRainforest = Optional.absent();
public static Optional<? extends BiomeGenBase> thicket = Optional.absent();
public static Optional<? extends BiomeGenBase> tropicalRainforest = Optional.absent();
public static Optional<? extends BiomeGenBase> tropics = Optional.absent();
public static Optional<? extends BiomeGenBase> tundra = Optional.absent();
public static Optional<? extends BiomeGenBase> volcano = Optional.absent();
public static Optional<? extends BiomeGenBase> wasteland = Optional.absent();
public static Optional<? extends BiomeGenBase> wetland = Optional.absent();
public static Optional<? extends BiomeGenBase> woodland = Optional.absent();
public static Optional<? extends BiomeGenBase> plainsNew = Optional.absent();
public static Optional<? extends BiomeGenBase> desertNew = Optional.absent();
public static Optional<? extends BiomeGenBase> extremeHillsNew = Optional.absent();
public static Optional<? extends BiomeGenBase> forestNew = Optional.absent();
public static Optional<? extends BiomeGenBase> taigaNew = Optional.absent();
public static Optional<? extends BiomeGenBase> swamplandNew = Optional.absent();
public static Optional<? extends BiomeGenBase> jungleNew = Optional.absent();
}

View file

@ -0,0 +1,180 @@
package biomesoplenty.api;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import com.google.common.base.Optional;
public class BlockReferences {
public static enum EnumBlocks
{
acaciaLog (Blocks.logs1, 0),
cherryLog (Blocks.logs1, 1),
darkLog (Blocks.logs1, 2),
firLog (Blocks.logs1, 3),
holyLog (Blocks.logs2, 0),
magicLog (Blocks.logs2, 1),
mangroveLog (Blocks.logs2, 2),
palmLog (Blocks.logs2, 3),
redwoodLog (Blocks.logs3, 0),
willowLog (Blocks.logs3, 1),
deadLog (Blocks.logs3, 2),
bigFlowerStem (Blocks.logs3, 3),
acaciaPlank (Blocks.planks, 0),
cherryPlank (Blocks.planks, 1),
darkPlank (Blocks.planks, 2),
firPlank (Blocks.planks, 3),
holyPlank (Blocks.planks, 4),
magicPlank (Blocks.planks, 5),
mangrovePlank (Blocks.planks, 6),
palmPlank (Blocks.planks, 7),
redwoodPlank (Blocks.planks, 8),
willowPlank (Blocks.planks, 9),
bambooThatching (Blocks.planks, 10),
acaciaLeaves (Blocks.leavesColorized, 0),
mangroveLeaves (Blocks.leavesColorized, 1),
palmLeaves (Blocks.leavesColorized, 2),
redwoodLeaves (Blocks.leavesColorized, 3),
willowLeaves (Blocks.leavesColorized, 4),
yellowAutumnLeaves (Blocks.leaves1, 0),
bambooLeaves (Blocks.leaves1, 1),
magicLeaves (Blocks.leaves1, 2),
darkLeaves (Blocks.leaves1, 3),
deadLeaves (Blocks.leaves1, 4),
firLeaves (Blocks.leaves1, 5),
holyLeaves (Blocks.leaves1, 6),
orangeAutumnLeaves (Blocks.leaves1, 7),
originLeaves (Blocks.leaves2, 0),
pinkCherryLeaves (Blocks.leaves2, 1),
mapleLeaves (Blocks.leaves2, 2),
whiteCherryLeaves (Blocks.leaves2, 3),
appleLeaves (Blocks.leavesFruit, 3),
appleLeavesFruitless (Blocks.leavesFruit, 0),
bamboo (Blocks.bamboo, 0),
barley (Blocks.plants, 6),
cattail (Blocks.plants, 7),
sproutItem (Blocks.foliage, 5),
bushItem (Blocks.foliage, 4),
highGrassItem (Blocks.foliage, 3),
mediumGrassItem (Blocks.foliage, 2),
shortGrassItem (Blocks.foliage, 1),
algae (Blocks.foliage, 0),
holySapling (Blocks.saplings, 7),
magicSapling (Blocks.saplings, 3),
darkSapling (Blocks.saplings, 4),
deadSapling (Blocks.saplings, 5),
acaciaSapling (Blocks.colorizedSaplings, 0),
firSapling (Blocks.saplings, 6),
mangroveSapling (Blocks.colorizedSaplings, 1),
palmSapling (Blocks.colorizedSaplings, 2),
redwoodSapling (Blocks.colorizedSaplings, 3),
willowSapling (Blocks.colorizedSaplings, 4),
mapleSapling (Blocks.saplings, 11),
orangeAutumnSapling (Blocks.saplings, 8),
pinkCherrySapling (Blocks.saplings, 10),
whiteCherrySapling (Blocks.saplings, 12),
appleSapling (Blocks.saplings, 0),
originSapling (Blocks.saplings, 9),
yellowAutumnSapling (Blocks.saplings, 1),
bambooSapling (Blocks.saplings, 2),
mud (Blocks.mud, 0),
driedDirt (Blocks.driedDirt, 0),
redRock (Blocks.redRock, 0),
ash (Blocks.ash, 0),
ashStone (Blocks.ashStone, 0),
hardIce (Blocks.hardIce, 0),
originGrass (Blocks.originGrass, 0),
hardSand (Blocks.hardSand, 0),
hardDirt (Blocks.hardDirt, 0),
holyGrass (Blocks.holyGrass, 0),
holyStone (Blocks.holyStone, 0),
cragRock (Blocks.cragRock, 0),
quicksand (Blocks.mud, 1),
smolderingGrass (Blocks.holyGrass, 1),
amethystBlock (Blocks.amethystOre, 1),
amethystOre (Blocks.amethystOre, 0),
redRockCobble (Blocks.redRock, 1),
giantFlowerRed (Blocks.petals, 0),
giantFlowerYellow (Blocks.petals, 1),
toadstool (Blocks.flowers, 10),
tinyCactus (Blocks.flowers, 11),
holyTallGrass (Blocks.plants, 4),
desertSprouts (Blocks.plants, 2),
duneGrass (Blocks.plants, 3),
thorn (Blocks.plants, 5),
desertGrass (Blocks.plants, 1),
deadGrass (Blocks.plants, 0),
treeMoss (Blocks.treeMoss, 0),
moss (Blocks.moss, 0),
willow (Blocks.willow, 0),
violet (Blocks.flowers, 8),
hydrangea (Blocks.flowers, 4),
deathbloom (Blocks.flowers, 2),
glowFlower (Blocks.flowers, 3),
anenome (Blocks.flowers, 9),
swampFlower (Blocks.flowers, 1),
wildFlower (Blocks.flowers, 7),
daisy (Blocks.flowers, 5),
tulip (Blocks.flowers, 6),
clover (Blocks.flowers, 0),
;
public Optional<? extends Block> block;
public int meta;
private EnumBlocks(Optional<? extends Block> block, int meta) {
this.block = block;
this.meta = meta;
}
public Optional<? extends Block> getBlock() {
return block;
}
public int getMeta() {
return meta;
}
}
public static ItemStack getBlockItemStack(String string)
{
Optional<? extends Block> stackblock = EnumBlocks.valueOf(string).block;
int stackmeta = EnumBlocks.valueOf(string).meta;
if (stackmeta != 0)
{
return new ItemStack(stackblock.get(), 1, stackmeta);
}
else
{
return new ItemStack(stackblock.get(), 1);
}
}
public static int getBlockID(String string)
{
Optional<? extends Block> stackblock = EnumBlocks.valueOf(string).block;
return stackblock.get().blockID;
}
public static int getBlockMeta(String string)
{
int stackmeta = EnumBlocks.valueOf(string).meta;
return stackmeta;
}
}

View file

@ -0,0 +1,87 @@
package biomesoplenty.api;
import java.util.HashMap;
import java.util.Map;
import net.minecraft.block.Block;
import net.minecraft.block.BlockHalfSlab;
import com.google.common.base.Optional;
public class Blocks
{
// Worldgen Blocks
public static Optional<? extends Block> ash = Optional.absent();
public static Optional<? extends Block> ashStone = Optional.absent();
public static Optional<? extends Block> cragRock = Optional.absent();
public static Optional<? extends Block> driedDirt = Optional.absent();
public static Optional<? extends Block> hardDirt = Optional.absent();
public static Optional<? extends Block> hardIce = Optional.absent();
public static Optional<? extends Block> hardSand = Optional.absent();
public static Optional<? extends Block> holyGrass = Optional.absent();
public static Optional<? extends Block> holyStone = Optional.absent();
public static Optional<? extends Block> mud = Optional.absent();
public static Optional<? extends Block> originGrass = Optional.absent();
public static Optional<? extends Block> redRock = Optional.absent();
// Planks and logs
public static Optional<? extends Block> planks = Optional.absent();
public static Optional<? extends Block> logs1 = Optional.absent();
public static Optional<? extends Block> logs2 = Optional.absent();
public static Optional<? extends Block> logs3 = Optional.absent();
// Stairs
public static Optional<? extends Block> acaciaStairs = Optional.absent();
public static Optional<? extends Block> cherryStairs = Optional.absent();
public static Optional<? extends Block> darkStairs = Optional.absent();
public static Optional<? extends Block> firStairs = Optional.absent();
public static Optional<? extends Block> holyStairs = Optional.absent();
public static Optional<? extends Block> magicStairs = Optional.absent();
public static Optional<? extends Block> mangroveStairs = Optional.absent();
public static Optional<? extends Block> palmStairs = Optional.absent();
public static Optional<? extends Block> redwoodStairs = Optional.absent();
public static Optional<? extends Block> willowStairs = Optional.absent();
public static Optional<? extends Block> redCobbleStairs = Optional.absent();
public static Optional<? extends Block> redBricksStairs = Optional.absent();
public static Optional<? extends Block> mudBricksStairs = Optional.absent();
// Slabs
public static Optional<? extends BlockHalfSlab> woodenSingleSlab1 = Optional.absent();
public static Optional<? extends BlockHalfSlab> woodenDoubleSlab1 = Optional.absent();
public static Optional<? extends BlockHalfSlab> woodenSingleSlab2 = Optional.absent();
public static Optional<? extends BlockHalfSlab> woodenDoubleSlab2 = Optional.absent();
public static Optional<? extends BlockHalfSlab> stoneSingleSlab = Optional.absent();
public static Optional<? extends BlockHalfSlab> stoneDoubleSlab = Optional.absent();
// Plants
public static Optional<? extends Block> flowers = Optional.absent();
public static Optional<? extends Block> leaves1 = Optional.absent();
public static Optional<? extends Block> leaves2 = Optional.absent();
public static Optional<? extends Block> leavesColorized = Optional.absent();
public static Optional<? extends Block> leavesFruit = Optional.absent();
public static Optional<? extends Block> foliage = Optional.absent();
public static Optional<? extends Block> plants = Optional.absent();
public static Optional<? extends Block> flatPlants = Optional.absent();
public static Optional<? extends Block> saplings = Optional.absent();
public static Optional<? extends Block> colorizedSaplings = Optional.absent();
public static Optional<? extends Block> willow = Optional.absent();
public static Optional<? extends Block> treeMoss = Optional.absent();
public static Optional<? extends Block> moss = Optional.absent();
public static Optional<? extends Block> petals = Optional.absent();
public static Optional<? extends Block> bamboo = Optional.absent();
// public static Optional<? extends Block> amethystBlock = Optional.absent();
public static Optional<? extends Block> amethystOre = Optional.absent();
// public static Optional<? extends Block> bambooThatching = Optional.absent();
public static Optional<? extends Block> mudBrick = Optional.absent();
// public static Optional<? extends Block> smolderingGrass = Optional.absent();
// public static Optional<? extends Block> quicksand = Optional.absent();
// public static Optional<? extends Block> grass = Optional.absent();
public static Optional<? extends Block> promisedPortal = Optional.absent();
/**
* Populated by Biomes O Plenty with default Biomes O Plenty leaves. Add additional leaves here (E.g. "Blocks.shearBlockIds.put(acaciaLeaves.blockID, 15.0F);")
*/
public static Map shearBlockIds = new HashMap();
}

View file

@ -0,0 +1,22 @@
package biomesoplenty.api;
public class Entities {
public static Class Mudball = getClass("biomesoplenty.items.projectiles.EntityMudball");
public static Class JungleSpider = getClass("biomesoplenty.mobs.EntityJungleSpider");
public static Class Rosester = getClass("biomesoplenty.mobs.EntityRosester");
public static Class getClass(String inputstring)
{
Class foundclass = null;
try
{
foundclass = Class.forName(inputstring);
}
catch (ClassNotFoundException e)
{
e.printStackTrace();
}
return foundclass;
}
}

View file

@ -0,0 +1,37 @@
package biomesoplenty.api;
import net.minecraft.item.Item;
import com.google.common.base.Optional;
public class Items
{
public static Optional<? extends Item> bopDisc = Optional.absent();
public static Optional<? extends Item> bopDiscMud = Optional.absent();
public static Optional<? extends Item> swordMud = Optional.absent();
public static Optional<? extends Item> shovelMud = Optional.absent();
public static Optional<? extends Item> pickaxeMud = Optional.absent();
public static Optional<? extends Item> axeMud = Optional.absent();
public static Optional<? extends Item> hoeMud = Optional.absent();
public static Optional<? extends Item> helmetMud = Optional.absent();
public static Optional<? extends Item> chestplateMud = Optional.absent();
public static Optional<? extends Item> leggingsMud = Optional.absent();
public static Optional<? extends Item> bootsMud = Optional.absent();
public static Optional<? extends Item> swordAmethyst = Optional.absent();
public static Optional<? extends Item> shovelAmethyst = Optional.absent();
public static Optional<? extends Item> pickaxeAmethyst = Optional.absent();
public static Optional<? extends Item> axeAmethyst = Optional.absent();
public static Optional<? extends Item> hoeAmethyst = Optional.absent();
public static Optional<? extends Item> helmetAmethyst = Optional.absent();
public static Optional<? extends Item> chestplateAmethyst = Optional.absent();
public static Optional<? extends Item> leggingsAmethyst = Optional.absent();
public static Optional<? extends Item> bootsAmethyst = Optional.absent();
public static Optional<? extends Item> ancientStaff = Optional.absent();
public static Optional<? extends Item> enderporter = Optional.absent();
public static Optional<? extends Item> shroomPowder = Optional.absent();
public static Optional<? extends Item> miscItems = Optional.absent();
public static Optional<? extends Item> mudball = Optional.absent();
}

View file

@ -0,0 +1,40 @@
package biomesoplenty.armor;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.item.EnumArmorMaterial;
import net.minecraft.item.ItemArmor;
import net.minecraft.item.ItemStack;
import net.minecraftforge.common.IArmorTextureProvider;
import biomesoplenty.BiomesOPlenty;
import biomesoplenty.CommonProxy;
import biomesoplenty.api.Items;
public class ArmorAmethyst extends ItemArmor implements IArmorTextureProvider
{
public int textureID = 0;
public ArmorAmethyst(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) {
super(par1, par2EnumArmorMaterial, par3, par4);
textureID = par4;
setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public String getArmorTextureFile(ItemStack par1) {
if(par1.itemID == Items.helmetAmethyst.get().itemID||par1.itemID == Items.chestplateAmethyst.get().itemID||par1.itemID == Items.bootsAmethyst.get().itemID){
return CommonProxy.ARMOR_AMETHYST1_PNG;
}
if(par1.itemID == Items.leggingsAmethyst.get().itemID){
return CommonProxy.ARMOR_AMETHYST2_PNG;
}
return null;
}
public void registerIcons(IconRegister iconRegister)
{
if(textureID==0){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethysthelmet"); }
else if(textureID==1){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystchestplate"); }
else if(textureID==2){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystleggings"); }
else if(textureID==3){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:amethystboots"); }
else { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudball"); }
}
}

View file

@ -0,0 +1,40 @@
package biomesoplenty.armor;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.item.EnumArmorMaterial;
import net.minecraft.item.ItemArmor;
import net.minecraft.item.ItemStack;
import net.minecraftforge.common.IArmorTextureProvider;
import biomesoplenty.BiomesOPlenty;
import biomesoplenty.CommonProxy;
import biomesoplenty.api.Items;
public class ArmorMuddy extends ItemArmor implements IArmorTextureProvider
{
public int textureID = 0;
public ArmorMuddy(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) {
super(par1, par2EnumArmorMaterial, par3, par4);
textureID = par4;
setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
}
public String getArmorTextureFile(ItemStack par1) {
if(par1.itemID == Items.helmetMud.get().itemID||par1.itemID == Items.chestplateMud.get().itemID||par1.itemID == Items.bootsMud.get().itemID){
return CommonProxy.ARMOR_MUD1_PNG;
}
if(par1.itemID == Items.leggingsMud.get().itemID){
return CommonProxy.ARMOR_MUD2_PNG;
}
return null;
}
public void registerIcons(IconRegister iconRegister)
{
if(textureID==0){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudhelmet"); }
else if(textureID==1){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudchestplate"); }
else if(textureID==2){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudleggings"); }
else if(textureID==3){ itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudboots"); }
else { itemIcon = iconRegister.registerIcon("BiomesOPlenty:mudball"); }
}
}

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,36 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenTaiga6;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenAlps extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenAlps(int par1)
{
super(par1);
this.topBlock = (byte)Block.stone.blockID;
this.fillerBlock = (byte)Block.stone.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenTaiga6(false);
}
}

View file

@ -0,0 +1,47 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenTaiga3;
import biomesoplenty.worldgen.WorldGenTaiga4;
import biomesoplenty.worldgen.WorldGenTaiga9;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenArctic extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenArctic(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 3;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? new WorldGenTaiga3(false) : (par1Random.nextInt(3) == 0 ? new WorldGenTaiga4(false) : new WorldGenTaiga9(false)));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
}

View file

@ -0,0 +1,59 @@
package biomesoplenty.biomes;
import java.awt.Color;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenBadlands extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenBadlands(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.sandStone.blockID;
this.fillerBlock = (byte)Blocks.hardSand.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.deadBushPerChunk = 4;
this.customBiomeDecorator.reedsPerChunk = -999;
this.customBiomeDecorator.cactiPerChunk = 2;
this.customBiomeDecorator.clayPerChunk = 3;
this.customBiomeDecorator.generateClayInStone = true;
this.customBiomeDecorator.generateSandInStone = true;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 13421723;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,84 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenBambooTree;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenBambooForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenBambooForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 30;
this.customBiomeDecorator.grassPerChunk = 5;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.bushesPerChunk = 5;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenShrub(0, 0) : new WorldGenBambooTree(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 10739795;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 10739795;
}
}

View file

@ -0,0 +1,106 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenBayou1;
import biomesoplenty.worldgen.WorldGenBayou2;
import biomesoplenty.worldgen.WorldGenBayou3;
import biomesoplenty.worldgen.WorldGenMoss;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenBayou extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenBayou(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 15;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.reedsPerChunk = 25;
this.customBiomeDecorator.mudPerChunk = 1;
this.customBiomeDecorator.mudPerChunk2 = 1;
this.customBiomeDecorator.toadstoolsPerChunk = 2;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.waterlilyPerChunk = 2;
this.customBiomeDecorator.cattailsPerChunk = 1;
this.customBiomeDecorator.algaePerChunk = 1;
this.customBiomeDecorator.generatePumpkins = false;
this.waterColorMultiplier = 16767282;
this.spawnableWaterCreatureList.clear();
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(8) == 0 ? new WorldGenBayou3() : (par1Random.nextInt(2) == 0 ? new WorldGenBayou1() : new WorldGenBayou2()));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 9154411;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11591816;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 11322556;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,64 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenBirchForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenBirchForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 5;
this.customBiomeDecorator.grassPerChunk = 3;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.tinyFlowersPerChunk = 6;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return this.worldGeneratorForest;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(3) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
}

View file

@ -0,0 +1,103 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenBog1;
import biomesoplenty.worldgen.WorldGenBog2;
import net.minecraft.block.Block;
import net.minecraft.entity.monster.EntitySlime;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenBog extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenBog(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 30;
this.customBiomeDecorator.grassPerChunk = 30;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.mudPerChunk = 5;
this.customBiomeDecorator.mudPerChunk2 = 5;
this.customBiomeDecorator.deadBushPerChunk = 5;
this.customBiomeDecorator.algaePerChunk = 2;
this.spawnableCreatureList.add(new SpawnListEntry(EntitySlime.class, 10, 1, 3));
this.waterColorMultiplier = 11506176;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenBog2() : new WorldGenBog1());
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(9) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 0) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 2);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 7627817;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 9539892;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 7039816;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,62 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenAutumn;
import biomesoplenty.worldgen.WorldGenTaiga5;
import net.minecraft.block.Block;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenBorealForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenBorealForest(int par1)
{
super(par1);
this.spawnableCreatureList.add(new SpawnListEntry(EntityWolf.class, 5, 4, 4));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 25;
this.customBiomeDecorator.grassPerChunk = 50;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? this.worldGeneratorTrees : (par1Random.nextInt(5) == 0 ? new WorldGenShrub(0,0) : (par1Random.nextInt(3) == 0 ? new WorldGenAutumn(false) : (par1Random.nextInt(3) == 0 ? this.worldGeneratorForest : new WorldGenTaiga5(false)))));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 10467185;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 13225573;
}
}

View file

@ -0,0 +1,47 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenCanyonShrub;
import biomesoplenty.worldgen.WorldGenCanyonTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenCanyon extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenCanyon(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.topBlock = (byte)Blocks.hardDirt.get().blockID;
this.fillerBlock = (byte)Blocks.hardDirt.get().blockID;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.tinyCactiPerChunk = 2;
this.customBiomeDecorator.generatePumpkins = false;
//this.customBiomeDecorator.generateCanyon = true;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenCanyonTree() : new WorldGenCanyonShrub(0,0));
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11123300;
}
}

View file

@ -0,0 +1,76 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenChaparral1;
import biomesoplenty.worldgen.WorldGenChaparral2;
import biomesoplenty.worldgen.WorldGenChaparral3;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenChaparral extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenChaparral(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 8;
this.customBiomeDecorator.grassPerChunk = 20;
this.customBiomeDecorator.bushesPerChunk = 10;
this.customBiomeDecorator.generateStoneInGrass = true;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenChaparral2() : (par1Random.nextInt(5) == 0 ? new WorldGenChaparral1(0, 0) : new WorldGenChaparral3()));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 12638301;
}
}

View file

@ -0,0 +1,49 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenCherry1;
import biomesoplenty.worldgen.WorldGenCherry2;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenCherryBlossomGrove extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenCherryBlossomGrove(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 5;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.pinkFlowersPerChunk = 15;
this.customBiomeDecorator.whiteFlowersPerChunk = 30;
this.customBiomeDecorator.tinyFlowersPerChunk = 25;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenCherry2(false) : new WorldGenCherry1(false));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 10747818;
}
public int getBiomeFoliageColor()
{
return 10747818;
}
}

View file

@ -0,0 +1,70 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenTaiga3;
import biomesoplenty.worldgen.WorldGenTaiga4;
import biomesoplenty.worldgen.WorldGenTaiga9;
import net.minecraft.block.Block;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenConiferousForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenConiferousForest(int par1)
{
super(par1);
this.spawnableCreatureList.add(new SpawnListEntry(EntityWolf.class, 8, 4, 4));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 6;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.toadstoolsPerChunk = 3;
this.customBiomeDecorator.violetsPerChunk = 2;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? new WorldGenTaiga3(false) : (par1Random.nextInt(3) == 0 ? new WorldGenTaiga4(false) : new WorldGenTaiga9(false)));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 2);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
}

View file

@ -0,0 +1,54 @@
package biomesoplenty.biomes;
import java.awt.Color;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenCrag extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenCrag(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.topBlock = (byte)Blocks.cragRock.get().blockID;
this.fillerBlock = (byte)Blocks.cragRock.get().blockID;
this.waterColorMultiplier = 944693;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 4944498;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,90 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenDeadTree;
import biomesoplenty.worldgen.WorldGenDeadTree2;
import biomesoplenty.worldgen.WorldGenTaiga5;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenDeadForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDeadForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 3;
this.customBiomeDecorator.grassPerChunk = 1;
this.customBiomeDecorator.thornsPerChunk = 2;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.reedsPerChunk = -999;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(9) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 0) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenDeadTree(false) : (par1Random.nextInt(4) == 0 ? new WorldGenTaiga5(false): new WorldGenDeadTree2(false)));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 12362085;
}
public int getBiomeFoliageColor()
{
return 12362085;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 9873591;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,94 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenDeadTree;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenDeadSwamp extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDeadSwamp(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.highGrassPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.reedsPerChunk = -999;
this.customBiomeDecorator.mudPerChunk = 3;
this.customBiomeDecorator.mudPerChunk2 = 3;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.waterColorMultiplier = 10661201;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(9) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 2);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenDeadTree(false);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 6713420;
}
public int getBiomeFoliageColor()
{
return 6713420;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 6451816;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,108 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.entity.monster.EntityCreeper;
import net.minecraft.entity.passive.EntityBat;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenMinable;
import net.minecraft.world.gen.feature.WorldGenerator;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenDeadTree3;
import biomesoplenty.worldgen.WorldGenDeadlands;
public class BiomeGenDeadlands extends BiomeGenBase
{
private WorldGenerator theWorldGenerator;
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenDeadlands(int par1)
{
super(par1);
this.topBlock = (byte)Blocks.ash.get().blockID;
this.fillerBlock = (byte)Blocks.ash.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.mushroomsPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.lavaLakesPerChunk = 25;
this.customBiomeDecorator.generatePits = true;
this.customBiomeDecorator.generateSmolderingGrass = true;
this.waterColorMultiplier = 16711680;
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.spawnableCreatureList.add(new SpawnListEntry(EntityCreeper.class, 30, 1, 7));
this.spawnableCaveCreatureList.add(new SpawnListEntry(EntityBat.class, 10, 8, 8));
this.theWorldGenerator = new WorldGenMinable(Block.silverfish.blockID, 8);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenDeadTree3(false);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return new WorldGenDeadlands();
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
int var6;
int var7;
int var8;
for (var5 = 0; var5 < 7; ++var5)
{
var6 = par3 + par2Random.nextInt(16);
var7 = par2Random.nextInt(64);
var8 = par4 + par2Random.nextInt(16);
this.theWorldGenerator.generate(par1World, par2Random, var6, var7, var8);
}
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 4464929;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,62 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenDeciduous;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenDeciduousForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDeciduousForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 15;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.toadstoolsPerChunk = 1;
this.customBiomeDecorator.bushesPerChunk = 8;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(4) == 0 ? new WorldGenShrub(2,2) : new WorldGenDeciduous(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(5) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 12695369;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 12896570;
}
}

View file

@ -0,0 +1,43 @@
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenDesertWells;
public class BiomeGenDesertNew extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDesertNew(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.sand.blockID;
this.fillerBlock = (byte)Block.sand.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.deadBushPerChunk = 2;
this.customBiomeDecorator.reedsPerChunk = 50;
this.customBiomeDecorator.cactiPerChunk = 10;
this.customBiomeDecorator.desertSproutsPerChunk = 1;
this.customBiomeDecorator.tinyCactiPerChunk = 5;
this.customBiomeDecorator.quicksand2PerChunk = 3;
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
if (par2Random.nextInt(1000) == 0)
{
int var5 = par3 + par2Random.nextInt(16) + 8;
int var6 = par4 + par2Random.nextInt(16) + 8;
WorldGenDesertWells var7 = new WorldGenDesertWells();
var7.generate(par1World, par2Random, var5, par1World.getHeightValue(var5, var6) + 1, var6);
}
}
}

View file

@ -0,0 +1,47 @@
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenDrylands extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDrylands(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 4;
this.customBiomeDecorator.thornsPerChunk = 4;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.quicksandPerChunk = 4;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? new WorldGenShrub(0, 0) : this.worldGeneratorTrees);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 13404780;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 13407596;
}
}

View file

@ -0,0 +1,56 @@
package biomesoplenty.biomes;
import java.awt.Color;
import biomesoplenty.configuration.BOPConfiguration;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenDunes extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDunes(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.sand.blockID;
this.fillerBlock = (byte)Block.sand.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.deadBushPerChunk = -999;
this.customBiomeDecorator.duneGrassPerChunk = 10;
this.customBiomeDecorator.desertSproutsPerChunk = 5;
this.customBiomeDecorator.reedsPerChunk = -999;
this.customBiomeDecorator.generateLakes = false;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 14203007;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,88 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenDeadTree;
import biomesoplenty.worldgen.WorldGenFen1;
import biomesoplenty.worldgen.WorldGenFen2;
import biomesoplenty.worldgen.WorldGenMoss;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenFen extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenFen(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.highGrassPerChunk = 1;
this.customBiomeDecorator.waterlilyPerChunk = 1;
this.customBiomeDecorator.cattailsPerChunk = 1;
this.customBiomeDecorator.pondsPerChunk = 99;
this.customBiomeDecorator.toadstoolsPerChunk = 2;
this.customBiomeDecorator.mushroomsPerChunk = 8;
this.customBiomeDecorator.mudPerChunk = 1;
this.customBiomeDecorator.mudPerChunk2 = 1;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.algaePerChunk = 1;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenFen2(false) : (par1Random.nextInt(20) == 0 ? new WorldGenDeadTree(false) : new WorldGenFen1()));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return (par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : (par1Random.nextInt(3) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1)));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 12240001;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 13547897;
}
}

View file

@ -0,0 +1,50 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenTaiga5;
import biomesoplenty.worldgen.WorldGenTaiga8;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenField extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenField(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = 1;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(4) == 0 ? new WorldGenTaiga5(false) : (par1Random.nextInt(8) == 0 ? new WorldGenTaiga8(false) : (par1Random.nextInt(2) == 0 ? this.worldGeneratorTrees : new WorldGenShrub(0,0))));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11186770;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 10467150;
}
}

View file

@ -0,0 +1,52 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenMoss;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenForestNew extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenForestNew(int par1)
{
super(par1);
this.spawnableCreatureList.add(new SpawnListEntry(EntityWolf.class, 5, 4, 4));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 2;
this.customBiomeDecorator.hydrangeasPerChunk = 2;
this.customBiomeDecorator.whiteFlowersPerChunk = 1;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenWhiteOak1() : (par1Random.nextInt(5) == 0 ? new WorldGenAlder2() : (par1Random.nextInt(8) == 0 ? new WorldGenAlder1() : (par1Random.nextInt(4) == 0 ? new WorldGenPaperBirch2() : (par1Random.nextInt(7) == 0 ? new WorldGenPaperBirch1() : new WorldGenWhiteOak2())))));
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? this.worldGeneratorForest : (par1Random.nextInt(10) == 0 ? this.worldGeneratorBigTree : this.worldGeneratorTrees));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
}

View file

@ -0,0 +1,77 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenFrostForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenFrostForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 3;
this.customBiomeDecorator.grassPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.mushroomsPerChunk = -999;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return this.worldGeneratorTrees;
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11261628;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11261628;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 13557994;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,106 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenMoss;
import biomesoplenty.worldgen.WorldGenSwampTall;
import biomesoplenty.worldgen.WorldGenThickTree;
import net.minecraft.entity.passive.EntityMooshroom;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenFungiForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenFungiForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 4;
this.customBiomeDecorator.grassPerChunk = 5;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.mushroomsPerChunk = 8;
this.customBiomeDecorator.bigMushroomsPerChunk = 4;
this.customBiomeDecorator.toadstoolsPerChunk = 5;
this.customBiomeDecorator.blueFlowersPerChunk = 3;
this.customBiomeDecorator.generateMycelium = true;
this.customBiomeDecorator.generatePumpkins = false;
this.waterColorMultiplier = 65326;
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.spawnableCreatureList.add(new SpawnListEntry(EntityMooshroom.class, 3, 4, 8));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenThickTree(false) : new WorldGenSwampTall());
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 5359235;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 5359235;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 5888980;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,94 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.mobs.EntityRosester;
import biomesoplenty.worldgen.WorldGenGiantFlowerRed;
import biomesoplenty.worldgen.WorldGenGiantFlowerYellow;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenGarden extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenGarden(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = 20;
this.customBiomeDecorator.whiteFlowersPerChunk = 25;
this.customBiomeDecorator.tinyFlowersPerChunk = 15;
this.customBiomeDecorator.sproutsPerChunk = 1;
this.customBiomeDecorator.rosesPerChunk = 20;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.bushesPerChunk = 10;
this.customBiomeDecorator.generatePumpkins = false;
this.spawnableCreatureList.clear();
this.spawnableCreatureList.add(new SpawnListEntry(EntityRosester.class, 10, 4, 4));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(3) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 1) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenGiantFlowerRed() : new WorldGenGiantFlowerYellow());
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 3785757;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 5364530;
}
}

View file

@ -0,0 +1,26 @@
package biomesoplenty.biomes;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenGlacier extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenGlacier(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Blocks.hardIce.get().blockID;
this.fillerBlock = (byte)Blocks.hardIce.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
}
}

View file

@ -0,0 +1,84 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.block.Block;
import net.minecraft.entity.passive.EntityChicken;
import net.minecraft.entity.passive.EntityCow;
import net.minecraft.entity.passive.EntityPig;
import net.minecraft.entity.passive.EntitySheep;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenGrassland extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenGrassland(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = 2;
this.customBiomeDecorator.reedsPerChunk = 25;
this.customBiomeDecorator.mushroomsPerChunk = 20;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.waterLakesPerChunk = 15;
this.customBiomeDecorator.generatePumpkins = false;
this.spawnableCreatureList.add(new SpawnListEntry(EntitySheep.class, 14, 4, 4));
this.spawnableCreatureList.add(new SpawnListEntry(EntityPig.class, 12, 4, 4));
this.spawnableCreatureList.add(new SpawnListEntry(EntityChicken.class, 12, 4, 4));
this.spawnableCreatureList.add(new SpawnListEntry(EntityCow.class, 10, 4, 4));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(3) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 8379261;
}
public int getBiomeFoliageColor()
{
return 8379261;
}
}

View file

@ -0,0 +1,49 @@
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenGrove extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenGrove(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 6;
this.customBiomeDecorator.flowersPerChunk = 5;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.sproutsPerChunk = 2;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenShrub(2,2) : this.worldGeneratorBigTree);
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenNorwaySpruce1() : new WorldGenNorwaySpruce2());
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 8298592;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 7445333;
}
}

View file

@ -0,0 +1,51 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenHeath;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenHeathland extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenHeathland(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.purpleFlowersPerChunk = 30;
this.customBiomeDecorator.deadBushPerChunk = 2;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenShrub(0, 0) : new WorldGenHeath(false));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 13550967;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11454081;
}
}

View file

@ -0,0 +1,20 @@
package biomesoplenty.biomes;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenHighland extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenHighland(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.highGrassPerChunk = 25;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.potatoesPerChunk = -999;
this.customBiomeDecorator.generateBoulders = true;
}
}

View file

@ -0,0 +1,54 @@
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenMinable;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenHillsNew extends BiomeGenBase
{
private WorldGenerator theWorldGenerator;
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenHillsNew(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.violetsPerChunk = 5;
this.theWorldGenerator = new WorldGenMinable(Block.silverfish.blockID, 8);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
int var6;
int var7;
int var8;
for (var6 = 0; var6 < var5; ++var6)
{
var7 = par3 + par2Random.nextInt(16);
var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
for (var5 = 0; var5 < 7; ++var5)
{
var6 = par3 + par2Random.nextInt(16);
var7 = par2Random.nextInt(64);
var8 = par4 + par2Random.nextInt(16);
this.theWorldGenerator.generate(par1World, par2Random, var6, var7, var8);
}
}
}

View file

@ -0,0 +1,24 @@
package biomesoplenty.biomes;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenIceSheet extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenIceSheet(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.ice.blockID;
this.fillerBlock = (byte)Block.ice.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
}
}

View file

@ -0,0 +1,68 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenIceTree;
import net.minecraft.block.Block;
import net.minecraft.entity.monster.EntitySnowman;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenIcyHills extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenIcyHills(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.blockSnow.blockID;
this.fillerBlock = (byte)Block.blockSnow.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = -999;
this.spawnableCreatureList.add(new SpawnListEntry(EntitySnowman.class, 30, 2, 4));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenIceTree(false);
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 16777215;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,97 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenJadeTree;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenJadeCliffs extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenJadeCliffs(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 12;
this.customBiomeDecorator.grassPerChunk = 3;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(4) == 0 ? new WorldGenShrub(0, 1) : new WorldGenJadeTree(false));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 12045485;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 8168808;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 9096298;
}
}

View file

@ -0,0 +1,90 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.mobs.EntityJungleSpider;
import net.minecraft.block.Block;
import net.minecraft.entity.passive.EntityChicken;
import net.minecraft.entity.passive.EntityOcelot;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenHugeTrees;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenTrees;
import net.minecraft.world.gen.feature.WorldGenVines;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenJungleNew extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenJungleNew(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 45;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.flowersPerChunk = 4;
this.customBiomeDecorator.orangeFlowersPerChunk = 5;
this.customBiomeDecorator.quicksandPerChunk = 1;
this.customBiomeDecorator.generateMelons = true;
this.waterColorMultiplier = 10745289;
this.spawnableMonsterList.add(new SpawnListEntry(EntityOcelot.class, 2, 1, 1));
this.spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6));
this.spawnableCreatureList.add(new SpawnListEntry(EntityChicken.class, 10, 4, 4));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
//return (WorldGenerator)(par1Random.nextInt(5) == 0 ? new WorldGenBrazilNut1() : (par1Random.nextInt(10) == 0 ? new WorldGenSandboxTree1() : (par1Random.nextInt(2) == 0 ? new WorldGenBrazilNut2() : (par1Random.nextInt(3) == 0 ? new WorldGenSandboxTree2() : new WorldGenShrub(3, 0)))));
return (WorldGenerator)(par1Random.nextInt(10) == 0 ? this.worldGeneratorBigTree : (par1Random.nextInt(2) == 0 ? new WorldGenShrub(3, 0) : (par1Random.nextInt(3) == 0 ? new WorldGenHugeTrees(false, 10 + par1Random.nextInt(20), 3, 3) : new WorldGenTrees(false, 4 + par1Random.nextInt(7), 3, 3, true))));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenVines var5 = new WorldGenVines();
for (int var6 = 0; var6 < 50; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 32;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 5232218;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 3266623;
}
}

View file

@ -0,0 +1,46 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenAcacia;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenLushDesert extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenLushDesert(int par1)
{
super(par1);
this.topBlock = (byte)Blocks.redRock.get().blockID;
this.fillerBlock = (byte)Blocks.redRock.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 8;
this.customBiomeDecorator.grassPerChunk = 8;
this.customBiomeDecorator.oasesPerChunk = 999;
this.customBiomeDecorator.oasesPerChunk2 = 999;
this.customBiomeDecorator.deadBushPerChunk = 2;
this.customBiomeDecorator.purpleFlowersPerChunk = 5;
this.customBiomeDecorator.desertGrassPerChunk = 10;
this.customBiomeDecorator.desertCactiPerChunk = 10;
this.customBiomeDecorator.cactiPerChunk = 20;
this.customBiomeDecorator.tinyCactiPerChunk = 5;
this.customBiomeDecorator.generateGrass = true;
this.customBiomeDecorator.generateSand = true;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenAcacia(false) : new WorldGenShrub(0, 0));
}
}

View file

@ -0,0 +1,60 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenSwampTall;
import net.minecraft.block.Block;
import net.minecraft.entity.monster.EntitySlime;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenLushSwamp extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenLushSwamp(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 4;
this.customBiomeDecorator.mushroomsPerChunk = 8;
this.customBiomeDecorator.reedsPerChunk = 16;
this.customBiomeDecorator.cattailsPerChunk = 10;
this.customBiomeDecorator.waterlilyPerChunk = 3;
this.customBiomeDecorator.hydrangeasPerChunk = 1;
this.spawnableMonsterList.add(new SpawnListEntry(EntitySlime.class, 1, 1, 1));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenSwampTall() : this.worldGeneratorSwamp);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
}

View file

@ -0,0 +1,38 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenMangrove;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMangrove extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenMangrove(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.sand.blockID;
this.fillerBlock = (byte)Block.sand.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 6;
this.customBiomeDecorator.deadBushPerChunk = 1;
this.customBiomeDecorator.deadGrassPerChunk = 9;
this.customBiomeDecorator.reedsPerChunk = -999;
this.customBiomeDecorator.cactiPerChunk = -999;
this.customBiomeDecorator.desertSproutsPerChunk = 1;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenMangrove(false);
}
}

View file

@ -0,0 +1,32 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenMaple;
import biomesoplenty.worldgen.WorldGenTaiga5;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMapleWoods extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenMapleWoods(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 9;
this.customBiomeDecorator.grassPerChunk = 1;
this.customBiomeDecorator.violetsPerChunk = 1;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(6) == 0 ? new WorldGenTaiga5(false) : new WorldGenMaple(false));
}
}

View file

@ -0,0 +1,55 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenMarsh;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMarsh extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenMarsh(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = 65;
this.customBiomeDecorator.highGrassPerChunk = 25;
this.customBiomeDecorator.generatePumpkins = false;
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMarsh var5 = new WorldGenMarsh();
for (int var6 = 0; var6 < 25; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 62;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
}

View file

@ -0,0 +1,71 @@
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTaiga2;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMeadow extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenMeadow(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.tinyFlowersPerChunk = 14;
this.customBiomeDecorator.flowersPerChunk = 10;
this.customBiomeDecorator.carrotsPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.hydrangeasPerChunk = 3;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenTaiga2(false) : new WorldGenShrub(0, 1));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 6533741;
}
public int getBiomeFoliageColor()
{
return 6533741;
}
}

View file

@ -0,0 +1,59 @@
package biomesoplenty.biomes;
import java.awt.Color;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import net.minecraft.entity.monster.EntitySpider;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
public class BiomeGenMesa extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenMesa(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Blocks.redRock.get().blockID;
this.fillerBlock = (byte)Blocks.redRock.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.deadBushPerChunk = 2;
this.customBiomeDecorator.desertGrassPerChunk = 10;
this.customBiomeDecorator.tinyCactiPerChunk = 2;
this.spawnableMonsterList.add(new SpawnListEntry(EntitySpider.class, 15, 2, 6));
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 15898486;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,101 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenMoor;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMoor extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenMoor(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.mudPerChunk = 1;
this.customBiomeDecorator.mudPerChunk2 = 1;
this.waterColorMultiplier = 5800566;
this.customBiomeDecorator.generatePumpkins = false;
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoor var5 = new WorldGenMoor();
for (int var6 = 0; var6 < 16; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 64;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return (par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : (par1Random.nextInt(3) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1)));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 6394725;
}
public int getBiomeFoliageColor()
{
return 6394725;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 10536403;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,31 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenTaiga7;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTaiga2;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMountain extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenMountain(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.grassPerChunk = 3;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(8) == 0 ? new WorldGenTaiga2(false) : (par1Random.nextInt(4) == 0 ? new WorldGenTaiga7(false) : this.worldGeneratorTrees));
}
}

View file

@ -0,0 +1,102 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenMystic1;
import biomesoplenty.worldgen.WorldGenMystic2;
import net.minecraft.block.Block;
import net.minecraft.entity.monster.EntityWitch;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenMysticGrove extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenMysticGrove(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 8;
this.customBiomeDecorator.grassPerChunk = 7;
this.customBiomeDecorator.flowersPerChunk = 8;
this.customBiomeDecorator.pinkFlowersPerChunk = 6;
this.customBiomeDecorator.glowFlowersPerChunk = 15;
this.customBiomeDecorator.rosesPerChunk = 8;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.sproutsPerChunk = 3;
this.customBiomeDecorator.hydrangeasPerChunk = 3;
this.waterColorMultiplier = 15349914;
this.spawnableMonsterList.clear();
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.spawnableMonsterList.add(new SpawnListEntry(EntityWitch.class, 10, 4, 4));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? new WorldGenMystic2(false) : new WorldGenMystic1(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 7004860;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 3530896;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 16751558;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,44 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenPalmTree3;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenOasis extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenOasis(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.sand.blockID;
this.fillerBlock = (byte)Block.sand.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 3;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.reedsPerChunk = 100;
this.customBiomeDecorator.oasesPerChunk = 999;
this.customBiomeDecorator.oasesPerChunk2 = 999;
this.customBiomeDecorator.cactiPerChunk = 7;
this.customBiomeDecorator.desertSproutsPerChunk = 3;
this.customBiomeDecorator.tinyCactiPerChunk = 2;
this.customBiomeDecorator.generatePumpkins = false;
this.customBiomeDecorator.generateMelons = true;
this.customBiomeDecorator.waterLakesPerChunk = 10;
this.customBiomeDecorator.quicksand2PerChunk = 2;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenPalmTree3();
}
}

View file

@ -0,0 +1,106 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenOminous1;
import biomesoplenty.worldgen.WorldGenOminous2;
import net.minecraft.block.Block;
import net.minecraft.entity.monster.EntityCaveSpider;
import net.minecraft.entity.monster.EntityEnderman;
import net.minecraft.entity.passive.EntityBat;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenOminousWoods extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenOminousWoods(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.deathbloomsPerChunk = 1;
this.customBiomeDecorator.mushroomsPerChunk = 8;
this.customBiomeDecorator.reedsPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.thornsPerChunk = 9;
this.waterColorMultiplier = 1973030;
this.spawnableMonsterList.clear();
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.spawnableMonsterList.add(new SpawnListEntry(EntityCaveSpider.class, 15, 1, 2));
this.spawnableMonsterList.add(new SpawnListEntry(EntityEnderman.class, 10, 1, 4));
this.spawnableCaveCreatureList.add(new SpawnListEntry(EntityBat.class, 10, 8, 8));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenWillow2() : (par1Random.nextInt(7) == 0 ? new WorldGenDarkTree1() : (par1Random.nextInt(5) == 0 ? new WorldGenWillow1() : new WorldGenDarkTree2())));
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenOminous1(false) : new WorldGenOminous2());
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(6) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 0) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 4145489;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 4145489;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 5069168;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,47 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenApple;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenOrchard extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenOrchard(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.flowersPerChunk = 20;
this.customBiomeDecorator.whiteFlowersPerChunk = 20;
this.customBiomeDecorator.tinyFlowersPerChunk = 20;
this.customBiomeDecorator.grassPerChunk = 15;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenAppleTree1() : new WorldGenAppleTree2());
return new WorldGenApple(false);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 14024557;
}
public int getBiomeFoliageColor()
{
return 14024557;
}
}

View file

@ -0,0 +1,82 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenOriginTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenOriginValley extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenOriginValley(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.topBlock = (byte)Blocks.originGrass.get().blockID;
this.customBiomeDecorator.treesPerChunk = 4;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.generatePumpkins = false;
this.customBiomeDecorator.sandPerChunk = 0;
this.customBiomeDecorator.sandPerChunk2 = 0;
this.customBiomeDecorator.clayPerChunk = 0;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenOriginTree(false);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 10682207;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 3866368;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 8703228;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,42 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenOutbackShrub;
import biomesoplenty.worldgen.WorldGenOutbackTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenOutback extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenOutback(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.topBlock = (byte)Blocks.hardSand.get().blockID;
this.fillerBlock = (byte)Blocks.hardSand.get().blockID;
this.customBiomeDecorator.treesPerChunk = 3;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.outbackPerChunk = 10;
this.customBiomeDecorator.deadBushPerChunk = 7;
this.customBiomeDecorator.tinyCactiPerChunk = 2;
this.customBiomeDecorator.bushesPerChunk = 5;
this.customBiomeDecorator.quicksandPerChunk = 1;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenOutbackShrub(0,0) : new WorldGenOutbackTree());
}
}

View file

@ -0,0 +1,58 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenPasture extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenPasture(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 0;
this.customBiomeDecorator.grassPerChunk = 999;
this.customBiomeDecorator.flowersPerChunk = -999;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return new WorldGenTallGrass(Blocks.plants.get().blockID, 6);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return this.worldGeneratorBigTree;
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 15259456;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 13166666;
}
}

View file

@ -0,0 +1,35 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenPlainsNew extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenPlainsNew(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = 4;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.tinyFlowersPerChunk = 1;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
}

View file

@ -0,0 +1,44 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenPrairie;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenPrairie extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenPrairie(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.grassPerChunk = 999;
this.customBiomeDecorator.whiteFlowersPerChunk = 45;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenPrairie(false);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return (par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : (par1Random.nextInt(3) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1)));
}
}

View file

@ -0,0 +1,118 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenPromisedShrub;
import biomesoplenty.worldgen.WorldGenPromisedTree;
import biomesoplenty.worldgen.WorldGenPromisedTree2;
import biomesoplenty.worldgen.WorldGenPromisedTree3;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenMinable;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenPromisedLand extends BiomeGenBase
{
private WorldGenerator theWorldGenerator;
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenPromisedLand(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.topBlock = (byte)Blocks.holyGrass.get().blockID;
this.fillerBlock = (byte)Blocks.holyStone.get().blockID;
this.customBiomeDecorator.treesPerChunk = 8;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.holyTallGrassPerChunk = 50;
this.customBiomeDecorator.promisedWillowPerChunk = 80;
this.customBiomeDecorator.pinkFlowersPerChunk = 6;
this.customBiomeDecorator.glowFlowersPerChunk = 3;
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.spawnableMonsterList.clear();
this.spawnableCaveCreatureList.clear();
this.customBiomeDecorator.generatePumpkins = false;
this.theWorldGenerator = new WorldGenMinable(Block.waterMoving.blockID, 8);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenPromisedShrub(0, 0) : (par1Random.nextInt(4) == 0 ? new WorldGenPromisedTree3(false) : (par1Random.nextInt(8) == 0 ? new WorldGenPromisedTree2(false) : new WorldGenPromisedTree(false))));
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 4583331;
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 100;
int var6;
int var7;
int var8;
for (var6 = 0; var6 < var5; ++var6)
{
var7 = par3 + par2Random.nextInt(16);
var8 = par2Random.nextInt(30) + 30;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Blocks.amethystOre.get().blockID, 0, 2);
}
}
for (var5 = 0; var5 < 12; ++var5)
{
var6 = par3 + par2Random.nextInt(16);
var7 = par2Random.nextInt(60);
var8 = par4 + par2Random.nextInt(16);
this.theWorldGenerator.generate(par1World, par2Random, var6, var7, var8);
}
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 50175;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,84 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenDeadTree;
public class BiomeGenQuagmire extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenQuagmire(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.topBlock = (byte)Blocks.mud.get().blockID;
this.fillerBlock = (byte)Blocks.mud.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 0;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.waterColorMultiplier = 13390080;
this.customBiomeDecorator.generateQuagmire = true;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenDeadTree(false);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 10390377;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 10390377;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 12436670;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,68 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.mobs.EntityJungleSpider;
import biomesoplenty.worldgen.WorldGenRainforestTree1;
import net.minecraft.block.Block;
import net.minecraft.entity.passive.EntityOcelot;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenRainforest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenRainforest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 14;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.pinkFlowersPerChunk = 2;
this.customBiomeDecorator.flowersPerChunk = 25;
this.customBiomeDecorator.rosesPerChunk = 10;
this.customBiomeDecorator.mushroomsPerChunk = 25;
this.customBiomeDecorator.orangeFlowersPerChunk = 6;
this.customBiomeDecorator.generatePumpkins = false;
this.spawnableMonsterList.add(new SpawnListEntry(EntityOcelot.class, 2, 1, 1));
this.spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(15) == 0 ? this.worldGeneratorForest : (par1Random.nextInt(5) == 0 ? this.worldGeneratorBigTree : new WorldGenRainforestTree1(false)));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 1759340;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 1368687;
}
}

View file

@ -0,0 +1,44 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenRedwoodTree;
import biomesoplenty.worldgen.WorldGenRedwoodTree2;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenRedwoodForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenRedwoodForest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 16;
this.customBiomeDecorator.bushesPerChunk = 4;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenRedwood2() : new WorldGenRedwood1());
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenRedwoodTree(false) : new WorldGenRedwoodTree2(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
}

View file

@ -0,0 +1,103 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.mobs.EntityJungleSpider;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSacredSprings extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenSacredSprings(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 30;
this.customBiomeDecorator.grassPerChunk = 4;
this.customBiomeDecorator.waterlilyPerChunk = 5;
this.customBiomeDecorator.violetsPerChunk = 1;
this.customBiomeDecorator.generatePumpkins = false;
this.spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenShrub(0, 0);
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = par2Random.nextInt(75);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(53) + 75;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID || var10 == Block.dirt.blockID)
{
par1World.setBlock(var7, var8, var9, Block.waterMoving.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 39259;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 39259;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 1995007;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,48 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenAcacia;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSavanna extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenSavanna(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.purpleFlowersPerChunk = 10;
this.customBiomeDecorator.tinyFlowersPerChunk = 2;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenShrub(0, 0) : new WorldGenAcacia(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
}

View file

@ -0,0 +1,44 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenScrubland;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenScrubland extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenScrubland(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 7;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.highGrassPerChunk = 2;
this.customBiomeDecorator.grassPerChunk = 30;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenShrub(0, 0) : new WorldGenScrubland(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(5) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 0) : new WorldGenTallGrass(Block.tallGrass.blockID, 1);
}
}

View file

@ -0,0 +1,68 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenAutumn;
import biomesoplenty.worldgen.WorldGenAutumn2;
import biomesoplenty.worldgen.WorldGenDeadTree2;
import biomesoplenty.worldgen.WorldGenMaple;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSeasonalForest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenSeasonalForest(int par1)
{
super(par1);
this.spawnableCreatureList.add(new SpawnListEntry(EntityWolf.class, 5, 4, 4));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 20;
this.customBiomeDecorator.grassPerChunk = 8;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.toadstoolsPerChunk = 4;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenAutumn2(false) : (par1Random.nextInt(3) == 0 ? new WorldGenAutumn(false) : (par1Random.nextInt(3) == 0 ? new WorldGenMaple(false) : (par1Random.nextInt(5) == 0 ? new WorldGenDeadTree2(false) : this.worldGeneratorTrees))));
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11781186;
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 12502092;
//return 12502595;
}
}

View file

@ -0,0 +1,68 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenMoss;
import biomesoplenty.worldgen.WorldGenTaiga5;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenShield extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenShield(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 7;
this.customBiomeDecorator.grassPerChunk = 12;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.gravelPerChunk = 4;
this.customBiomeDecorator.gravelPerChunk2 = 4;
this.customBiomeDecorator.generateStoneInGrass2 = true;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(2) == 0 ? new WorldGenShrub(0,0) : new WorldGenTaiga5(false));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 6586168;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 7902787;
}
}

View file

@ -0,0 +1,12 @@
package biomesoplenty.biomes;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenShore extends BiomeGenBase
{
public BiomeGenShore(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
}
}

View file

@ -0,0 +1,45 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenShrubland extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenShrubland(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 0;
this.customBiomeDecorator.flowersPerChunk = 0;
this.customBiomeDecorator.grassPerChunk = 5;
this.customBiomeDecorator.bushesPerChunk = 7;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenShrub(0, 0);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
}

View file

@ -0,0 +1,90 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenDeadTree;
import biomesoplenty.worldgen.WorldGenDeadTree2;
import biomesoplenty.worldgen.WorldGenTaiga5;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSnowyWoods extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenSnowyWoods(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 2;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.reedsPerChunk = -999;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(6) == 0 ? new WorldGenDeadTree2(false) : (par1Random.nextInt(3) == 0 ? new WorldGenTaiga5(false): new WorldGenDeadTree(false)));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11176526;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11903827;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 9873591;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,36 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenTaiga5;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTaiga2;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSpruceWoods extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenSpruceWoods(int par1)
{
super(par1);
this.spawnableCreatureList.add(new SpawnListEntry(EntityWolf.class, 8, 4, 4));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 6;
this.customBiomeDecorator.sproutsPerChunk = 3;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenTaiga5(false) : new WorldGenTaiga2(false));
}
}

View file

@ -0,0 +1,54 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSteppe extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenSteppe(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = 15;
this.customBiomeDecorator.deadBushPerChunk = 7;
this.customBiomeDecorator.tinyCactiPerChunk = 1;
this.customBiomeDecorator.quicksandPerChunk = 1;
this.customBiomeDecorator.steppePerChunk = 6;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return (par1Random.nextInt(8) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : (par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1)));
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 13413215;
}
public int getBiomeFoliageColor()
{
return 13413215;
}
}

View file

@ -0,0 +1,81 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.worldgen.WorldGenLog;
import biomesoplenty.worldgen.WorldGenMoss;
import biomesoplenty.worldgen.WorldGenWillow;
import net.minecraft.entity.monster.EntitySlime;
import net.minecraft.world.ColorizerFoliage;
import net.minecraft.world.ColorizerGrass;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSwampNew extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenSwampNew(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 4;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.deadBushPerChunk = 1;
this.customBiomeDecorator.mushroomsPerChunk = 8;
this.customBiomeDecorator.reedsPerChunk = 10;
this.customBiomeDecorator.clayPerChunk = 1;
this.customBiomeDecorator.waterlilyPerChunk = 4;
this.customBiomeDecorator.mudPerChunk = 9;
this.customBiomeDecorator.mudPerChunk2 = 9;
this.waterColorMultiplier = 14745456;
this.spawnableMonsterList.add(new SpawnListEntry(EntitySlime.class, 1, 1, 1));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenLog() : new WorldGenWillow());
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
double var1 = (double)this.getFloatTemperature();
double var3 = (double)this.getFloatRainfall();
return ((ColorizerGrass.getGrassColor(var1, var3) & 16711422) + 5115470) / 2;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
double var1 = (double)this.getFloatTemperature();
double var3 = (double)this.getFloatRainfall();
return ((ColorizerFoliage.getFoliageColor(var1, var3) & 16711422) + 5115470) / 2;
}
}

View file

@ -0,0 +1,86 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenCypress;
import biomesoplenty.worldgen.WorldGenMarsh;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenSwampwoods extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenSwampwoods(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 12;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = 10;
this.customBiomeDecorator.highGrassPerChunk = 10;
this.customBiomeDecorator.mudPerChunk = 2;
this.customBiomeDecorator.mudPerChunk2 = 2;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
this.customBiomeDecorator.algaePerChunk = 2;
this.customBiomeDecorator.waterlilyPerChunk = 4;
this.customBiomeDecorator.generatePumpkins = false;
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMarsh var5 = new WorldGenMarsh();
for (int var6 = 0; var6 < 5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 62;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenShrub(0,0) : new WorldGenCypress(false));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 2);
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 1660473;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 2324303;
}
}

View file

@ -0,0 +1,49 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.item.ItemStack;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenTaiga1;
import net.minecraft.world.gen.feature.WorldGenTaiga2;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenTaigaNew extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenTaigaNew(int par1)
{
super(par1);
this.spawnableCreatureList.add(new SpawnListEntry(EntityWolf.class, 8, 4, 4));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 10;
this.customBiomeDecorator.grassPerChunk = 1;
this.customBiomeDecorator.violetsPerChunk = 1;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenTaiga1() : new WorldGenTaiga2(false));
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenNorwaySpruce1() : new WorldGenNorwaySpruce2());
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return new WorldGenTallGrass(Blocks.foliage.get().blockID, 1);
}
}

View file

@ -0,0 +1,80 @@
package biomesoplenty.biomes;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.worldgen.WorldGenMoss;
import biomesoplenty.worldgen.WorldGenTemperate;
import biomesoplenty.worldgen.WorldGenThickTree;
import biomesoplenty.worldgen.WorldGenWillow;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenTemperateRainforest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenTemperateRainforest(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 22;
this.customBiomeDecorator.grassPerChunk = 25;
this.customBiomeDecorator.generatePumpkins = false;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
//return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenGrandFir1() : (par1Random.nextInt(4) == 0 ? new WorldGenAlaskanCedar2() : (par1Random.nextInt(8) == 0 ? new WorldGenAlaskanCedar1() : (par1Random.nextInt(2) == 0 ? new WorldGenShrub(0,0) : new WorldGenGrandFir2()))));
return (WorldGenerator)(par1Random.nextInt(10) == 0 ? new WorldGenWillow() : (par1Random.nextInt(6) == 0 ? new WorldGenThickTree(false) : (par1Random.nextInt(2) == 0 ? new WorldGenTemperate(false) : new WorldGenShrub(0, 0))));
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
return (par1Random.nextInt(6) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : (par1Random.nextInt(2) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : (par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Blocks.foliage.get().blockID, 2) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 1))));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
WorldGenMoss var5 = new WorldGenMoss();
for (int var6 = 0; var6 < 20; ++var6)
{
int var7 = par3 + par2Random.nextInt(16) + 8;
byte var8 = 58;
int var9 = par4 + par2Random.nextInt(16) + 8;
var5.generate(par1World, par2Random, var7, var8, var9);
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11981671;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 12311907;
}
}

View file

@ -0,0 +1,51 @@
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenShrub;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenThicket extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenThicket(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 17;
this.customBiomeDecorator.grassPerChunk = 1;
this.customBiomeDecorator.thornsPerChunk = 25;
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? this.worldGeneratorTrees : new WorldGenShrub(0, 0));
}
}

View file

@ -0,0 +1,112 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.mobs.EntityJungleSpider;
import biomesoplenty.worldgen.WorldGenRainforest1;
import biomesoplenty.worldgen.WorldGenRainforest2;
import net.minecraft.block.Block;
import net.minecraft.entity.passive.EntityOcelot;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenTropicalRainforest extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenTropicalRainforest(int par1)
{
super(par1);
this.spawnableMonsterList.add(new SpawnListEntry(EntityOcelot.class, 2, 1, 1));
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 12;
this.customBiomeDecorator.grassPerChunk = 7;
this.customBiomeDecorator.highGrassPerChunk = 4;
this.customBiomeDecorator.reedsPerChunk = 10;
this.customBiomeDecorator.waterlilyPerChunk = 2;
this.customBiomeDecorator.orangeFlowersPerChunk = 10;
this.customBiomeDecorator.generatePumpkins = false;
this.customBiomeDecorator.generateMelons = true;
this.customBiomeDecorator.sproutsPerChunk = 2;
this.customBiomeDecorator.quicksandPerChunk = 3;
this.spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6));
this.waterColorMultiplier = 6160128;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(5) == 0 ? new WorldGenRainforest2() : new WorldGenRainforest1(false));
}
public void decorate(World par1World, Random par2Random, int par3, int par4)
{
super.decorate(par1World, par2Random, par3, par4);
int var5 = 3 + par2Random.nextInt(6);
for (int var6 = 0; var6 < var5; ++var6)
{
int var7 = par3 + par2Random.nextInt(16);
int var8 = par2Random.nextInt(28) + 4;
int var9 = par4 + par2Random.nextInt(16);
int var10 = par1World.getBlockId(var7, var8, var9);
if (var10 == Block.stone.blockID)
{
par1World.setBlock(var7, var8, var9, Block.oreEmerald.blockID, 0, 2);
}
}
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11002176;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 8970560;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 12971089;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,71 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.mobs.EntityJungleSpider;
import biomesoplenty.worldgen.WorldGenPalmTree1;
import biomesoplenty.worldgen.WorldGenPalmTree3;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.biome.SpawnListEntry;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenTropics extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
@SuppressWarnings("unchecked")
public BiomeGenTropics(int par1)
{
super(par1);
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 8;
this.customBiomeDecorator.grassPerChunk = 7;
this.customBiomeDecorator.flowersPerChunk = 10;
this.customBiomeDecorator.sandPerChunk = 50;
this.customBiomeDecorator.sandPerChunk2 = 50;
this.customBiomeDecorator.orangeFlowersPerChunk = 10;
this.customBiomeDecorator.whiteFlowersPerChunk = 4;
this.customBiomeDecorator.generatePumpkins = false;
this.spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6));
this.spawnableCreatureList.clear();
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(3) == 0 ? new WorldGenPalmTree1() : new WorldGenPalmTree3());
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 3333631;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,37 @@
package biomesoplenty.biomes;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenTundra extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenTundra(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.sandPerChunk = -999;
this.customBiomeDecorator.sandPerChunk2 = -999;
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11176526;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11903827;
}
}

View file

@ -0,0 +1,67 @@
package biomesoplenty.biomes;
import java.awt.Color;
import java.util.Random;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import biomesoplenty.worldgen.WorldGenVolcano;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
public class BiomeGenVolcano extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenVolcano(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Blocks.ashStone.get().blockID;
this.fillerBlock = (byte)Blocks.ashStone.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = 1;
this.customBiomeDecorator.flowersPerChunk = -999;
this.customBiomeDecorator.grassPerChunk = -999;
this.customBiomeDecorator.lavaLakesPerChunk = 50;
this.customBiomeDecorator.generateAsh = true;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return new WorldGenVolcano();
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 8026746;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

View file

@ -0,0 +1,71 @@
package biomesoplenty.biomes;
import java.awt.Color;
import biomesoplenty.api.Blocks;
import biomesoplenty.configuration.BOPBlocks;
import biomesoplenty.configuration.BOPConfiguration;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeGenWasteland extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenWasteland(int par1)
{
super(par1);
this.topBlock = (byte)Blocks.driedDirt.get().blockID;
this.fillerBlock = (byte)Blocks.driedDirt.get().blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.deadGrassPerChunk = 14;
this.waterColorMultiplier = 15073024;
this.spawnableCreatureList.clear();
this.spawnableWaterCreatureList.clear();
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 10330232;
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 10067541;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 10465942;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}

Some files were not shown because too many files have changed in this diff Show more