Skip to main content

Module chicken

Module chicken 

Source
Expand description

Those mobs are passive creatures that run away when attacked by a player. Vanilla Chicken entity with variant + sound-variant parity, wing-flap slow-fall, and periodic egg-laying behavior.

StructsΒ§

ChickenEntity
Vanilla chicken entity.
ChickenState πŸ”’
Runtime state unique to chickens: wing-flap animation, egg timer, and jockey flag.

ConstantsΒ§

CHICKEN_BABY_DIMENSIONS πŸ”’
CHICKEN_BABY_EYE_HEIGHT πŸ”’
CHICKEN_BABY_HEIGHT πŸ”’
CHICKEN_BABY_PASSENGER_ATTACHMENTS πŸ”’
CHICKEN_BABY_WIDTH πŸ”’
CHICKEN_JOCKEY_EXPERIENCE_REWARD πŸ”’
Experience rewarded for a chicken jockey (vanilla Chicken.getBaseExperienceReward).
EGG_LAY_MIN_DELAY_TICKS πŸ”’
Minimum ticks between egg lays (vanilla nextInt(6000) + 6000).
EGG_LAY_RANDOM_RANGE_TICKS πŸ”’
Range of the randomized egg-lay delay in ticks.
EGG_LAY_SOUND_BASE_PITCH πŸ”’
EGG_LAY_SOUND_PITCH_JITTER πŸ”’
Pitch jitter around the base egg-lay sound pitch.
EGG_LAY_SOUND_VOLUME πŸ”’
EGG_LAY_SPAWN_Y_OFFSET πŸ”’
Offset at which laid eggs spawn above the chicken’s feet.
FALL_DRAG_Y πŸ”’
Downward velocity multiplier while airborne, producing the chicken slow-fall.
FLAPPING_STRENGTH_DECAY πŸ”’
Multiplicative flapping-strength decay per tick.
FLAP_ROTATION_SCALE πŸ”’
Scales accumulated flap rotation (vanilla Chicken.aiStep).
FLAP_SPEED_ADJUST_SCALE πŸ”’
Scales the per-tick flap-speed adjustment (vanilla Chicken.aiStep).
FLAP_SPEED_AIR_GAIN πŸ”’
Flap speed gained per tick while airborne (vanilla Chicken.aiStep).
FLAP_SPEED_GROUND_LOSS πŸ”’
Flap speed lost per tick while grounded (vanilla Chicken.aiStep).
FLAP_SPEED_MAX πŸ”’
FLAP_SPEED_MIN πŸ”’
MIN_FLAPPING_STRENGTH πŸ”’
Flapping strength restored whenever the chicken is airborne.
NEXT_FLAP_SPEED_DIVISOR πŸ”’
Divisor converting flap speed into the next flap distance threshold.