Skip to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Animefan8888

Forge Modder
  • Joined

  • Last visited

Everything posted by Animefan8888

  1. You created a wrapper for a reason.
  2. IBlockColor.colorMultiplier I feel like it will be mostly an instance of World, other than that you are screwed.
  3. It appears to me that it is only accessible from a World. I assume I am screwed then? Seems like it, what method passes an IBlockAccess that you are using?
  4. Add a new entry to your list.
  5. Yes you will have to create your own capability. The forge documentation is a little low, but there are examples out there Choonster has some example on his github. There is also this which helped me understand what I need for a capability specifically. https://github.com/Choonster?tab=repositories http://www.planetminecraft.com/blog/forge-tutorial-capability-system/
  6. You can check to see if it is an instance of World, or any other instance that you can get it from.
  7. Yes in the @Mod annotation serverSide = true. Thank you very much Animefan8888. Also. The mod I made has a set of translated messages in the assets folder. I noticed if I didn't reopen the client while in development, the messages didn't work well because it shows the "id" of the message. So that means that the translation happens in the client and the client is which has the language files. Is there a way to do the same but server side? I don't know if I should create another post for this question... No there is not another way to do this, as the server doesn't need to know the translations it is only server side, I suppose you could make a translator your self.
  8. I think you will want to create a new one and then in the methods you need to call the super if it doesn't match yours. IE @Override public ICapabilityProvider initCapabilities(ItemStack stack, NBTTagCompound nbt) { ICapabilityProvider superProvider = super.initCapabilities(stack, nbt); return new ICapabilityProvider() { @Override public boolean hasCapability(Capability<?> capability, EnumFacing facing) { return capability == yourCapability ? true : superProvider.hasCapability(capability, facing); } @Override public <T> T getCapability(Capability<T> capability, EnumFacing facing) { return capability == yourCapability ? yourCapability : superProvider.getCapability(capability, facing); } }; } I don't see how you could incorporate facing into an Item, but...ehh.
  9. Post your whole class.
  10. Yes in the @Mod annotation serverSide = true.
  11. how can i do that? player.fallDistance = 0; ? Two ways either Subscribe to the LivingFallEvent or litterally in your onArmorTick constantly set it to 0. All right ill take care of that in a bit, but running into a bit of a problem, when i charge up the jetpack in my inventory it also charges all the jetpacks in the world, how do i fix that? Make a ItemStack capability for energy items.
  12. how can i do that? player.fallDistance = 0; ? Two ways either Subscribe to the LivingFallEvent or litterally in your onArmorTick constantly set it to 0.
  13. nah that is good, but i would add an if else statement like if (player.motionY >= someVelocity) { // Do stuff } else { // Add velocity }
  14. Could you post code so I can see what you tried.
  15. player.addVelocity(0, 0.2/** Running speed 0.1 walking speed*/, 0); Also you may want to add a cap, y velocity.
  16. No x, y, z are different from velocity. Velocity is speed and direction, x, y, z are positions.
  17. Actually it would probably be better to detect when the button is pressed, then set a boolean to true and send a packet to make the boolean true on the server, this way you don't have the Player moved wrongly or some other alert message going in the server console. And then when it is released send a packet setting it to false and set it to false.
  18. You need to override TileEntity#getUpdatePacket(), TileEntity#getUpdateTag(), TileEntity#onDataPacket(), and TileEntity#handleUpdateTag(). And you should switch fromusing ISIdedInventory to the IItemHandler capability.
  19. You need a mountable entity that is invisible.
  20. Does rendered.getIsRendered()'s value ever changed to a 1?
  21. Or do it in the attackEntityAsMob() or any other attacking function...
  22. This this.attackEntityAsMob(this) Is saying attack this mob with this mob. Not attack a mob with this mob. attackEntityAsMob(Entity) is supposed to be called by other Entities not the one you are in. So what if (!this.worldObj.isRemote && this.attackEntityAsMob(this)) { is really saying is if the world is server side and I can attack myself create an explosion.
  23. First off no Thread.sleep() is not a valid way of doing that. It puts the whole thread asleep. IE no game play the entire thing pauses. And I wonder why that method does nothing....oh wait From the World class. public void playSound(double x, double y, double z, SoundEvent soundIn, SoundCategory category, float volume, float pitch, boolean distanceDelay) { } Edit: Off topic, but something I found very funny that can be done. PositionedSoundRecord sound = new PositionedSoundRecord(SoundEvents.ENTITY_CREEPER_PRIMED, SoundCategory.HOSTILE, 1, 1, new BlockPos(0, 0, 0)); @Override @SideOnly(Side.CLIENT) public void addInformation(ItemStack stack, EntityPlayer playerIn, List<String> tooltip, boolean advanced) { if (!Minecraft.getMinecraft().getSoundHandler().isSoundPlaying(sound)) { sound = new PositionedSoundRecord(SoundEvents.ENTITY_CREEPER_PRIMED, SoundCategory.HOSTILE, 1, 1, playerIn.getPosition()); Minecraft.getMinecraft().getSoundHandler().playSound(sound); } }
  24. Not it has, but it needs.

Important Information

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

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.