Jump to content

NinjaNick95

Members
  • Posts

    3
  • Joined

  • Last visited

Posts posted by NinjaNick95

  1. Hello,

     

    I've been looking through the source code and forge documentation for most of the day trying to figure out how I can accomplish this. From what I can tell a coremod is the only way to do this currently.

     

    This is because the code that removes a fired arrow from the player's inventory is in the onPlayerStoppedUsing method of ItemBow.class and not included in the ArrowNock or ArrowLoose events:

     

    From ItemBow.class:

    if (!flag1 && !entityplayer.capabilities.isCreativeMode)
    {
    	itemstack.shrink(1);
    
    	if (itemstack.isEmpty())
    	{
    		entityplayer.inventory.deleteStack(itemstack);
    	}
    }

    ^Flag1 checks if ammo is of the ItemArrow class specifically (TippedArrow is its own class so it fails this check). This is probably the easiest place to modify to allow tipped arrows to work with Infinity.

     

    Reflection is a completely new concept to me but from what I'm reading it doesn't look like it would work for this. Please correct me if I'm wrong.

×
×
  • Create New...

Important Information

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