Jump to content

Fochis

Members
  • Posts

    11
  • Joined

  • Last visited

Converted

  • Gender
    Male
  • Location
    Spain
  • Personal Text
    I am new!

Fochis's Achievements

Tree Puncher

Tree Puncher (2/8)

2

Reputation

  1. Hi Warjort. You were right. The problem was a problem with the graphics card. After uninstalling the drivers and reinstalling them, the modpack worked again. Thank you very much for your time
  2. Hello everyone. When starting Minecraft today from CurseForge app, the game stops with an error message Error Code 1. I was playing yesterday with no problems and have not made any changes or any updates to the mods. As tests, I made a new modpack from CurseForge app with Minecraft version 1.19.2, Forge 43.1.47 and without including any mods getting the same error. I also tried booting the previous empty modpack from version 43.1.0 and I get the same error, which has completely stunned me. When trying to start a modpack with another version of Minecraf and Forge, (1.18.2 mc and forge 40.1.80) I had no problem and with vanilla Minecraft either. The error only gives me a log file called hs_err_pid18948.log but there is none in the "crash-reports" folder and none in the "logs" folder either. The log I show is from the empty modpack I created. It seems to be a bug that jumps with version 1.19.2. Can anyone give me an idea of what is happening? Greetings to all the community
  3. @SideOnly(Side.CLIENT) /** * Performs a ray trace for the distance specified and using the partial tick time. Args: distance, partialTickTime */ public MovingObjectPosition rayTrace(double par1, float par3) { Vec3 var4 = this.getPosition(par3); Vec3 var5 = this.getLook(par3); Vec3 var6 = var4.addVector(var5.xCoord * par1, var5.yCoord * par1, var5.zCoord * par1); return this.worldObj.rayTraceBlocks(var4, var6); } The second argument is partialTickTime. I do not know how to get those values. I will do some tests with this method. Regards
  4. The code is only a example to view the result. I'm only learning about mods development with Forge. My intention is that when using an object on a block, that block is a reference to create a structure. Then I need the values ​​x, y and z of the block to which I am pointing the cursor and objectMouseOver gives me these values​​. My question is if I'm using the correct method. Thanks for your answer
  5. Thanks for your help Atrain99, but this method look for 2 args, distance and partialTickTime and I don't have the distance. I can calculate the distance to a Entity but not to a Block. I'll keep looking for any clues Thanks a lot. (Sorry. I not speak English and is very difficult for me to explain properly. I'm from Spain) EDIT: I found in Minecraft class a object called "objectMouseOver". This object have 3 variables called blockX, blockY and blockZ. This object stores the coordinates of the block where the mouse are. To acces to this object, I create a Minecraft instance in my item class, like this: public class ItemCreator extends Item { @Instance private Minecraft instance; protected ItemCreator(int id) { super(id); } public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer player) { if(Minecraft.getMinecraft().objectMouseOver!=null) { int xm=Minecraft.getMinecraft().objectMouseOver.blockX; int ym=Minecraft.getMinecraft().objectMouseOver.blockY; int zm=Minecraft.getMinecraft().objectMouseOver.blockZ; player.addChatMessage("X: "+xm+" Y:"+ym+"Z: "+zm); } return par1ItemStack; } It's the good way to do it or I,m create a monster?
  6. From the method onItemRightClick I want to change the block I'm pointing the cursor. From where I can get the coordinates of that block? I've tried from EntityPlayer, but all I found was the method getLookvec(), but gives me values ​​that I do not understand Thank you very much in advance
  7. My mistake :-[ The problem was the "randomDisplayTick" method. I've changed by "onNeighborBlockChange" and works properly
  8. Here is my code. [hide] This is my main mod file http://s2.subirimagenes.com/otros/previo/thump_7961967pant.jpg[/img] and this is one of my block file http://s2.subirimagenes.com/otros/previo/thump_7961989pant2.jpg[/img] [/hide] I Hope it helps you
  9. I've been reading SMP Coding Guidelines and I found what's the problem: I imagine that the change in the block have to do on the server side, but I do not know how to do this. My mod is a very simple mod that works only in single player but with the changes in the 1.3.2 version, single and multiplayer modes seems to be the same. My block work's as the grass block, but I don't find the way to do it.
  10. If your mod pakage is in Minecraft.common, you can create a folder called gfx into common package and drop here your terrain.png and your item.png (or other names) Example: you have a block YBlock To call your graphics from your mod, use : MinecraftForgeClient.preloadTexture("/gfx/terrain.png"); to load the textures and in the block file: @SideOnly(Side.CLIENT) public String getTextureFile() { return "/gfx/terrain.png"; } It's only a example. You can change the names or the path of your graphics folder if you update the load and call methods Sorry. I don't speak english.
  11. Hi. I don't speak english and it's very hard for me explain my problem properly, sorry. I have a problem with this code: public void randomDisplayTick(World par1World, int par2, int par3, int par4, Random par5Random) { if(!(par1World.isRemote)) { if(hayLava(par1World,par2,par3,par4)) //Determine if lava touch my block { par1World.setBlockWithNotify(par2, par3, par4, Nemod.reforzado2.blockID); } } } In game, the block never change to "Nemod.reforzado2.blockId". If I remove the "if(!par1World.isRemote)" line, the block appears to change, but not properly. If I look the block in McEdit, the block has the old ID, but in game showme the new block There seems to be two worlds in the same game, the server world and the client world, but why i can change any block in the "server world"? I tried multiple ways to do it, but I not found any solution. Can you help me? Tell me if you need more information or screenshots. Thank's in advance and sorry for my bad english.
×
×
  • Create New...

Important Information

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