Permalink
Browse files

Functional change Lignum suggested

  • Loading branch information...
Wojbie committed Jul 28, 2017
1 parent 225ec59 commit acb5f65e162a0aa6db2b8952d880d788d0706318
@@ -55,9 +55,9 @@ public BlockPos getPos()
return m_speaker.getPos();
}
public synchronized boolean madeSound()
public synchronized boolean madeSound(long ticks)
{
return (m_clock - m_lastPlayTime <= 20) ;
return (m_clock - m_lastPlayTime <= ticks) ;
}
/* IPeripheral implementation */
@@ -75,7 +75,7 @@ else if ( entity != null )
speaker.setLocation( entity.getEntityWorld(), entity.posX, entity.posY, entity.posZ );
}
speaker.update();
access.setLight( speaker.madeSound() ? 0x3320fc : -1 );
access.setLight( speaker.madeSound(20) ? 0x3320fc : -1 );
}
}

0 comments on commit acb5f65

Please sign in to comment.