Skip to content

Package net.minecraft.world.entity.animal.armadillo

Part 1/1


Armadillo

  • Full name: net.minecraft.world.entity.animal.armadillo.Armadillo
  • Package: net.minecraft.world.entity.animal.armadillo
  • Source: commonnet/minecraft/world/entity/animal/armadillo/Armadillo.java
  • Type: class
  • Modifiers: public
  • Extends: Animal

net.minecraft.world.entity.animal.armadillo.Armadillo#actuallyHurt(ServerLevel,DamageSource,float)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:290
  • Modifiers: protected
  • Return: void

คืออะไร

ดำเนินการ actuallyHurt ตาม implementation ของ Armadillo

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: isNoAi(), isDeadOrDying(), getEntity(), getBrain(), setMemoryWithExpiry(), canStayRolledUp(), rollUp(), is().

Parameters

  • ServerLevel serverLevel
  • DamageSource damageSource
  • float f

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
DamageSource damageSource = ...;
@Override
protected void actuallyHurt(ServerLevel serverLevel, DamageSource damageSource, float f) {
    super.actuallyHurt(serverLevel, damageSource, f);
}

net.minecraft.world.entity.animal.armadillo.Armadillo#addAdditionalSaveData(CompoundTag)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:247
  • Modifiers: public
  • Return: void

คืออะไร

เพิ่ม Additional Save Data

ทำงานยังไง

เรียกต่อ: putString(), getState(), getSerializedName(), putInt().

Parameters

  • CompoundTag compoundTag

ตัวอย่างใช้งาน

Armadillo instance = ...;
CompoundTag compoundTag = ...;
instance.addAdditionalSaveData(compoundTag);

net.minecraft.world.entity.animal.armadillo.Armadillo#Armadillo(EntityType<? extends Animal>,Level)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:67
  • Modifiers: public
  • Kind: constructor

คืออะไร

สร้างออบเจ็กต์ Armadillo ด้วยพารามิเตอร์ที่ระบุ

ทำงานยังไง

แก้ state: scuteTime. เรียกต่อ: getNavigation(), setCanFloat(), pickNextScuteDropTime().

Parameters

  • EntityType<? extends Animal> entityType
  • Level level

ตัวอย่างใช้งาน

EntityType<? extends Animal> entityType = ...;
Level level = ...;
Armadillo instance = new Armadillo(entityType, level);

net.minecraft.world.entity.animal.armadillo.Armadillo#brainProvider()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:124
  • Modifiers: protected
  • Return: Brain.Provider<Armadillo>

คืออะไร

ดำเนินการ brainProvider ตาม implementation ของ Armadillo

ทำงานยังไง

คืนค่า: ArmadilloAi.brainProvider().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

@Override
protected Brain.Provider<Armadillo> brainProvider() {
    return super.brainProvider();
}

net.minecraft.world.entity.animal.armadillo.Armadillo#brushOffScute()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:316
  • Modifiers: public
  • Return: boolean

คืออะไร

ดำเนินการ brushOffScute ตาม implementation ของ Armadillo

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: isBaby(), level(), spawnAtLocation(), gameEvent(), playSound(). สร้างออบเจ็กต์: ItemStack. มีจุด return อย่างน้อย 2 จุด.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
boolean result = instance.brushOffScute();

net.minecraft.world.entity.animal.armadillo.Armadillo#canFallInLove()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:334
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบว่าสามารถ Fall In Love

ทำงานยังไง

เรียกต่อ: isScared(). คืนค่า: super.canFallInLove() && !this.isScared().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
boolean result = instance.canFallInLove();

net.minecraft.world.entity.animal.armadillo.Armadillo#canStayRolledUp()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:330
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบว่าสามารถ Stay Rolled Up

ทำงานยังไง

เรียกต่อ: isPanicking(), isInLiquid(), isLeashed(), isPassenger(), isVehicle(). คืนค่า: !this.isPanicking() && !this.isInLiquid() && !this.isLeashed() && !this.isPassenger() && !this.isVehicle().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
boolean result = instance.canStayRolledUp();

net.minecraft.world.entity.animal.armadillo.Armadillo#checkArmadilloSpawnRules(EntityType<Armadillo>,LevelAccessor,EntitySpawnReason,BlockPos,RandomSource)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:227
  • Modifiers: public static
  • Return: boolean

