Jump to content

Recommended Posts

Posted

I have made a mod for the current version of Forge. I want to make the mod for a server too! When I go into my MCP folder, and I run the server, I can't use the items. So, I am just wondering if I need to do something like create a class to implement server compatibility!

Friendly neighborhood Spiderma...coder

Posted

package mods.com.Filkie.LavaVsWater;

 

import mods.com.Filkie.LavaVsWater.Blocks.BlockWaterOre;

import mods.com.Filkie.LavaVsWater.Blocks.BlockEmberStone;

import mods.com.Filkie.LavaVsWater.Blocks.BlockFlamingBlock;

import mods.com.Filkie.LavaVsWater.Blocks.BlockHailStone;

import mods.com.Filkie.LavaVsWater.Blocks.BlockLavaOre;

import mods.com.Filkie.LavaVsWater.Blocks.BlockWaterBlock;

import mods.com.Filkie.LavaVsWater.Items.ItemElementalGem;

import mods.com.Filkie.LavaVsWater.Items.ItemElementalShard;

import mods.com.Filkie.LavaVsWater.Items.ItemEscenseOfFire;

import mods.com.Filkie.LavaVsWater.Items.ItemEscenseOfWater;

import mods.com.Filkie.LavaVsWater.Items.ItemLavaShard;

import mods.com.Filkie.LavaVsWater.Items.ItemWaterShard;

import mods.com.Filkie.LavaVsWater.Mobs.EntityLavaCreeper;

import mods.com.Filkie.LavaVsWater.Mobs.EntityWaterCreeper;

import net.minecraft.block.Block;

import net.minecraft.block.material.Material;

import net.minecraft.creativetab.CreativeTabs;

import net.minecraft.entity.Entity;

import net.minecraft.entity.EntityEggInfo;

import net.minecraft.entity.EntityList;

import net.minecraft.entity.EnumCreatureType;

import net.minecraft.item.Item;

import net.minecraft.world.biome.BiomeGenBase;

import net.minecraftforge.common.DimensionManager;

import cpw.mods.fml.common.Mod;

import cpw.mods.fml.common.Mod.Init;

import cpw.mods.fml.common.SidedProxy;

import cpw.mods.fml.common.event.FMLInitializationEvent;

import cpw.mods.fml.common.network.NetworkMod;

import cpw.mods.fml.common.registry.EntityRegistry;

import cpw.mods.fml.common.registry.GameRegistry;

import cpw.mods.fml.common.registry.LanguageRegistry;

 

 

@Mod(modid = "LavaVsWater_Mod", name = "Lava Vs Water Mod", version = "1.0")

@NetworkMod(clientSideRequired = true, serverSideRequired = false)

public class LavaVsWater_Mod

{

 

 

@SidedProxy(clientSide = "mods.com.Filkie.LavaVsWater.ClientProxy", serverSide = "mods.com.Filkie.LavaVsWater.CommonProxy")

