Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

NullPointerException when accessing Multiplayer Menu


cublikefoot
 Share

Recommended Posts

Minecraft Version: 1.4.5

Forge Version: 6.4.0.394

 

It does not affect the functions of the multiplayer menu, but it is an error otherwise.

 

 

 

------------- MultiMC Crash Report -------------

Information:

Date: 11-21-2012 14:50:13

Operating System: Windows 7 (build 7601, Service Pack 1), 64-bit edition

MultiMC Version: 4.2.0 jenkins-MultiMC4Windows-41

Minecraft Version: 1.4.5

 

------------------ Mod Lists -------------------

Jar Mods:

[Dependency] Minecraft Forge 6.4.0.394.zip

Version:

Filename: [Dependency] Minecraft Forge 6.4.0.394.zip

 

 

 

----------------- Console Log ------------------

Instance started with command: "C:\Program Files\Java\jre7\bin\java.exe"  -Xms512m -Xmx2048m -jar MultiMCLauncher.jar  "<username>" "<session ID>" "MultiMC: CubCraft 0.1b" "1280x720"

 

Loading jars...

Loading URL: file:/C:/Users/<username>/Dropbox/CubCraft/CubCraft_Client/instances/CubCraft/minecraft/bin/minecraft.jar

Loading URL: file:/C:/Users/<username>/Dropbox/CubCraft/CubCraft_Client/instances/CubCraft/minecraft/bin/lwjgl.jar

Loading URL: file:/C:/Users/<username>/Dropbox/CubCraft/CubCraft_Client/instances/CubCraft/minecraft/bin/lwjgl_util.jar

Loading URL: file:/C:/Users/<username>/Dropbox/CubCraft/CubCraft_Client/instances/CubCraft/minecraft/bin/jinput.jar

Loading natives...

Fixed Minecraft Path: Field was private static java.io.File net.minecraft.client.Minecraft.an

MCDIR: C:\Users\<username>\AppData\Roaming\.minecraft

Launching with applet wrapper...

2012-11-21 14:50:00 [iNFO] [ForgeModLoader] Forge Mod Loader version 4.5.0.457 for Minecraft 1.4.5 loading

2012-11-21 14:50:02 [iNFO] [sTDOUT] 27 achievements

2012-11-21 14:50:02 [iNFO] [sTDOUT] 208 recipes

2012-11-21 14:50:02 [iNFO] [sTDOUT] Setting user: <username>, <session ID>

2012-11-21 14:50:03 [iNFO] [sTDOUT] LWJGL Version: 2.4.2

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Attempting early MinecraftForge initialization

2012-11-21 14:50:04 [iNFO] [sTDOUT] MinecraftForge v6.4.0.394 Initialized

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] MinecraftForge v6.4.0.394 Initialized

2012-11-21 14:50:04 [iNFO] [sTDOUT] Replaced 84 ore recipies

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Completed early MinecraftForge initialization

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Searching C:\Users\<username>\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\mods for mods

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Forge Mod Loader has identified 3 mods to load

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Configured a dormant chunk cache size of 0

2012-11-21 14:50:05 [iNFO] [sTDOUT] Starting up SoundSystem...

2012-11-21 14:50:05 [iNFO] [sTDOUT] Initializing LWJGL OpenAL

2012-11-21 14:50:05 [iNFO] [sTDOUT]    (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)

2012-11-21 14:50:05 [iNFO] [sTDOUT] OpenAL initialized.

2012-11-21 14:50:06 [iNFO] [ForgeModLoader] Forge Mod Loader has successfully loaded 3 mods

2012-11-21 14:50:08 [iNFO] [sTDERR] java.lang.NullPointerException

2012-11-21 14:50:08 [iNFO] [sTDERR] at ayp.a(SourceFile:25)

2012-11-21 14:50:08 [iNFO] [sTDERR] at ayp.<init>(SourceFile:18)

2012-11-21 14:50:08 [iNFO] [sTDERR] at ato.A_(SourceFile:82)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:97)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.a(Minecraft.java:665)

2012-11-21 14:50:08 [iNFO] [sTDERR] at bem.a(GuiMainMenu.java:223)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:71)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.d(SourceFile:125)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.m(SourceFile:110)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.l(Minecraft.java:1515)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.J(Minecraft.java:858)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.run(Minecraft.java:783)

2012-11-21 14:50:08 [iNFO] [sTDERR] at java.lang.Thread.run(Unknown Source)

2012-11-21 14:50:08 [iNFO] [sTDERR] java.lang.NullPointerException

2012-11-21 14:50:08 [iNFO] [sTDERR] at ayp.a(SourceFile:25)

2012-11-21 14:50:08 [iNFO] [sTDERR] at ato.A_(SourceFile:83)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:97)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.a(Minecraft.java:665)