คืออะไร

ตรวจสอบ Armadillo Spawn Rules

ทำงานยังไง

เรียกต่อ: getBlockState(), below(), is(), isBrightEnoughToSpawn(). คืนค่า: levelAccessor.getBlockState(blockPos.below()).is(BlockTags.ARMADILLO_SPAWNABLE_ON) && isBrightEnoughToSpawn(levelAccessor, blockPos).

Parameters

  • EntityType<Armadillo> entityType
  • LevelAccessor levelAccessor
  • EntitySpawnReason entitySpawnReason
  • BlockPos blockPos
  • RandomSource randomSource

ตัวอย่างใช้งาน

EntityType<Armadillo> entityType = ...;
LevelAccessor levelAccessor = ...;
EntitySpawnReason entitySpawnReason = ...;
BlockPos blockPos = ...;
RandomSource randomSource = ...;
boolean result = Armadillo.checkArmadilloSpawnRules(entityType, levelAccessor, entitySpawnReason, blockPos, randomSource);

net.minecraft.world.entity.animal.armadillo.Armadillo#createAttributes()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:79
  • Modifiers: public static
  • Return: AttributeSupplier.Builder

คืออะไร

สร้าง Attributes

ทำงานยังไง

เรียกต่อ: createAnimalAttributes(), add(). คืนค่า: Animal.createAnimalAttributes().add(Attributes.MAX_HEALTH, 12.0).add(Attributes.MOVEMENT_SPEED, 0.14).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

AttributeSupplier.Builder result = Armadillo.createAttributes();

net.minecraft.world.entity.animal.armadillo.Armadillo#createBodyControl()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:369
  • Modifiers: protected
  • Return: BodyRotationControl

คืออะไร