    public static CommonProxy proxy;

 

//Items

public static Item LavaShard;

public static Item WaterShard;

public static Item EscenseOfFire;

public static Item EscenseOfWater;

public static Item ElementalGem;

public static Item Elementalshard;

 

//Blocks

public static Block FlamingBlock;

public static Block WaterBlock;

public static Block EmberStone;

public static Block HailStone;

public static Block ElementalPortal;

 

 

//Creative Tabs

 

public static CreativeTabs tabLava = new TabLava(CreativeTabs.getNextID(),"Lava"); //Our custom creative tab's object

public static CreativeTabs tabWater = new TabWater(CreativeTabs.getNextID(),"Water"); //Our custom creative tab's object

public static CreativeTabs tabElemental = new TabElemental(CreativeTabs.getNextID(),"Elemental"); //Our custom creative tab's object

 

//Tools

 

//Registry

//public static int ElementalRealmDimension = 20;

//Mobs

static int startEntityId = 300;

 

 

//Biomes

//public static BiomeGenBase ElementalBiome;

 

@Init

public void load(FMLInitializationEvent event)

{

proxy.registerRenderThings();

 

 

 

//Ores

 

 

 

//Items

LavaShard = new ItemLavaShard(5500, "Lava Shard").setUnlocalizedName("Lava Shard");

 

  LanguageRegistry.addName(LavaShard, "Lava Shard");

 

  WaterShard = new ItemWaterShard(5501, "Water Shard").setUnlocalizedName("Water Shard");

 

  LanguageRegistry.addName(WaterShard, "Water Shard");

 

  EscenseOfFire = new ItemEscenseOfFire(5502, "Escense of Fire").setUnlocalizedName("Escense of Fire");

 

  LanguageRegistry.addName(EscenseOfFire, "Escense of Fire");

 

  EscenseOfWater = new ItemEscenseOfWater(5503, "Escense of Water").setUnlocalizedName("Escense of Water");

 

  LanguageRegistry.addName(EscenseOfWater, "Escense of Water");

 

  ElementalGem = new ItemElementalGem(5504, "Elemental Gem").setUnlocalizedName("Elemental Gem");

 

  LanguageRegistry.addName(ElementalGem, "Elemental Gem");

 

  Elementalshard = new ItemElementalShard(5505, "Elemental Shard").setUnlocalizedName("Elemental Shard");

 

  LanguageRegistry.addName(Elementalshard, "Elemental Shard");

 

//Blocks

  FlamingBlock = new BlockFlamingBlock(1000, "Flaming Block").setUnlocalizedName("Flaming Block").setHardness(3.0F).setResistance(10.0F);

 

  GameRegistry.registerBlock(FlamingBlock);

 

  LanguageRegistry.addName(FlamingBlock, "Flaming Block");

 

  WaterBlock = new BlockWaterBlock(1001, "Water Block").setUnlocalizedName("Water Block").setHardness(3.0F).setResistance(10.0F);

 

  GameRegistry.registerBlock(WaterBlock);

 

  LanguageRegistry.addName(WaterBlock, "Water Block");

 

  EmberStone = new BlockEmberStone(1002, "Ember Stone").setUnlocalizedName("Ember Stone").setHardness(3.0F).setResistance(10.0F);

 

  GameRegistry.registerBlock(EmberStone);

 

  LanguageRegistry.addName(EmberStone, "Ember Stone");

 

  HailStone = new BlockHailStone(1003, "Hail Stone").setUnlocalizedName("Hail Stone").setHardness(3.0F).setResistance(10.0F);

 

  GameRegistry.registerBlock(HailStone);

 

  LanguageRegistry.addName(HailStone, "Hail Stone");

 

  //ElementalPortal = new Filkie.LavaVsWater.BlockElementalPortal(254, 4).setBlockName("Elemental Realm Portal");

 

  //GameRegistry.registerBlock(ElementalPortal, "Elemental Realm Portal");

 

  //LanguageRegistry.addName(ElementalPortal, "Elemental Realm Portal");

 

 

       

 

//Registry

  //DimensionManager.registerProviderType(ElementalRealmDimension, WorldProviderLavaVsWater.class, false);

 

  //DimensionManager.registerDimension(ElementalRealmDimension, ElementalRealmDimension);

 

 

//Mobs

  EntityRegistry.registerModEntity(EntityLavaCreeper.class, "LavaCreeper", 1, this, 80, 3, true);

  EntityRegistry.addSpawn(EntityLavaCreeper.class, 10, 2, 4, EnumCreatureType.monster, BiomeGenBase.beach, BiomeGenBase.extremeHills, BiomeGenBase.extremeHillsEdge, BiomeGenBase.forest, BiomeGenBase.forestHills, BiomeGenBase.jungle, BiomeGenBase.jungleHills, BiomeGenBase.mushroomIsland, BiomeGenBase.mushroomIslandShore, BiomeGenBase.ocean, BiomeGenBase.plains, BiomeGenBase.river, BiomeGenBase.swampland);

  LanguageRegistry.instance().addStringLocalization("entity.LavaCreeper.name", "LavaCreeper");

 

  //registerEntityEgg(EntityLavaCreeper.class, 0xffffff, 0x000000);

 

  EntityRegistry.registerModEntity(EntityWaterCreeper.class, "WaterCreeper", 1, this, 80, 3, true);

  EntityRegistry.addSpawn(EntityWaterCreeper.class, 10, 2, 4, EnumCreatureType.monster, BiomeGenBase.beach, BiomeGenBase.extremeHills, BiomeGenBase.extremeHillsEdge, BiomeGenBase.forest, BiomeGenBase.forestHills, BiomeGenBase.jungle, BiomeGenBase.jungleHills, BiomeGenBase.mushroomIsland, BiomeGenBase.mushroomIslandShore, BiomeGenBase.ocean, BiomeGenBase.plains, BiomeGenBase.river, BiomeGenBase.swampland);

  LanguageRegistry.instance().addStringLocalization("entity.WaterCreeper.name", "WaterCreeper");

 

// registerEntityEgg(EntityLavaCreeper.class, 0xffffff, 0x000000);

 

//Biomes

       

  //ElementalBiome = new BiomeGenElementalBiome(53).setColor(2900485).setBiomeName("Elemental Biome").setTemperatureRainfall(1F, 0.5F).setMinMaxHeight(0.2F, 1F);

       

  //GameRegistry.addBiome(ElementalBiome);

 

 

}

 

 

 

 

 

}

 

 

 

 

Friendly neighborhood Spiderma...coder

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.