2012-11-21 14:50:08 [iNFO] [sTDERR] at bem.a(GuiMainMenu.java:223)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:71)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.d(SourceFile:125)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.m(SourceFile:110)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.l(Minecraft.java:1515)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.J(Minecraft.java:858)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.run(Minecraft.java:783)

2012-11-21 14:50:08 [iNFO] [sTDERR] at java.lang.Thread.run(Unknown Source)

 

 

------------------- FML Log --------------------

2012-11-21 14:50:00 [iNFO] [ForgeModLoader] Forge Mod Loader version 4.5.0.457 for Minecraft 1.4.5 loading

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] All core mods are successfully located

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Discovering coremods

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Found library file argo-2.25.jar present and correct in lib dir

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Found library file guava-12.0.1.jar present and correct in lib dir

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Found library file asm-all-4.0.jar present and correct in lib dir

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Running coremod plugins

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Running coremod plugin FMLCorePlugin

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Coremod plugin FMLCorePlugin run successfully

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Running coremod plugin FMLForgePlugin

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Coremod plugin FMLForgePlugin run successfully

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Validating minecraft

2012-11-21 14:50:00 [FINEST] [ForgeModLoader] Minecraft validated, launching...

2012-11-21 14:50:02 [iNFO] [sTDOUT] 27 achievements

2012-11-21 14:50:02 [iNFO] [sTDOUT] 208 recipes

2012-11-21 14:50:02 [iNFO] [sTDOUT] Setting user: cublikefoot, 3afaa839720402bcd2aba854307c732234959acb

2012-11-21 14:50:03 [iNFO] [sTDOUT] LWJGL Version: 2.4.2

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Attempting early MinecraftForge initialization

2012-11-21 14:50:04 [iNFO] [sTDOUT] MinecraftForge v6.4.0.394 Initialized

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] MinecraftForge v6.4.0.394 Initialized

2012-11-21 14:50:04 [iNFO] [sTDOUT] Replaced 84 ore recipies

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Completed early MinecraftForge initialization

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Building injected Mod Containers [cpw.mods.fml.common.FMLDummyContainer, net.minecraftforge.common.ForgeDummyContainer]

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Attempting to load mods contained in the minecraft jar file and associated classes

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Found a minecraft related file at C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\bin\minecraft.jar, examining for mod candidates

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Skipping known library file C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\bin\lwjgl.jar

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Skipping known library file C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\bin\lwjgl_util.jar

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Skipping known library file C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\bin\jinput.jar

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Skipping known library file C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\lib\argo-2.25.jar

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Skipping known library file C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\lib\guava-12.0.1.jar

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Skipping known library file C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\lib\asm-all-4.0.jar

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Minecraft jar mods loaded successfully

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Searching C:\Users\cublikefoot\Dropbox\CubCraft\CubCraft_Client\instances\CubCraft\minecraft\mods for mods

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Examining file minecraft.jar for potential mods

2012-11-21 14:50:04 [FINE] [ForgeModLoader] The mod container minecraft.jar appears to be missing an mcmod.info file

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Forge Mod Loader has identified 3 mods to load

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Received a system property request ''

2012-11-21 14:50:04 [FINE] [ForgeModLoader] System property request managing the state of 0 mods

2012-11-21 14:50:04 [FINE] [ForgeModLoader] After merging, found state information for 0 mods

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Activating mod mcp

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Activating mod FML

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Activating mod Forge

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Verifying mod requirements are satisfied

2012-11-21 14:50:04 [FINE] [ForgeModLoader] All mod requirements are satisfied

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Sorting mods into an ordered list

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Mod sorting completed successfully

2012-11-21 14:50:04 [FINE] [ForgeModLoader] Mod sorting data:

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sending event FMLConstructionEvent to mod mcp

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sent event FMLConstructionEvent to mod mcp

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sending event FMLConstructionEvent to mod FML

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sent event FMLConstructionEvent to mod FML

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sending event FMLConstructionEvent to mod Forge

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sent event FMLConstructionEvent to mod Forge

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sending event FMLPreInitializationEvent to mod mcp

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sent event FMLPreInitializationEvent to mod mcp

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sending event FMLPreInitializationEvent to mod FML

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sent event FMLPreInitializationEvent to mod FML

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sending event FMLPreInitializationEvent to mod Forge

2012-11-21 14:50:04 [iNFO] [ForgeModLoader] Configured a dormant chunk cache size of 0

2012-11-21 14:50:04 [FINER] [ForgeModLoader] Sent event FMLPreInitializationEvent to mod Forge

2012-11-21 14:50:05 [iNFO] [sTDOUT] Starting up SoundSystem...

2012-11-21 14:50:05 [iNFO] [sTDOUT] Initializing LWJGL OpenAL

2012-11-21 14:50:05 [iNFO] [sTDOUT]    (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)

