
Jantomedes
Members-
Posts
32 -
Joined
-
Last visited
Everything posted by Jantomedes
-
Oh, you didn't describe your problem enough to help you but I will try. The point is, you have to make this value static. Than it will the same for all instances of your block. The other thing is that you should use saving it to NBT tag by overriding method writeToNBT(NBTTagCompund nbt) and readFromNBT(NBTTagCompund nbt). These methods are in TileEntity class. And about the mod you are writing about. Applying is pretty simple - you have to create an account first, than just validate your email by clicking a link in mail you gonna receive, than get back to the applying page. First you have to choose a category you'd want to apply. Than write a little description, for example if you want to be a coder, write about a mod you are proud of and you have made. Also attach some screenshots or videos and the mod's files and code from done tasks for your category to let them now you are good. Click the big green button 'submit application' and wait for an anwer. Before you'll make that, I suggest you to look at left and read what they want from a 3D artist, coder etc. I hope I helped you. If yes, don't forget to give me a 'thank' ;-) Regards. Jantomedes
-
Oh, you didn't describe your problem enough to help you but I will try. The point is, you have to make this value static. Than it will the same for all instances of your block. The other thing is that you should use saving it to NBT tag by overriding method writeToNBT(NBTTagCompund nbt) and readFromNBT(NBTTagCompund nbt). These methods are in TileEntity class. And about the mod you are writing about. Applying is pretty simple - you have to create an account first, than just validate your email by clicking a link in mail you gonna receive, than get back to the applying page. First you have to choose a category you'd want to apply. Than write a little description, for example if you want to be a coder, write about a mod you are proud of and you have made. Also attach some screenshots or videos and the mod's files and code from done tasks for your category to let them now you are good. Click the big green button 'submit application' and wait for an anwer. Before you'll make that, I suggest you to look at left and read what they want from a 3D artist, coder etc. I hope I helped you. If yes, don't forget to give me a 'thank' ;-) Regards. Jantomedes
-
I knew what a reference type is but didn't know that all not primitive types are reference types automatically. And your answer helped me - I've read on the wiki about that. I have to say it wasn't true that you didn't helped me. You didn't have to write the first part so precisely because I know how to create a new TE of good type. But thanks for the last lines with neat way of saving TE to NBT. Without that and without mnm saying it could be done like this, I would have made it with manually saving important values from TEs. Oh, or I even wouldn't because they are private. And grab some karma for this NBT ;-) It's the same thing - he wrote that it magically uses some link. If he don't know what a "reference type" (or "static" or "value type" or "method" or "field") means, he should stop trying to mod and go back to learning Java. If he don't uderstand it and just copy-paste your code, he'll be back tomorrow with similar "learn java" issue. Also it will be frustrating for him, becuase in the end he ends up with code which is impossible to maintain - copied pieces together without any knowledge why it works. I did write that on the end of my post... I wonder how machines from BC, IC2 or computers from RP or CC wound react on this copying. *thinking about multiblock structures* I don't think that a lot (if any) modders were considering this when writing their TE. Mnn, you're making a little mistake. I have to say I didn't know how reference types are working but I know the basic Java. Of course I know what static/value type/method/field means. I am not somebody who thinks that learning Java by modding is a good way to do that. It isn't a way at all. So why if I know Java I have such simple problem? Well, I know the basic Java. And basic means much more than just 'static' or 'field'. The point is that I have sometimes some gaps in my knowledge. The main reason is probably that I didn't understand something and forgot to get back to it. Maybe sounds dumb but that's it. I don't learn Java by modding. At most just realize what I've missed or what I have to remind. Anyway, this was a Java question so sorry for 'offtopicing'. And thanks fro your answers. I will worry later about multiblock structures. And these emotions were because of comparing me to noobs which think that they can learn Java by modding. Regards. Jantomedes @Down: Argh... So embarrassing... PS. assert this.nativeLanguage != Languages.ENGLISH; ;-)
-
I knew what a reference type is but didn't know that all not primitive types are reference types automatically. And your answer helped me - I've read on the wiki about that. I have to say it wasn't true that you didn't helped me. You didn't have to write the first part so precisely because I know how to create a new TE of good type. But thanks for the last lines with neat way of saving TE to NBT. Without that and without mnm saying it could be done like this, I would have made it with manually saving important values from TEs. Oh, or I even wouldn't because they are private. And grab some karma for this NBT ;-) It's the same thing - he wrote that it magically uses some link. If he don't know what a "reference type" (or "static" or "value type" or "method" or "field") means, he should stop trying to mod and go back to learning Java. If he don't uderstand it and just copy-paste your code, he'll be back tomorrow with similar "learn java" issue. Also it will be frustrating for him, becuase in the end he ends up with code which is impossible to maintain - copied pieces together without any knowledge why it works. I did write that on the end of my post... I wonder how machines from BC, IC2 or computers from RP or CC wound react on this copying. *thinking about multiblock structures* I don't think that a lot (if any) modders were considering this when writing their TE. Mnn, you're making a little mistake. I have to say I didn't know how reference types are working but I know the basic Java. Of course I know what static/value type/method/field means. I am not somebody who thinks that learning Java by modding is a good way to do that. It isn't a way at all. So why if I know Java I have such simple problem? Well, I know the basic Java. And basic means much more than just 'static' or 'field'. The point is that I have sometimes some gaps in my knowledge. The main reason is probably that I didn't understand something and forgot to get back to it. Maybe sounds dumb but that's it. I don't learn Java by modding. At most just realize what I've missed or what I have to remind. Anyway, this was a Java question so sorry for 'offtopicing'. And thanks fro your answers. I will worry later about multiblock structures. And these emotions were because of comparing me to noobs which think that they can learn Java by modding. Regards. Jantomedes @Down: Argh... So embarrassing... PS. assert this.nativeLanguage != Languages.ENGLISH; ;-)
-
Oh, you didn't read my post carefully. YES, this exactly a "learn java" thread. Many of you already have a reflex 'if it's a Java question, we have to hate it immediately'. But I believe there are some kind people who don't have it and know the difference between a question from a noob who doesn't learn Java at all or he does it 'by modding' and a question from a person who know the basics of Java but sometimes also has some problems. Thanks for saying me exactly what I wrote in my post. Very helpful and clever. That's very practical if I can ask a question on a forum and get the precise name of my problem. I also believe that there are some of these kind people who can give me a little explanation and write an example. Thanks. --------------------- If I've gone too far, sorry - emotions.
-
But I do :-) Look into GUI of "DoYouWantToDownloadTheTexturepackThisServerUsesAndWhichSucks?". I'm afraid it was called a little bit differently ;-)
-
Well, I know you can place them in /bin or bin/natives but maybe there is a extra external super hyper secret magic additional way to do that.
-
When you are in Eclipse, right click your mod project and select Properties->Java build path->Libraries->Add external JARs
-
Hi there. First, I wanted to make a simple tool for copying and replacing blocks, so I can easily copy a chest or something else and place copy it somewhere else. This seems so easy but I have some terrible problems. It looks Java bites me when I want to make a copy of something but it's a link not a copy. When I am copying a block everything is ok but when I set another block, the TileEntity of the original block disappears and the new block also don't have a TileEntity. When I set a block to another it even doesn't set the metadata... -.- Wrench of copying: Wrench of setting: ChainSettings: Regards. Jantomedes
-
Hey there! I made a block which should be rendered depending on a value in his TileEntity. The problem is that it depends on default value from TileEntity's constructor. I checked and the value is properly saved and loaded. Code from the block: @SideOnly(Side.CLIENT) public Icon getBlockTexture(IBlockAccess par1IBlockAccess, int par2, int par3, int par4, int par5){ return Block.blocksList[((TileEntityChainReactiveRock)par1IBlockAccess.getBlockTileEntity(par2, par3, par4)).textureID].getBlockTexture(par1IBlockAccess, par2, par3, par4, par5); } And from TileEntity: I don't paste the whole code of block because there is so much of it and there is nothing about block's texture except what I pasted. I think it could be something with IBlockAccess. Regards. Jantomedes
-
Now I know :-) Any block with TileEntity has to implement ITileEntityProvider. I didn't see that because major of blocks with TileEntitys (all of them?) are extending BlockContainer which is implementing that. Anyway thanks for your help.
-
I'm sorry but it didn't help me at all. Anyway thank for your trying to help ;-) Better let's get an example: We have ItemArmor(EnumArmorMaterial) and we want to define an object with it but no of existing values in EnumArmorMaterial is good for us. We also don't want to change ItemArmor or EnumArmorMaterial class nor create new class which is just a bit changed ItemArmor. How we can do that? Possible ideas: (i didn't check them, they're just examples what I'm searching for) ItemArmor(new EnumArmorMaterial(data)); ItemArmor((EnumArmorMaterial)Enum.setOf(data));
-
I have always been a bit confused with Enums. So my question is if we have e.g. constructor with an EnumMagic for an argument and we want to use other data than the existing in EnumMagic, so do we HAVE to edit EnumMagic or is there way to to something like "new EnumMagic(data)". Regards. Jantomedes This is just a theoretical Java question. It's not about the armor. Really.
-
I added the snippet and it's working. I also overrided the method (registration I already had but blocks still don't update after loading a world. I have to place them again to start them counting. Do you have any ideas? Anyway, thanks a lot ;-)
-
Hey there. I have an issue that tileentity of a block is not updating after loading a saved game but when I place a new block it is updating even after destroying the block. The code for block and tileentity: http://pastebin.com/CuCbTafE
-
Well, I didn't get catch you get the error after placing in Minecraft. Mods which are using ModLoader have the main classes starting with mod_ just like yours. Java convention wants it to start with capital. But as you can see on the error log, game trye to find getNextId() method in ItemBucket not in CreativeTabs. That's because the code is "wrong" deobfuscated. You probably have created a mod on 1.5.0 and run the files on 1.5.1 or vice versa. It can be also made by using unstable build of Forge. Try use updateMCP.bat and updateNames.bat or how it was called.
-
How do I create a custom bucket with the normal bucket?
Jantomedes replied to lorizz's topic in Modder Support
https://github.com/BuildCraft/BuildCraft And now take a lesson of the magic skill of searching ;-) -
Okey I'll try (and give you a + if it worsk ;-)) But just out of crazy curiosity: what I have to do to just use the updateTick() method?
-
2013-04-02 17:00:34 [iNFO] [sTDERR] Exception in thread "Minecraft main thread" java.lang.NoSuchMethodError: net.minecraft.item.ItemBucket.getNextID()I 2013-04-02 17:00:34 [iNFO] [sTDERR] at tutorialtest.mod_tutorial.<clinit>(mod_tutorial.java:29) I bet It's not about creative tab ;-) And why you your class like it uses ModLoader?
-
Hi there! It's probably a bit silly question but I was making a block and wanted it to something on each tick so I added the updateTick() method and Eclipse tells it's overrided but the method isn't called at all. The javadoc description says that updateTick() has to be scheduled but how can I do that? I tried the TickRegistry.registerTickHandler() but it has to get a class implementing ITickHandler and it's looks just a bit too hard to be the solution I'm looking for. The normal blocks like dirt are using updateTick() but I don't see any advanced ITickHandlers? So where it is or maybe I must implement ITickHandler? You can give me a tutorial. Regards. Jantomedes
-
Have you set the PATH variable correctly?
-
So try deinstalling Java SE. JDK own a runtime environment so you won't have any issues with running programs.
-
Are you using recommended build or just the newest? Try downloading recommended if not.
-
Hey there! Have you ever been doing an advanced escape or adventure map? Weren't you tired with the need of using external tools to set all the NBT tags right or with finding a proper tutorial? Well, this is going to end because now you will be able to use all the special features and even new ones! Idea: What is hard, my mod will make easy. What is impossible, my mod will make possible. Ladies and gentlemen, I introduce you the new MapTools mod! Major enabled features: In-game NBT tags text editor with made presets, help pages, copy-paste functions etc. In-game NBT tags GUI editor to make NBT editing even easier - this will be using the grab and drop functions and will show you all important fields and description of every tag Built-in help for all the mod functions and all the game map functions with examples and tutorials A very simple environment to run/write/edit built-in, community's and your own craftscripts (something like MCedit filters) Maybe even possibility to run MCedit filters A very easy way to generate vanilla structures Maybe some built-in tools to edit terrain like WorldEdit or VoxelSniper Much more! Major brand new features: Lot of more NBT tags (e.g. for TNT to make more predictable explosions, to make blocks or items to be coloured a bit), to make glass able to be destroyed by arrow, to make mobs explode with bacon(lol?), to change the size of mobs, block drops etc. Blocks for scripting block changes! Something like command blocks but you will be able to set somewhere a wall (or castle ), somewhere destroy a house, somewhere activate a piston or even animate blocks! Player NPCs with even scripted events, different models, talking system and much more Special block functions like break a whole chunk of glass by destroying just one block, or making a chain-reaction (e.g. collapsing rock ceiling in a mineshaft) And of course much more! So do you like the idea? Questions you will be probably asking: Will the player be forced to download the mod to play my map? It all depends on you! If you won't use any extra tools (<<brand new features>> like scripted player NPCs) the player won't have to. You can even make a map which player can play without mod but if he have the mod, he will be able to play more threads/places. The game will visibly say you that since now, the map needs mod to work. There will be probably a function to even not display extra functions. When will be the mod out? Can I support you somehow? The mod is in early stage of development. There isn't any beta version available and screenshots (for now). If you want to support me, you can write what you think about my mod down below or if you are an artist, you can make me a logo (I don't have one... :C) or a signature (something with command block and the idea? ;-)). I will need artist later to make the game graphics. If you feel really generously and you would like to donate me, contact me on PM. If you are a modder and want to code, I apologise, but for now I don't take people to team (but stay tuned ;-)). Will there be a version for each new snapshot? I'm afraid no but you know... Everything can happen ;-) I have a genius idea! So write it below! ;-) What is the estimated date of releasing complete/beta mod? There isn't a release date. I just started to work. You can speed me up by supporting by flattering me or (look 2 questions earlier). And these you are probably to lazy to ask: So that's all. Hope you enjoy it! Regards. Jantomedes
-
[1.5.1] Block/Item Texture/Icon location?
Jantomedes replied to Kalbintion's topic in Modder Support
@Up Try using registerIcons() instead of updateIcons()