สร้าง Body Control

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: clientTick(), isScared(). สร้างออบเจ็กต์: BodyRotationControl. คืนค่า: new BodyRotationControl(this) { @Override public void clientTick() { if (!Armadillo.this.isScared()) { super.clientTick().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

@Override
protected BodyRotationControl createBodyControl() {
    return super.createBodyControl();
}

net.minecraft.world.entity.animal.armadillo.Armadillo#customServerAiStep(ServerLevel)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:134
  • Modifiers: protected
  • Return: void

คืออะไร

ดำเนินการ customServerAiStep ตาม implementation ของ Armadillo

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. แก้ state: scuteTime. เรียกต่อ: get(), push(), tick(), pop(), updateActivity(), isAlive(), isBaby(), dropFromGiftLootTable().

Parameters

  • ServerLevel serverLevel

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
@Override
protected void customServerAiStep(ServerLevel serverLevel) {
    super.customServerAiStep(serverLevel);
}

net.minecraft.world.entity.animal.armadillo.Armadillo#defineSynchedData(SynchedEntityData.Builder)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:83
  • Modifiers: protected
  • Return: void

คืออะไร

ดำเนินการ defineSynchedData ตาม implementation ของ Armadillo

ทำงานยังไง

เรียกต่อ: define().

Parameters

  • SynchedEntityData.Builder builder

ตัวอย่างใช้งาน

SynchedEntityData.Builder builder = ...;
@Override
protected void defineSynchedData(SynchedEntityData.Builder builder) {
    super.defineSynchedData(builder);
}

net.minecraft.world.entity.animal.armadillo.Armadillo#getAgeScale()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:173
  • Modifiers: public
  • Return: float

คืออะไร

อ่านค่า Age Scale

ทำงานยังไง

เรียกต่อ: isBaby(). คืนค่า: this.isBaby() ? 0.6F : 1.0F.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
float result = instance.getAgeScale();

net.minecraft.world.entity.animal.armadillo.Armadillo#getAmbientSound()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:339
  • Modifiers: protected
  • Return: SoundEvent

คืออะไร

อ่านค่า Ambient Sound

ทำงานยังไง

เรียกต่อ: isScared(). คืนค่า: this.isScared() ? null : SoundEvents.ARMADILLO_AMBIENT.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

@Override
protected SoundEvent getAmbientSound() {
    return super.getAmbientSound();
}

net.minecraft.world.entity.animal.armadillo.Armadillo#getBreedOffspring(ServerLevel,AgeableMob)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:73
  • Modifiers: public
  • Return: AgeableMob

คืออะไร

อ่านค่า Breed Offspring

ทำงานยังไง

เรียกต่อ: create(). คืนค่า: EntityType.ARMADILLO.create(serverLevel, EntitySpawnReason.BREEDING).

Parameters

  • ServerLevel serverLevel
  • AgeableMob ageableMob

ตัวอย่างใช้งาน

Armadillo instance = ...;
ServerLevel serverLevel = ...;
AgeableMob ageableMob = ...;
AgeableMob result = instance.getBreedOffspring(serverLevel, ageableMob);

net.minecraft.world.entity.animal.armadillo.Armadillo#getDeathSound()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:349
  • Modifiers: protected
  • Return: SoundEvent

คืออะไร

อ่านค่า Death Sound

ทำงานยังไง

คืนค่า: SoundEvents.ARMADILLO_DEATH.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

@Override
protected SoundEvent getDeathSound() {
    return super.getDeathSound();
}

net.minecraft.world.entity.animal.armadillo.Armadillo#getHurtSound(DamageSource)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:354
  • Modifiers: protected
  • Return: SoundEvent

คืออะไร

อ่านค่า Hurt Sound

ทำงานยังไง

เรียกต่อ: isScared(). คืนค่า: this.isScared() ? SoundEvents.ARMADILLO_HURT_REDUCED : SoundEvents.ARMADILLO_HURT.

Parameters

  • DamageSource damageSource

ตัวอย่างใช้งาน

DamageSource damageSource = ...;
@Override
protected SoundEvent getHurtSound(DamageSource damageSource) {
    return super.getHurtSound(damageSource);
}

net.minecraft.world.entity.animal.armadillo.Armadillo#getMaxHeadYRot()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:364
  • Modifiers: public
  • Return: int

คืออะไร

อ่านค่า Max Head YRot

ทำงานยังไง

เรียกต่อ: isScared(). คืนค่า: this.isScared() ? 0 : 32.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
int result = instance.getMaxHeadYRot();

net.minecraft.world.entity.animal.armadillo.Armadillo#getState()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:101
  • Modifiers: public
  • Return: Armadillo.ArmadilloState

คืออะไร

อ่านค่า State

ทำงานยังไง

เรียกต่อ: get(). คืนค่า: this.entityData.get(ARMADILLO_STATE).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
Armadillo.ArmadilloState result = instance.getState();

net.minecraft.world.entity.animal.armadillo.Armadillo#handleEntityEvent(byte)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:212
  • Modifiers: public
  • Return: void

คืออะไร

จัดการ Entity Event

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. แก้ state: peekReceivedClient. เรียกต่อ: level(), playLocalSound(), getX(), getY(), getZ(), getSoundSource().

Parameters

  • byte b

ตัวอย่างใช้งาน

Armadillo instance = ...;
instance.handleEntityEvent(0);

net.minecraft.world.entity.animal.armadillo.Armadillo#hurtServer(ServerLevel,DamageSource,float)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:281
  • Modifiers: public
  • Return: boolean

คืออะไร

ประมวลผลความเสียหาย Server

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: isScared(). คืนค่า: super.hurtServer(serverLevel, damageSource, f).

Parameters

  • ServerLevel serverLevel
  • DamageSource damageSource
  • float f

ตัวอย่างใช้งาน

Armadillo instance = ...;
ServerLevel serverLevel = ...;
DamageSource damageSource = ...;
boolean result = instance.hurtServer(serverLevel, damageSource, 0.0F);

net.minecraft.world.entity.animal.armadillo.Armadillo#isFood(ItemStack)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:222
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบสถานะ Food

ทำงานยังไง

เรียกต่อ: is(). คืนค่า: itemStack.is(ItemTags.ARMADILLO_FOOD).

Parameters

  • ItemStack itemStack

ตัวอย่างใช้งาน

Armadillo instance = ...;
ItemStack itemStack = ...;
boolean result = instance.isFood(itemStack);

net.minecraft.world.entity.animal.armadillo.Armadillo#isScared()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:89
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบสถานะ Scared

ทำงานยังไง

เรียกต่อ: get(). คืนค่า: this.entityData.get(ARMADILLO_STATE) != Armadillo.ArmadilloState.IDLE.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
boolean result = instance.isScared();

net.minecraft.world.entity.animal.armadillo.Armadillo#isScaredBy(LivingEntity)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:233
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบสถานะ Scared By

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: getBoundingBox(), inflate(), intersects(), getType(), is(), getLastHurtByMob(), isSpectator(), isSprinting(). มีจุด return อย่างน้อย 5 จุด.

Parameters

  • LivingEntity livingEntity

ตัวอย่างใช้งาน

Armadillo instance = ...;
LivingEntity livingEntity = ...;
boolean result = instance.isScaredBy(livingEntity);

net.minecraft.world.entity.animal.armadillo.Armadillo#makeBrain(Dynamic<?>)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:129
  • Modifiers: protected
  • Return: Brain<?>

คืออะไร

สร้าง Brain

ทำงานยังไง

เรียกต่อ: brainProvider(). คืนค่า: ArmadilloAi.makeBrain(this.brainProvider().makeBrain(dynamic)).

Parameters

  • Dynamic<?> dynamic

ตัวอย่างใช้งาน

Dynamic<?> dynamic = ...;
@Override
protected Brain<?> makeBrain(Dynamic<?> dynamic) {
    return super.makeBrain(dynamic);
}

net.minecraft.world.entity.animal.armadillo.Armadillo#mobInteract(Player,InteractionHand)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:305
  • Modifiers: public
  • Return: InteractionResult

คืออะไร

ดำเนินการ mobInteract ตาม implementation ของ Armadillo

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: getItemInHand(), is(), brushOffScute(), hurtAndBreak(), getSlotForHand(), isScared(). มีจุด return อย่างน้อย 2 จุด.

Parameters

  • Player player
  • InteractionHand interactionHand

ตัวอย่างใช้งาน

Armadillo instance = ...;
Player player = ...;
InteractionHand interactionHand = ...;
InteractionResult result = instance.mobInteract(player, interactionHand);

net.minecraft.world.entity.animal.armadillo.Armadillo#onSyncedDataUpdated(EntityDataAccessor<?>)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:115
  • Modifiers: public
  • Return: void

คืออะไร

จัดการเหตุการณ์ Synced Data Updated

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. แก้ state: inStateTicks. เรียกต่อ: equals().

Parameters

  • EntityDataAccessor<?> entityDataAccessor

ตัวอย่างใช้งาน

Armadillo instance = ...;
EntityDataAccessor<?> entityDataAccessor = ...;
instance.onSyncedDataUpdated(entityDataAccessor);

net.minecraft.world.entity.animal.armadillo.Armadillo#playEatingSound()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:344
  • Modifiers: protected
  • Return: void

คืออะไร

ดำเนินการ playEatingSound ตาม implementation ของ Armadillo

ทำงานยังไง

เรียกต่อ: makeSound().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

@Override
protected void playEatingSound() {
    super.playEatingSound();
}

net.minecraft.world.entity.animal.armadillo.Armadillo#playStepSound(BlockPos,BlockState)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:359
  • Modifiers: protected
  • Return: void

คืออะไร

ดำเนินการ playStepSound ตาม implementation ของ Armadillo

ทำงานยังไง

เรียกต่อ: playSound().

Parameters

  • BlockPos blockPos
  • BlockState blockState

ตัวอย่างใช้งาน

BlockPos blockPos = ...;
BlockState blockState = ...;
@Override
protected void playStepSound(BlockPos blockPos, BlockState blockState) {
    super.playStepSound(blockPos, blockState);
}

net.minecraft.world.entity.animal.armadillo.Armadillo#readAdditionalSaveData(CompoundTag)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:254
  • Modifiers: public
  • Return: void

คืออะไร

อ่าน Additional Save Data

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. แก้ state: scuteTime. เรียกต่อ: switchToState(), fromName(), getString(), contains(), getInt().

Parameters

  • CompoundTag compoundTag

ตัวอย่างใช้งาน

Armadillo instance = ...;
CompoundTag compoundTag = ...;
instance.readAdditionalSaveData(compoundTag);

net.minecraft.world.entity.animal.armadillo.Armadillo#rollOut()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:273
  • Modifiers: public
  • Return: void

คืออะไร

ดำเนินการ rollOut ตาม implementation ของ Armadillo

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: isScared(), gameEvent(), makeSound(), switchToState().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
instance.rollOut();

net.minecraft.world.entity.animal.armadillo.Armadillo#rollUp()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:263
  • Modifiers: public
  • Return: void

คืออะไร

ดำเนินการ rollUp ตาม implementation ของ Armadillo

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: isScared(), stopInPlace(), resetLove(), gameEvent(), makeSound(), switchToState().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
instance.rollUp();

net.minecraft.world.entity.animal.armadillo.Armadillo#sendDebugPackets()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:105
  • Modifiers: protected
  • Return: void

คืออะไร

ส่ง Debug Packets

ทำงานยังไง

เรียกต่อ: sendEntityBrain().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

@Override
protected void sendDebugPackets() {
    super.sendDebugPackets();
}

net.minecraft.world.entity.animal.armadillo.Armadillo#shouldHideInShell()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:93
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบว่าควร Hide In Shell

ทำงานยังไง

เรียกต่อ: getState(). คืนค่า: this.getState().shouldHideInShell(this.inStateTicks).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
boolean result = instance.shouldHideInShell();

net.minecraft.world.entity.animal.armadillo.Armadillo#shouldSwitchToScaredState()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:97
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบว่าควร Switch To Scared State

ทำงานยังไง

เรียกต่อ: getState(), animationDuration(). คืนค่า: this.getState() == Armadillo.ArmadilloState.ROLLING && this.inStateTicks > Armadillo.ArmadilloState.ROLLING.animationDuration().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
boolean result = instance.shouldSwitchToScaredState();

net.minecraft.world.entity.animal.armadillo.Armadillo#switchToState(Armadillo.ArmadilloState)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:111
  • Modifiers: public
  • Return: void

คืออะไร

ดำเนินการ switchToState ตาม implementation ของ Armadillo

ทำงานยังไง

เรียกต่อ: set().

Parameters

  • Armadillo.ArmadilloState armadilloState

ตัวอย่างใช้งาน

Armadillo instance = ...;
Armadillo.ArmadilloState armadilloState = ...;
instance.switchToState(armadilloState);

net.minecraft.world.entity.animal.armadillo.Armadillo#tick()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:159
  • Modifiers: public
  • Return: void

คืออะไร

ประมวลผล tick tick

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. แก้ state: inStateTicks. เรียกต่อ: level(), isClientSide(), setupAnimationStates(), isScared(), clampHeadRotationToBody().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo instance = ...;
instance.tick();

Armadillo$ArmadilloState

  • Full name: net.minecraft.world.entity.animal.armadillo.Armadillo$ArmadilloState
  • Package: net.minecraft.world.entity.animal.armadillo
  • Source: commonnet/minecraft/world/entity/animal/armadillo/Armadillo.java
  • Type: enum
  • Modifiers: public
  • Implements: StringRepresentable

net.minecraft.world.entity.animal.armadillo.Armadillo$ArmadilloState#animationDuration()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:443
  • Modifiers: public
  • Return: int

คืออะไร

ดำเนินการ animationDuration ตาม implementation ของ Armadillo$ArmadilloState

ทำงานยังไง

คืนค่า: this.animationDuration.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo.ArmadilloState instance = ...;
int result = instance.animationDuration();

net.minecraft.world.entity.animal.armadillo.Armadillo$ArmadilloState#fromName(String)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:424
  • Modifiers: public static
  • Return: Armadillo.ArmadilloState

คืออะไร

ดำเนินการ fromName ตาม implementation ของ Armadillo$ArmadilloState

ทำงานยังไง

เรียกต่อ: byName(). คืนค่า: CODEC.byName(string, IDLE).

Parameters

  • String string

ตัวอย่างใช้งาน

Armadillo.ArmadilloState result = Armadillo.ArmadilloState.fromName("value");

net.minecraft.world.entity.animal.armadillo.Armadillo$ArmadilloState#getSerializedName()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:428
  • Modifiers: public
  • Return: String

คืออะไร

อ่านค่า Serialized Name

ทำงานยังไง

คืนค่า: this.name.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo.ArmadilloState instance = ...;
String result = instance.getSerializedName();

net.minecraft.world.entity.animal.armadillo.Armadillo$ArmadilloState#isThreatened()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:439
  • Modifiers: public
  • Return: boolean

คืออะไร

ตรวจสอบสถานะ Threatened

ทำงานยังไง

คืนค่า: this.isThreatened.

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Armadillo.ArmadilloState instance = ...;
boolean result = instance.isThreatened();

net.minecraft.world.entity.animal.armadillo.Armadillo$ArmadilloState#shouldHideInShell(long)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/Armadillo.java:437
  • Modifiers: public abstract
  • Return: boolean

คืออะไร

ตรวจสอบว่าควร Hide In Shell

ทำงานยังไง

ไม่มี implementation ใน declaration นี้; คลาสลูก/implementation เป็นผู้กำหนดพฤติกรรมจริง

Parameters

  • long l

ตัวอย่างใช้งาน

Armadillo.ArmadilloState instance = ...;
boolean result = instance.shouldHideInShell(0L);

ArmadilloAi

  • Full name: net.minecraft.world.entity.animal.armadillo.ArmadilloAi
  • Package: net.minecraft.world.entity.animal.armadillo
  • Source: commonnet/minecraft/world/entity/animal/armadillo/ArmadilloAi.java
  • Type: class
  • Modifiers: public

net.minecraft.world.entity.animal.armadillo.ArmadilloAi#brainProvider()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:82
  • Modifiers: public static
  • Return: Brain.Provider<Armadillo>

คืออะไร

ดำเนินการ brainProvider ตาม implementation ของ ArmadilloAi

ทำงานยังไง

เรียกต่อ: provider(). คืนค่า: Brain.provider(MEMORY_TYPES, SENSOR_TYPES).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Brain.Provider<Armadillo> result = ArmadilloAi.brainProvider();

net.minecraft.world.entity.animal.armadillo.ArmadilloAi#getTemptations()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:156
  • Modifiers: public static
  • Return: Predicate<ItemStack>

คืออะไร

อ่านค่า Temptations

ทำงานยังไง

เรียกต่อ: is(). คืนค่า: itemStack -> itemStack.is(ItemTags.ARMADILLO_FOOD).

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

Predicate<ItemStack> result = ArmadilloAi.getTemptations();

net.minecraft.world.entity.animal.armadillo.ArmadilloAi#makeBrain(Brain<Armadillo>)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:86
  • Modifiers: protected static
  • Return: Brain<?>

คืออะไร

สร้าง Brain

ทำงานยังไง

เรียกต่อ: initCoreActivity(), initIdleActivity(), initScaredActivity(), setCoreActivities(), of(), setDefaultActivity(), useDefaultActivity(). คืนค่า: brain.

Parameters

  • Brain<Armadillo> brain

ตัวอย่างใช้งาน

Brain<Armadillo> brain = ...;
@Override
protected Brain<?> makeBrain(Brain<Armadillo> brain) {
    return super.makeBrain(brain);
}

net.minecraft.world.entity.animal.armadillo.ArmadilloAi#updateActivity(Armadillo)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:152
  • Modifiers: public static
  • Return: void

คืออะไร

อัปเดต Activity

ทำงานยังไง

เรียกต่อ: getBrain(), setActiveActivityToFirstValid(), of().

Parameters

  • Armadillo armadillo

ตัวอย่างใช้งาน

Armadillo armadillo = ...;
ArmadilloAi.updateActivity(armadillo);

ArmadilloAi$ArmadilloBallUp

  • Full name: net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp
  • Package: net.minecraft.world.entity.animal.armadillo
  • Source: commonnet/minecraft/world/entity/animal/armadillo/ArmadilloAi.java
  • Type: class
  • Modifiers: public static
  • Extends: Behavior<Armadillo>

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp#ArmadilloBallUp()

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:167
  • Modifiers: public
  • Kind: constructor

คืออะไร

สร้างออบเจ็กต์ ArmadilloAi.ArmadilloBallUp ด้วยพารามิเตอร์ที่ระบุ

ทำงานยังไง

เรียกต่อ: of().

Parameters

  • ไม่มี

ตัวอย่างใช้งาน

ArmadilloAi.ArmadilloBallUp instance = new ArmadilloAi.ArmadilloBallUp();

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp#canStillUse(ServerLevel,Armadillo,long)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:215
  • Modifiers: protected
  • Return: boolean

คืออะไร

ตรวจสอบว่าสามารถ Still Use

ทำงานยังไง

เรียกต่อ: getState(), isThreatened(). คืนค่า: armadillo.getState().isThreatened().

Parameters

  • ServerLevel serverLevel
  • Armadillo armadillo
  • long l

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
Armadillo armadillo = ...;
@Override
protected boolean canStillUse(ServerLevel serverLevel, Armadillo armadillo, long l) {
    return super.canStillUse(serverLevel, armadillo, l);
}

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp#checkExtraStartConditions(ServerLevel,Armadillo)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:211
  • Modifiers: protected
  • Return: boolean

คืออะไร

ตรวจสอบ Extra Start Conditions

ทำงานยังไง

เรียกต่อ: onGround(). คืนค่า: armadillo.onGround().

Parameters

  • ServerLevel serverLevel
  • Armadillo armadillo

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
Armadillo armadillo = ...;
@Override
protected boolean checkExtraStartConditions(ServerLevel serverLevel, Armadillo armadillo) {
    return super.checkExtraStartConditions(serverLevel, armadillo);
}

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp#start(ServerLevel,Armadillo,long)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:219
  • Modifiers: protected
  • Return: void

คืออะไร

เริ่ม start

ทำงานยังไง

เรียกต่อ: rollUp().

Parameters

  • ServerLevel serverLevel
  • Armadillo armadillo
  • long l

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
Armadillo armadillo = ...;
@Override
protected void start(ServerLevel serverLevel, Armadillo armadillo, long l) {
    super.start(serverLevel, armadillo, l);
}

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp#stop(ServerLevel,Armadillo,long)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:223
  • Modifiers: protected
  • Return: void

คืออะไร

หยุด stop

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. เรียกต่อ: canStayRolledUp(), rollOut().

Parameters

  • ServerLevel serverLevel
  • Armadillo armadillo
  • long l

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
Armadillo armadillo = ...;
@Override
protected void stop(ServerLevel serverLevel, Armadillo armadillo, long l) {
    super.stop(serverLevel, armadillo, l);
}

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloBallUp#tick(ServerLevel,Armadillo,long)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:171
  • Modifiers: protected
  • Return: void

คืออะไร

ประมวลผล tick tick

ทำงานยังไง

ตรวจเงื่อนไขด้วย if. แก้ state: nextPeekTimer, dangerWasAround. เรียกต่อ: shouldSwitchToScaredState(), switchToState(), onGround(), playSound(), getState(), getBrain(), getTimeUntilExpiry(), pickNextPeekTimer().

Parameters

  • ServerLevel serverLevel
  • Armadillo armadillo
  • long l

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
Armadillo armadillo = ...;
@Override
protected void tick(ServerLevel serverLevel, Armadillo armadillo, long l) {
    super.tick(serverLevel, armadillo, l);
}

ArmadilloAi$ArmadilloPanic

  • Full name: net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloPanic
  • Package: net.minecraft.world.entity.animal.armadillo
  • Source: commonnet/minecraft/world/entity/animal/armadillo/ArmadilloAi.java
  • Type: class
  • Modifiers: public static
  • Extends: AnimalPanic<Armadillo>

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloPanic#ArmadilloPanic(float)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:231
  • Modifiers: public
  • Kind: constructor

คืออะไร

สร้างออบเจ็กต์ ArmadilloAi.ArmadilloPanic ด้วยพารามิเตอร์ที่ระบุ

ทำงานยังไง

ทำงานตาม body โดยตรง (ประมาณ 1 statement).

Parameters

  • float f

ตัวอย่างใช้งาน

ArmadilloAi.ArmadilloPanic instance = new ArmadilloAi.ArmadilloPanic(0.0F);

net.minecraft.world.entity.animal.armadillo.ArmadilloAi$ArmadilloPanic#start(ServerLevel,Armadillo,long)

  • Origin: common
  • Source: net/minecraft/world/entity/animal/armadillo/ArmadilloAi.java:235
  • Modifiers: protected
  • Return: void

คืออะไร

เริ่ม start

ทำงานยังไง

เรียกต่อ: rollOut().

Parameters

  • ServerLevel serverLevel
  • Armadillo armadillo
  • long l

ตัวอย่างใช้งาน

ServerLevel serverLevel = ...;
Armadillo armadillo = ...;
@Override
protected void start(ServerLevel serverLevel, Armadillo armadillo, long l) {
    super.start(serverLevel, armadillo, l);
}