2012-11-21 14:50:05 [iNFO] [sTDOUT] OpenAL initialized.

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLInitializationEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLInitializationEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLInitializationEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLInitializationEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLInitializationEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLInitializationEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event IMCEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event IMCEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event IMCEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event IMCEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event IMCEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event IMCEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLPostInitializationEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLPostInitializationEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLPostInitializationEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLPostInitializationEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLPostInitializationEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLPostInitializationEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLLoadCompleteEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLLoadCompleteEvent to mod mcp

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLLoadCompleteEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLLoadCompleteEvent to mod FML

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sending event FMLLoadCompleteEvent to mod Forge

2012-11-21 14:50:06 [FINER] [ForgeModLoader] Sent event FMLLoadCompleteEvent to mod Forge

2012-11-21 14:50:06 [iNFO] [ForgeModLoader] Forge Mod Loader has successfully loaded 3 mods

2012-11-21 14:50:08 [iNFO] [sTDERR] java.lang.NullPointerException

2012-11-21 14:50:08 [iNFO] [sTDERR] at ayp.a(SourceFile:25)

2012-11-21 14:50:08 [iNFO] [sTDERR] at ayp.<init>(SourceFile:18)

2012-11-21 14:50:08 [iNFO] [sTDERR] at ato.A_(SourceFile:82)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:97)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.a(Minecraft.java:665)

2012-11-21 14:50:08 [iNFO] [sTDERR] at bem.a(GuiMainMenu.java:223)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:71)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.d(SourceFile:125)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.m(SourceFile:110)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.l(Minecraft.java:1515)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.J(Minecraft.java:858)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.run(Minecraft.java:783)

2012-11-21 14:50:08 [iNFO] [sTDERR] at java.lang.Thread.run(Unknown Source)

2012-11-21 14:50:08 [iNFO] [sTDERR] java.lang.NullPointerException

2012-11-21 14:50:08 [iNFO] [sTDERR] at ayp.a(SourceFile:25)

2012-11-21 14:50:08 [iNFO] [sTDERR] at ato.A_(SourceFile:83)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:97)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.a(Minecraft.java:665)

2012-11-21 14:50:08 [iNFO] [sTDERR] at bem.a(GuiMainMenu.java:223)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.a(SourceFile:71)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.d(SourceFile:125)

2012-11-21 14:50:08 [iNFO] [sTDERR] at aue.m(SourceFile:110)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.l(Minecraft.java:1515)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.J(Minecraft.java:858)

2012-11-21 14:50:08 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.run(Minecraft.java:783)

2012-11-21 14:50:08 [iNFO] [sTDERR] at java.lang.Thread.run(Unknown Source)

 

 

Link to comment
Share on other sites

It only write the file when you actually do something with the server list, like add a server, or reorginize it.

If it still doesn't save after that, then you have a larger issue with not being able to write to your MC folder.

This isn't a forge thing.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Patreon: http://www.patreon.com/lexmanos
Paypal: http://paypal.me/LexManos

BitCoin: 1Q8rWvUNMM2T1ZfDaFeeYQyVXtYoeT6tTn

