-
Posts
3284 -
Joined
-
Last visited
-
Days Won
62
Everything posted by ChampionAsh5357
-
1. This is problematic for sidedness. 2. Minecraft uses GLFW keybindings, not AWT KeyEvent. Use a KeyBinding regardless. 3. This is not a tutorial. Nothing is explained, just copy this and get a result.
-
[1.16] Need help with ProjectileItemEntity Physics
ChampionAsh5357 replied to kiou.23's topic in Modder Support
If RayTraceResult#getType returns BLOCK, then you know the ray trace is an instance of BlockRayTraceResult which has a method called #getDirection (or #getFace in MCP) exactly for that. -
Listeners should be added in the constructor. Make the field lazy instead of relying on classloading.
-
[1.16] Need help with ProjectileItemEntity Physics
ChampionAsh5357 replied to kiou.23's topic in Modder Support
For the simplest implementation, whenever the projectile interacts with the surface, you'll get the associated face that the surface interacted with. Then, invert the associated component and multiply it with some number between 0-1 to represent to loss of energy. For example, if the associated motion velocity is <3,-1,2> and the ball hits a face on the Y-axis (either UP or DOWN), it will invert the component to <3,1,2>. Let's say we want to have 80% of the energy conserved, then it would be <3,0.8,2>. Of course, you'll need probably a deadzone for the total motion to deal with ridiculously small numbers. If you want to introduce other factors, then I would suggest looking over some bouncing ball physics. -
[Solved] Rendered BlockState defaults to stone
ChampionAsh5357 replied to NullDev's topic in Modder Support
How does the client know what the state of the block is? You would need to use IEntityAdditionalSpawnData to send the BlockState across the network and set it on the client so it displays the same. -
Are these the only instances of tags within your mod? It's suggesting that there are minecraft entries for your mod tags or registry objects.
-
Block.Properties.create failed to compile
ChampionAsh5357 replied to heipiao's topic in Modder Support
This is not really a helpful post. Most likely you are using an MCP mapping name for the method while in mojmaps. If that's the case the method would be AbstractBlock$Properteries#of. Feel free to check the replacement of the material name as well on your own if needed. -
This will crash if loaded before blocks are registered and will bottleneck world gen for other mods. The ConfiguredFeature needs to be registered to the associated WorldGenRegistries registry. It also should be made after all registries have passed (e.g. FMLCommonSetupEvent) and registered there via Registry::register since there is no forge associated registry. This can be done by lazily storing the value and resolving it within the common setup.
-
Where is the attribute system documentation in 1.16.5?
ChampionAsh5357 replied to AlexTheDolphin0's topic in Modder Support
There's no documentation on attributes at the current moment. You would need to read through the source itself on how to create and apply them to entities. Is there anything specific that you need to know? -
Rendering custom models on player.
ChampionAsh5357 replied to JacobsDevelop's topic in Modder Support
Does it need to be a java model? The same could be accomplished with a json one. -
Forge 1.16.X create Entity from NBT
ChampionAsh5357 replied to DietmarKracht's topic in Modder Support
That's done from EntityType now through either the #create or #spawn methods. -
[Solved] [1.16.5] Semi-Transparent Particle Rendering
ChampionAsh5357 replied to Mariobro85's topic in Modder Support
Then you might want to check if the particle displays the same issues on Fabulous graphics. If not, then it's fine how it currently is. -
[Solved] [1.16.5] Semi-Transparent Particle Rendering
ChampionAsh5357 replied to Mariobro85's topic in Modder Support
You would need to set the IParticleRenderType to PARTICLE_SHEET_TRANSLUCENT via Particle#getRenderType iirc. Don't manipulate the render system in any way. -
(1.16) When updating environment variables (PATH) is needed
ChampionAsh5357 replied to Daeruin's topic in Modder Support
Not really. If you set up your JDK with no modifications, it will still point to the JDK. The path variable is pretty much just a list to which the first entry that matches the requirements will be chosen. If I had two JDKs for two different versions on the path, whichever one is at the highest priority or the top of the list will be chosen. On the other hand, I can force a specific JDK to be chosen using the JAVA_HOME environment variable which tells the program exactly where to look for the JDK. If at least one of these two are set, you should be able to mod with no issues. There is no real dependency on any underlying system for modding, just the JDK you are using (which should be 8 as that is what is shipped with vanilla). -
[1.15.2] Questions about TileEntityRenderer [Solved]
ChampionAsh5357 replied to Thorius's topic in Modder Support
Well yes, that's what they were looking for, hence the example to look into chests. A chest is an example of a model rendered inside of some VoxelShape that is not a full cube. The idea is to look for the solution and not somewhere in-between. While yes, the TER might be clouded in shadow will inside a VoxelShape, this does not necessarily have to be the case. While the chest might show how a smaller VoxelShape could still result in the same lightmap as any other block, the mob spawner can show how to interleave a model within the VoxelShape. Using any combination of these blocks' methods can produce the result required. -
Enter my own logic to ItemEntity tick method
ChampionAsh5357 replied to NIsimm's topic in Modder Support
Probably can use EntityJoinWorldEvent to store the EntityItems and remove them via EntityLeaveWorldEvent. Then can use the world tick event on the server to handle your logic and sync the data to the client. -
The if statements are still nested. Nothing has changed.
-
Enter my own logic to ItemEntity tick method
ChampionAsh5357 replied to NIsimm's topic in Modder Support
What are you attempting to do? What would the condition be? Why does it need to be checked every tick? -
With capabilities. You can also look at an unofficial version here. Either or, a block does not create energy nor produce it, it is just the container for the TileEntity that handles the dynamic data. From there, you can look at the methods and see which one inserts and which one extracts energy from the object. Do not forget to read and write the data and invalidate it in their appropriate methods. You can use one of the existing TileEntity classes (e.g. ChestTileEntity) to see how to handle that.