Everything posted by DavidM
-
Checking for EntityPlayer on LivingHurtEvent
Use the instanceof keyword.
-
[1.114.4]Nerby Villiager
The predicate need to return true if the given Entity matches what you are looking for. In this case, it should return true if the given Entity if a villager.
-
Encountered a error during the load_registries event phase
Something is null at line 41. We need more code to figure out what it is. Either post code as a GitHub repo or find the culprit with the debugger.
-
[1.14.4] Need help with item tooltips .
1. Do not name your class with lower cases. The convention is to camel case and capitalize the first letter. 2. Your info method does nothing as of now. You need to override Item#addInformation instead.
-
Simulating transfering items
Check out GuiContainer#handleMouseClick. Simply iterate through every ItemStack in the opened chest container, and invoke GuiContainer#handleMouseClick with the appropriate slot for each ItemStack.
-
(SOLVED) [1.14.4] Best Way to Switch between Multiple Mods?
Use git clone.
-
[1.12.2] going insane trying to find out what makes this two mods derp
People other than the author of the mod are not necessarily familiar with the mod. Please report this phenomenon to the author of the mod.
-
Render Image over other players
Since the rendering of the player is done by OpenGL in a 3D space, the coordinate is a 3D coordinate in regards to the OpenGL rendering position (in relation to the screen view).
-
[1.14.4] Unable to set Y motion
You do have to include it unless the annotation is attached to a class inside the main mod class (which would have the mod ID passed in as a parameter in the @Mod annotation), which is not the case here.
-
[1.12.2] merge same chat message
Make a static field that stores the last chat message received. Subscribe to ClientChatReceivedEvent and compare the received message to the last message variable. Cancel the event if they have the same content, else set the last message variable to the received message. I might have misunderstood the question.
-
Render Image over other players
Subscribe to RenderPlayeEvent.Post and do your rendering there. The render position of the player is passed in via the event.
-
Can Classes be a "location" for a block?
setRegistryName takes in a ResourceLocation; you cannot replace it with a class. However, you can register any instance of Block, therefore you could create a new class extending Block.
-
Config Button Greyed Out
The mods you install have to implement a config page. Consider asking the mod author about implementing the in-game config page.
-
[SOLVED] [1.12.2] Runnable Scheduled Tasks
I believe so.
-
[SOLVED] [1.12.2] Runnable Scheduled Tasks
Packet handling and the game are on different threads. Therefore, any actions concerning the game should be in a scheduled task (i.e. world manipulation, tile entity manipulation, etc).
-
RL Craft LAG spikes
This is actually not caused by not enough memory for the OS. Java's garbage collector tend to clear the memory when the allocated RAM is full. If the allocated RAM is little (i.e. 2GB), the clearing would be fast as it only need to clear 2GB, and the delay would be negligible to the user. However, if the allocated RAM is large (i.e. >10GB), then each clearing would take up significant longer time, thus lagging the game.
-
Server doesn't start up!
Both of those are client-only mods and do nothing on a server...
-
RL Craft LAG spikes
Allocating too much RAM will also cause lag spikes. Most modpacks require around 6GB Ram.
-
[1.14] FakePlayerFactory
A fake player is not an Entity that can be added to the world. What are you trying to achieve?
-
Can I run mods other than my own mod in the ide version of minecraft
Note that you need to install the deobfuscated version of the mod.
-
What mod(s) are causing my game to crash ?
SpecialMobs' problem. Remove it and report to its author.
-
[1.14] Make some blocks affected by gravity.
You need to replace the block with your own by overriding it in the block registry.
-
[1.14.4] Glowing effect on ItemEntity
I am creating a helmet that, when worn, displays the location of nearby dropped items. I would like to create an outline effect similar to the glowing effect of LivingEntity. What is the best way to approach this?
-
Get Entities in player's vision/sight 1.12.2
Note that the client can lie about whether an Entity should be rendered. The server should implement some checks to make sure the client's information is in legal range.
-
[Solved] 1.12 how to create explosive arrow
The tracking distance determines whether the entity should be rendered at a certain distance. It does not affect aspects like teleportation and explosion.
IPS spam blocked by CleanTalk.