Link to comment
Share on other sites

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
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.

 Share



  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • My entity class extends AbstractMinecart and code in it is almost equal to FurnaceMinecart class.    public class Minecart_new extends AbstractMinecart { private static final EntityDataAccessor<Boolean> DATA_ID_FUEL = SynchedEntityData.defineId(MinecartFurnace.class, EntityDataSerializers.BOOLEAN); private int fuel; public double xPush; public double zPush; private static final Ingredient INGREDIENT = Ingredient.of(Items.APPLE, Items.CHARCOAL); public Minecart_new(EntityType<? extends Minecart_new> p_38552_, Level p_38553_) { super(p_38552_, p_38553_); } public AbstractMinecart.Type getMinecartType() { return AbstractMinecart.Type.FURNACE; } @Override protected void defineSynchedData() { super.defineSynchedData(); this.entityData.define(DATA_ID_FUEL, false); } @Override public void tick() { super.tick(); if (!this.level.isClientSide()) { if (this.fuel > 0) { --this.fuel; } if (this.fuel <= 0) { xPush = 0.0D; zPush = 0.0D; } this.setHasFuel(this.fuel > 0); } if (this.hasFuel() && this.random.nextInt(4) == 0) { this.level.addParticle(ParticleTypes.LARGE_SMOKE, this.getX(), this.getY() + 0.8D, this.getZ(), 0.0D, 0.0D, 0.0D); } } @Override protected double getMaxSpeed() { return (this.isInWater() ? 3.0D : 4.0D) / 20.0D; } @Override public float getMaxCartSpeedOnRail() { return 0.2f; } @Override public void destroy(DamageSource p_38560_) { super.destroy(p_38560_); if (!p_38560_.isExplosion() && this.level.getGameRules().getBoolean(GameRules.RULE_DOENTITYDROPS)) { this.spawnAtLocation(Blocks.FURNACE); } } @Override protected void moveAlongTrack(BlockPos p_38569_, BlockState p_38570_) { super.moveAlongTrack(p_38569_, p_38570_); Vec3 vec3 = this.getDeltaMovement(); double d2 = vec3.horizontalDistanceSqr(); double d3 = this.xPush * this.xPush + this.zPush * this.zPush; if (d3 > 1.0E-4D && d2 > 0.001D) { double d4 = Math.sqrt(d2); double d5 = Math.sqrt(d3); this.xPush = vec3.x / d4 * d5; this.zPush = vec3.z / d4 * d5; } } @Override protected void applyNaturalSlowdown() { double d0 = this.xPush * this.xPush + this.zPush * this.zPush; if (d0 > 1.0E-7D) { d0 = Math.sqrt(d0); this.xPush /= d0; this.zPush /= d0; Vec3 vec3 = this.getDeltaMovement().multiply(0.8D, 0.0D, 0.8D).add(this.xPush, 0.0D, this.zPush); if (this.isInWater()) { vec3 = vec3.scale(0.1D); } this.setDeltaMovement(vec3); } else { this.setDeltaMovement(this.getDeltaMovement().multiply(0.98D, 0.0D, 0.98D)); } super.applyNaturalSlowdown(); } @Override public InteractionResult interact(Player p_38562_, InteractionHand p_38563_) { InteractionResult ret = super.interact(p_38562_, p_38563_); if (ret.consumesAction()) return ret; ItemStack itemstack = p_38562_.getItemInHand(p_38563_); if (INGREDIENT.test(itemstack) && this.fuel+ 3600 <= 32000) { if (!p_38562_.getAbilities().instabuild) { itemstack.shrink(1); } this.fuel += 3600; } if (this.fuel > 0) { this.xPush = -(this.getX() - p_38562_.getX()); this.zPush = -(this.getZ() - p_38562_.getZ()); } return InteractionResult.sidedSuccess(this.level.isClientSide); } @Override protected void addAdditionalSaveData(CompoundTag p_38567_) { super.addAdditionalSaveData(p_38567_); p_38567_.putDouble("PushX", this.xPush); p_38567_.putDouble("PushZ", this.zPush); p_38567_.putShort("Fuel", (short)this.fuel); } @Override protected void readAdditionalSaveData(CompoundTag p_38565_) { super.readAdditionalSaveData(p_38565_); this.xPush = p_38565_.getDouble("PushX"); this.zPush = p_38565_.getDouble("PushZ"); this.fuel = p_38565_.getShort("Fuel"); } protected boolean hasFuel() { return this.entityData.get(DATA_ID_FUEL); } protected void setHasFuel(boolean p_38577_) { this.entityData.set(DATA_ID_FUEL, p_38577_); } @Override public BlockState getDefaultDisplayBlockState() { return Blocks.FURNACE.defaultBlockState().setValue(FurnaceBlock.FACING, Direction.NORTH).setValue(FurnaceBlock.LIT, Boolean.valueOf(this.hasFuel())); } ///////// @Override public ItemStack getPickResult() { Item item = ItemInit.MINECARTNEW_ITEM.get(); return new ItemStack(item); } } Registration of entity. public class EntityInit { private EntityInit() {} public static final DeferredRegister<EntityType<?>> ENTITIES = DeferredRegister.create(ForgeRegistries.ENTITIES, minecart.MOD_ID); public static final RegistryObject<EntityType<Minecart_new>> MINECART_ENTITY = ENTITIES.register("minecart_new", () -> EntityType.Builder.of(Minecart_new::new, MobCategory.MISC).sized(0.98F, 0.7F) .build(new ResourceLocation(minecart.MOD_ID,"minecart_new").toString())); }  
    • https://github.com/Kiwilis/simple-automation There's not much there yet, because this project isn't even a week old and I don't have a lot of time to work on it.
    • show your Entity class and your registration 
    • Hi. I have a custom entity minecart_new and I can summon it in minecraft by typing /summon minecart:minecart_new. How can I imitate this command via forge? What code should I write?  In minecraft I want it to be as follows: when player right click on custom item then command /summon minecart:minecart_new should be imitated.  So my code now is  @SubscribeEvent public void minecartItemRightClick(RightClickItem event) { if (event.getItemStack().getItem() == ItemInit.MINECARTNEW_ITEM.get()) { //imitate /summon minecart:minecart_new } } Event hooking works fine I think. What should I type instead of //imitate /summon minecart:minecart_new? Thanks in advance!
    • User was banned for piracy. Buy the game.
  • Topics

  • Who's Online (See full list)

×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.