daily pastebin goal
48%
SHARE
TWEET

Untitled

a guest Jan 19th, 2019 56 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. protected void entityInit() {
  2.     super.entityInit();
  3.     if (arrow == null) arrow = new ItemStack(Item.arrow,1);
  4. }
  5. public void onCollideWithPlayer(EntityPlayer par1EntityPlayer) {
  6.         if (worldObj.isRemote) return;
  7.     if (inGround && arrowShake <= 0) {
  8.         if (arrow != null) {
  9.             if (Math.random() < pickupChance) {
  10.                 EntityItem a = new EntityItem(worldObj, posX, posY, posZ, arrow);
  11.                 a.setVelocity(0,0,0);
  12.                 worldObj.spawnEntityInWorld(a);
  13.             }
  14.             setDead();
  15.         }
  16.     }
  17. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top