Everything posted by Draco18s
-
Changing vanilla classes without editing them
ASM or Reflections.
-
[1.6.4] World Gen Error Help please
Did you finally name your variable something other than the same name as your class? And start referencing that variable properly?
-
NoSuchFieldError: GUI Programming - A tricky one!
Q: Are you getting the error client side or server side?
-
[Solved] Help with using variable on a method
Save the block ID. Block.blocksList[nbt.getInteger("thatThingIWantToUse")].getBlockTextureFromSide(0)
-
[Solved] Help with using variable on a method
Eval() is evil. Do not use.
-
[Solved] Help with using variable on a method
Maybe. We don't have enough information to help you, as from the code supplied and the description given, we do not know where you've stored the NBT tag or if that object is available at that point.
-
WorldGen requirements
Do consider mods like Mystcraft which can created extra dimensions using any biome (including Sky and Hell). If you're doing something like Nether Ore generation, your ores should generate in these dimensions. Especially as some users wish to create "Nether Analogs" for their Ages.
-
Map Height and depth change
Yeeaahh....start with something simpler.
-
Map Height and depth change
Yes. Write your own chunk provider.
-
Random furnace output
You want the results to be different (and random) and stack? These two statements do not go together.
-
Server side integer saving?
Send a PM to Veovis. He's the one who figured it out and has a working codebase.
-
WorldGen requirements
Sorry, it should be world.getBlockId(x,y,z) But if you can't use your javadoc and Eclipse codehinting properly I'm not going to help you.
-
Server side integer saving?
- WorldGen requirements
HOLY CRAP YOU CAN USE VARIABLES TO SAVE THE RESULTS OF A CALL TO RANDOM. Yes, I'm mocking you:- WorldGen requirements
world.getBlock(x, y, z) ?- Forge Event for blocking mob spawners from spawning
This makes no sense. One does not place back a tile entity that shouldn't be there after you remove its parent block.- Server side integer saving?
Because the rest of the time it's just a variable in memory!- Forge Event for blocking mob spawners from spawning
Use your block to scan the area around itself and then use magic to change the spawner properties. Like setting the current time (NBTTagCompound.getShort("Delay")) to a number greater than 1.- Change Block gravity?
ASM or Reflections. Or base class editing.- [solved]Add text to inventory item tooltip?
Just to show how unfamiliar I am: I was pretty sure they referred to the same thing. @..@ Oh sweet, how about that.- [solved]Add text to inventory item tooltip?
Taking a look at Thaumcraft's source (JD GUI is awesome) I can't figure out how everything works, but it looks like he has a general look-up function that takes an item ID and checks it against various recipes (arcane, crucible, etc.) and generates a list of essence types (stored as a list of Enum values). For something more like adding "burnable" to it, ASM might be your best bet. Note: the Reflections API is not for the faint of heart.- Change Block gravity?
Gravity is not a globally referenced variable. Every entity handles its own downward movement and acceleration. (Blocks do not obey gravity, in any way, what so ever. "But sand and gravel!" you say. "Entities. EntityFallingSand. Not a block" I reply.)- [solved]Add text to inventory item tooltip?
@Override public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List) { par3List.add("Whatever string you want to display here"); } Which you probably could have figured out by looking at the classes of any item that displays tooltip information. Like ItemRecord.- IExtenedPlayerProps And Packet Handler
ByteArrayOutputStream bt = new ByteArrayOutputStream(); DataOutputStream out = new DataOutputStream(bt); out.writeBoolean(true); Packet250CustomPayload packet = new Packet250CustomPayload("MyChannel", bt.toByteArray()); PacketDispatcher.sendPacketToServer(packet);- Change the property of a configuration file
I would just like to report that mnn's solution works. He got the config syntax wrong, but there is a set method that works for most data types. I wanted to read in an integer array, then sort it, in order to take advantage of reading this array later in a fast method. So I figured I might as well sort the array and save it back to the config. Here's the solution: int[] white = config.get("WorldGen","dimensionWhitelistList", new int[] {0}).getIntList(); //read the values, supplying defaults int[] black = config.get("WorldGen","dimensionBlacklistList", new int[] {-1,1}).getIntList(); Arrays.sort(white); //sort Arrays.sort(black); String a=Arrays.toString(white); String whitestring[]=a.substring(1,a.length()-1).split(", "); //have to convert to a string array in order to write String b=Arrays.toString(black); String blackstring[]=b.substring(1,b.length()-1).split(", "); config.get("WorldGen","dimensionWhitelistList", new int[] {0}).set(whitestring); //default values here are irrelevant, but required in order to retrieve the config Property config.get("WorldGen","dimensionBlacklistList", new int[] {-1,1}).set(blackstring); - WorldGen requirements
IPS spam blocked by CleanTalk.
Important Information
By using this site, you agree to our Terms of Use.