1

[ERRORS] Modloader and my Block!!!!!!!!!

Peanutmasta! 11/9/12 6:55 pm
170
11/9/2012 8:06 pm
This is my first mod, and here is the lines with errors

public static final Block orephosphorous = new orePhosphorous (146,ModLoader.addOverride("/terrain.png", "/textures/phos_ore.png")).setHardness(3.0F).setResistance(5.0F).setLightValue(0.1F).setBlockName("Phosphorous Ore");

public mod_phosphorous()
{
Modloader.registerBlock(orephosphorous);
Modloader.addName(orephosphorous,"Phosphorous Ore");


Error 1: orePhosphorous cannot be resolved as a type.
Error 2/3: Modloader cannot be resolved

please help. My other class file is mod_orephosphorous.java it has no errors

PS: by the way, the Ore")" is actually on the end of the line above it.
Posted by
Peanutmasta!
Level 15 : Journeyman Artist
3

  Have something to say?

JoinSign in

4

hunturbo
11/09/2012 7:51 pm
Level 41 : Master Ninja
Do you have another method called public string version under the public load method?
1
Peanutmasta!
11/09/2012 8:06 pm
Level 15 : Journeyman Artist
package net.minecraft.src;

import java.util.Random;

public class mod_phosphorous extends BaseMod
{

public static final Block orephosphorous = new BlockorePhosphorous(146, ModLoader.addOverride("/terrain.png", "/textures/phos_ore.png")).setHardness(3.0F).setResistance(5.0F).setLightValue(0.1F).setBlockName("Phosphorous Ore");

public mod_phosphorous()
{
ModLoader.registerBlock(orephosphorous);
ModLoader.addName(orephosphorous,"Phosphorous Ore");
}
public void generateSurface(World world, Random random, int i, int j)
{
for(int i4 = 0; i4 < 20; i4++)
{
int j7 = i + random.nextInt(16);
int k10 = random.nextInt(128);
int j13 = j + random.nextInt(16);
(new WorldGenMinable(mod_phosphorous.orephosphorous.blockID, 10)).generate(world, random, j7, k10, j13);
}

}

@Override
public String getVersion() {
return null;
}
@Override
public void load() {
}
}

that's everything in that file
1
Peanutmasta!
11/09/2012 7:22 pm
Level 15 : Journeyman Artist
2/3 errors are fixed I now am only having probs with the 1st
1
sparky704
11/09/2012 7:05 pm
Level 4 : Apprentice Crafter
just goto youtube and look up scmowns he has a show that shows u how to do that
1

Welcome