MCPlayerEntity

Questa classe è stata aggiunta da una mod con ID crafttweaker. Perciò, è necessario avere questa mod installata per poter utilizzare questa funzione.

Importing the class

Potrebbe essere necessario importare il pacchetto, se si incontrano dei problemi (come castare un vettore), quindi meglio essere sicuri e aggiungere la direttiva di importazione.

crafttweaker.api.entity.player.MCPlayerEntity

Methods

addExhaustion

increases exhaustion level by supplied amount

myMCPlayerEntity.addExhaustion(exhaustion as float);
ParameterTypeDescription
exhaustionfloatNessuna descrizione fornita

addExperienceLevel

Add experience levels to this player.

myMCPlayerEntity.addExperienceLevel(levels as int);
ParameterTypeDescription
levelsintNessuna descrizione fornita

addItemStackToInventory

Restituisce un booleano

myMCPlayerEntity.addItemStackToInventory(p_191521_1_ as crafttweaker.api.item.IItemStack);
ParameterTypeDescription
p191521_1crafttweaker.api.item.IItemStackNessuna descrizione fornita

addMovementStat

Adds a value to a movement statistic field - like run, walk, swin or climb.

myMCPlayerEntity.addMovementStat(p_71000_1_ as double, p_71000_3_ as double, p_71000_5_ as double);
ParameterTypeDescription
p71000_1doubleNessuna descrizione fornita
p71000_3doubleNessuna descrizione fornita
p71000_5doubleNessuna descrizione fornita

addPotionEffect

Restituisce un booleano

myMCPlayerEntity.addPotionEffect(effectInstanceIn as crafttweaker.api.potion.MCPotionEffectInstance);
ParameterTypeDescription
effectInstanceIncrafttweaker.api.potion.MCPotionEffectInstanceNessuna descrizione fornita

addScore

Add to player's score

myMCPlayerEntity.addScore(scoreIn as int);
ParameterTypeDescription
scoreInintNessuna descrizione fornita

addTag

Restituisce un booleano

myMCPlayerEntity.addTag(tag as String);
ParameterTypeDescription
tagStringNessuna descrizione fornita

addVelocity

Adds to the current velocity of the entity, and sets to true.

myMCPlayerEntity.addVelocity(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

allowLogging

Restituisce un booleano

myMCPlayerEntity.allowLogging();

attackable

Restituisce un booleano

myMCPlayerEntity.attackable();

attemptTeleport

Restituisce un booleano

myMCPlayerEntity.attemptTeleport(p_213373_1_ as double, p_213373_3_ as double, p_213373_5_ as double, p_213373_7_ as boolean);
ParameterTypeDescription
p213373_1doubleNessuna descrizione fornita
p213373_3doubleNessuna descrizione fornita
p213373_5doubleNessuna descrizione fornita
p213373_7booleanNessuna descrizione fornita

baseTick

Gets called every tick from main Entity class

myMCPlayerEntity.baseTick();

canAttackPlayer

Restituisce un booleano

myMCPlayerEntity.canAttackPlayer(other as crafttweaker.api.entity.player.MCPlayerEntity);
ParameterTypeDescription
othercrafttweaker.api.entity.player.MCPlayerEntityNessuna descrizione fornita

canBeAttackedWithItem

Returns true if it's possible to attack this entity with an item.

Restituisce un booleano

myMCPlayerEntity.canBeAttackedWithItem();

canBeCollidedWith

Returns true if other Entities should be prevented from moving through this Entity.

Restituisce un booleano

myMCPlayerEntity.canBeCollidedWith();

canBeHitWithPotion

Returns false if the entity is an armor stand. Returns true for all other entity living bases.

Restituisce un booleano

myMCPlayerEntity.canBeHitWithPotion();

canBePushed

Returns true if this entity should push and be pushed by other entities when colliding.

Restituisce un booleano

myMCPlayerEntity.canBePushed();

canBeRiddenInWater

Restituisce un booleano

myMCPlayerEntity.canBeRiddenInWater();

canBreatheUnderwater

Restituisce un booleano

myMCPlayerEntity.canBreatheUnderwater();

canEat

Restituisce un booleano

myMCPlayerEntity.canEat(ignoreHunger as boolean);
ParameterTypeDescription
ignoreHungerbooleanNessuna descrizione fornita

canHarvestBlock

Restituisce un booleano

myMCPlayerEntity.canHarvestBlock(state as crafttweaker.api.block.MCBlockState);
ParameterTypeDescription
statecrafttweaker.api.block.MCBlockStateNessuna descrizione fornita

canPassengerSteer

Restituisce un booleano

myMCPlayerEntity.canPassengerSteer();

canPlayerEdit

Returns whether this player can modify the block at a certain location with the given stack.

The position being queried is {@code pos.offset(facing.getOpposite()))}. Returns: Whether this player may modify the queried location in the current world @see ItemStack#canPlaceOn(Block) @see ItemStack#canEditBlocks() @see PlayerCapabilities#allowEdit

Restituisce un booleano

myMCPlayerEntity.canPlayerEdit(pos as crafttweaker.api.util.BlockPos, facing as crafttweaker.api.util.Direction, stack as crafttweaker.api.item.IItemStack);
ParameterTypeDescription
poscrafttweaker.api.util.BlockPosNessuna descrizione fornita
facingcrafttweaker.api.util.DirectionNessuna descrizione fornita
stackcrafttweaker.api.item.IItemStackNessuna descrizione fornita

canRenderOnFire

Return whether this entity should be rendered as on fire.

Restituisce un booleano

myMCPlayerEntity.canRenderOnFire();

canRiderInteract

Restituisce un booleano

myMCPlayerEntity.canRiderInteract();

canSwim

Restituisce un booleano

myMCPlayerEntity.canSwim();

canTrample

Restituisce un booleano

myMCPlayerEntity.canTrample(state as crafttweaker.api.block.MCBlockState, pos as crafttweaker.api.util.BlockPos, fallDistance as float);
ParameterTypeDescription
statecrafttweaker.api.block.MCBlockStateNessuna descrizione fornita
poscrafttweaker.api.util.BlockPosNessuna descrizione fornita
fallDistancefloatNessuna descrizione fornita

canUpdate

Restituisce un booleano

myMCPlayerEntity.canUpdate();
myMCPlayerEntity.canUpdate(value as boolean);
ParameterTypeDescription
valuebooleanNessuna descrizione fornita

canUseCommandBlock

Restituisce un booleano

myMCPlayerEntity.canUseCommandBlock();

clearActivePotions

Restituisce un booleano

myMCPlayerEntity.clearActivePotions();

clearBedPosition

myMCPlayerEntity.clearBedPosition();

closeScreen

set current crafting inventory back to the 2x2 square

myMCPlayerEntity.closeScreen();

curePotionEffects

Restituisce un booleano

myMCPlayerEntity.curePotionEffects(curativeItem as crafttweaker.api.item.IItemStack);
ParameterTypeDescription
curativeItemcrafttweaker.api.item.IItemStackNessuna descrizione fornita

detach

myMCPlayerEntity.detach();

disableShield

myMCPlayerEntity.disableShield(p_190777_1_ as boolean);
ParameterTypeDescription
p190777_1booleanNessuna descrizione fornita

doesEntityNotTriggerPressurePlate

Return whether this entity should NOT trigger a pressure plate or a tripwire.

Restituisce un booleano

myMCPlayerEntity.doesEntityNotTriggerPressurePlate();

equals

Restituisce un booleano

myMCPlayerEntity.equals(p_equals_1_ as Object);
ParameterTypeDescription
pequals_1ObjectNessuna descrizione fornita

extinguish

Removes fire from entity.

myMCPlayerEntity.extinguish();

fall

myMCPlayerEntity.fall(distance as float, damageMultiplier as float);
ParameterTypeDescription
distancefloatNessuna descrizione fornita
damageMultiplierfloatNessuna descrizione fornita

findAmmo

Returns crafttweaker.api.item.IItemStack

myMCPlayerEntity.findAmmo(shootable as crafttweaker.api.item.IItemStack);
ParameterTypeDescription
shootablecrafttweaker.api.item.IItemStackNessuna descrizione fornita

func_213300_bk

Restituisce un booleano

myMCPlayerEntity.func_213300_bk();

func_213312_b

myMCPlayerEntity.func_213312_b(p_213312_1_ as double, p_213312_3_ as double, p_213312_5_ as double);
ParameterTypeDescription
p213312_1doubleNessuna descrizione fornita
p213312_3doubleNessuna descrizione fornita
p213312_5doubleNessuna descrizione fornita

func_213314_bj

Restituisce un booleano

myMCPlayerEntity.func_213314_bj();

func_213343_cS

Returns float

myMCPlayerEntity.func_213343_cS();

func_213365_e

Restituisce un booleano

myMCPlayerEntity.func_213365_e(itemstackIn as crafttweaker.api.item.IItemStack);
ParameterTypeDescription
itemstackIncrafttweaker.api.item.IItemStackNessuna descrizione fornita

getAIMoveSpeed

the movespeed used for the new AI system

Returns float

myMCPlayerEntity.getAIMoveSpeed();

getAbsorptionAmount

Returns the amount of health added by the Absorption effect.

Returns float

myMCPlayerEntity.getAbsorptionAmount();

getActiveItemStack

Returns crafttweaker.api.item.IItemStack

myMCPlayerEntity.getActiveItemStack();

getActivePotionEffect

returns the PotionEffect for the supplied Potion if it is active, null otherwise.

Returns crafttweaker.api.potion.MCPotionEffectInstance

myMCPlayerEntity.getActivePotionEffect(potionIn as crafttweaker.api.potion.MCPotionEffect);
ParameterTypeDescription
potionIncrafttweaker.api.potion.MCPotionEffectNessuna descrizione fornita

getActivePotionEffects

Returns Collection<crafttweaker.api.potion.MCPotionEffectInstance>

myMCPlayerEntity.getActivePotionEffects();

getAdjustedHorizontalFacing

Gets the horizontal facing direction of this Entity, adjusted to take specially-treated entity types into account.

Returns crafttweaker.api.util.Direction

myMCPlayerEntity.getAdjustedHorizontalFacing();

getAir

Restituisce un intero

myMCPlayerEntity.getAir();

getAlwaysRenderNameTagForRender

Restituisce un booleano

myMCPlayerEntity.getAlwaysRenderNameTagForRender();

getArrowCountInEntity

Restituisce un intero

myMCPlayerEntity.getArrowCountInEntity();

getBedDirection

gets the Direction for the camera if this entity is sleeping

Returns crafttweaker.api.util.Direction

myMCPlayerEntity.getBedDirection();

getBedLocation

Returns crafttweaker.api.util.BlockPos

myMCPlayerEntity.getBedLocation();

getBlockState

Restituisce un crafttweaker.api.block.MCBlockState

myMCPlayerEntity.getBlockState();

getBrightness

Gets how bright this entity is.

Returns float

myMCPlayerEntity.getBrightness();

getBrightnessForRender

Restituisce un intero

myMCPlayerEntity.getBrightnessForRender();

getCachedUniqueIdString

Ritorna una stringa

myMCPlayerEntity.getCachedUniqueIdString();

getClassification

Returns crafttweaker.api.entity.MCEntityClassification

myMCPlayerEntity.getClassification(forSpawnCount as boolean);
ParameterTypeDescription
forSpawnCountbooleanNessuna descrizione fornita

getCollisionBorderSize

Returns float

myMCPlayerEntity.getCollisionBorderSize();

getCooldownPeriod

Returns float

myMCPlayerEntity.getCooldownPeriod();

getCooledAttackStrength

Returns the percentage of attack power available based on the cooldown (zero to one).

Returns float

myMCPlayerEntity.getCooledAttackStrength(adjustTicks as float);
ParameterTypeDescription
adjustTicksfloatNessuna descrizione fornita

getDigSpeed

Returns float

myMCPlayerEntity.getDigSpeed(state as crafttweaker.api.block.MCBlockState);
ParameterTypeDescription
statecrafttweaker.api.block.MCBlockStateNessuna descrizione fornita

Returns float

myMCPlayerEntity.getDigSpeed(arg0 as crafttweaker.api.block.MCBlockState, arg1 as crafttweaker.api.util.BlockPos);
ParameterTypeDescription
arg0crafttweaker.api.block.MCBlockStateNessuna descrizione fornita
arg1crafttweaker.api.util.BlockPosNessuna descrizione fornita

getDistanceSq

Returns double

myMCPlayerEntity.getDistanceSq(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

getEntityId

Restituisce un intero

myMCPlayerEntity.getEntityId();

getEntityString

Ritorna una stringa

myMCPlayerEntity.getEntityString();

getEyeHeight

Returns float

myMCPlayerEntity.getEyeHeight();

getFireTimer

Restituisce un intero

myMCPlayerEntity.getFireTimer();

getHealth

Returns float

myMCPlayerEntity.getHealth();

getHeight

Returns float

myMCPlayerEntity.getHeight();

getHeldItemMainhand

Returns crafttweaker.api.item.IItemStack

myMCPlayerEntity.getHeldItemMainhand();

getHeldItemOffhand

Returns crafttweaker.api.item.IItemStack

myMCPlayerEntity.getHeldItemOffhand();

getHorizontalFacing

Gets the horizontal facing direction of this Entity.

Returns crafttweaker.api.util.Direction

myMCPlayerEntity.getHorizontalFacing();

getIdleTime

Restituisce un intero

myMCPlayerEntity.getIdleTime();

getItemInUseCount

Restituisce un intero

myMCPlayerEntity.getItemInUseCount();

getItemInUseMaxCount

Restituisce un intero

myMCPlayerEntity.getItemInUseMaxCount();

getLastAttackedEntityTime

Restituisce un intero

myMCPlayerEntity.getLastAttackedEntityTime();

getLuck

Returns float

myMCPlayerEntity.getLuck();

getMaxAir

Restituisce un intero

myMCPlayerEntity.getMaxAir();

getMaxFallHeight

The maximum height from where the entity is alowed to jump (used in pathfinder)

Restituisce un intero

myMCPlayerEntity.getMaxFallHeight();

getMaxHealth

Returns float

myMCPlayerEntity.getMaxHealth();

getMaxInPortalTime

Return the amount of time this entity should stay in a portal before being transported.

Restituisce un intero

myMCPlayerEntity.getMaxInPortalTime();

getMountedYOffset

Returns the Y offset from the entity's position for any entity riding this one.

Returns double

myMCPlayerEntity.getMountedYOffset();

getPitch

Gets the current pitch of the entity.

Returns float

myMCPlayerEntity.getPitch(partialTicks as float);
ParameterTypeDescription
partialTicksfloatNessuna descrizione fornita

getPortalCooldown

Return the amount of cooldown before this entity can use a portal again.

Restituisce un intero

myMCPlayerEntity.getPortalCooldown();

getPosition

Get the position in the world. {@code null} is not allowed! If you are not an entity in the world, return the coordinates 0, 0, 0

Returns crafttweaker.api.util.BlockPos

myMCPlayerEntity.getPosition();

getRenderScale

Returns float

myMCPlayerEntity.getRenderScale();

getRevengeTimer

Restituisce un intero

myMCPlayerEntity.getRevengeTimer();

getRotationYawHead

Returns float

myMCPlayerEntity.getRotationYawHead();

getScore

Restituisce un intero

myMCPlayerEntity.getScore();

getScoreboardName

Returns a String to use as this entity's name in the scoreboard/entity selector systems

Ritorna una stringa

myMCPlayerEntity.getScoreboardName();

getSleepTimer

Restituisce un intero

myMCPlayerEntity.getSleepTimer();

getSubmergedHeight

Returns double

myMCPlayerEntity.getSubmergedHeight();

getSwimAnimation

Returns float

myMCPlayerEntity.getSwimAnimation(partialTicks as float);
ParameterTypeDescription
partialTicksfloatNessuna descrizione fornita

getSwingProgress

Gets the progression of the swing animation, ranges from 0.0 to 1.0.

Returns float

myMCPlayerEntity.getSwingProgress(partialTickTime as float);
ParameterTypeDescription
partialTickTimefloatNessuna descrizione fornita

getTags

Returns Set

myMCPlayerEntity.getTags();

getTeleportDirection

Returns crafttweaker.api.util.Direction

myMCPlayerEntity.getTeleportDirection();

getTicksElytraFlying

Restituisce un intero

myMCPlayerEntity.getTicksElytraFlying();

getTotalArmorValue

Returns the current armor value as determined by a call to InventoryPlayer.getTotalArmorValue

Restituisce un intero

myMCPlayerEntity.getTotalArmorValue();

getWidth

Returns float

myMCPlayerEntity.getWidth();

getXPSeed

Restituisce un intero

myMCPlayerEntity.getXPSeed();

getYOffset

Returns the Y Offset of this entity.

Returns double

myMCPlayerEntity.getYOffset();

getYaw

Gets the current yaw of the entity

Returns float

myMCPlayerEntity.getYaw(partialTicks as float);
ParameterTypeDescription
partialTicksfloatNessuna descrizione fornita

giveExperiencePoints

myMCPlayerEntity.giveExperiencePoints(p_195068_1_ as int);
ParameterTypeDescription
p195068_1intNessuna descrizione fornita

handleStatusUpdate

myMCPlayerEntity.handleStatusUpdate(id as byte);
ParameterTypeDescription
idbyteNessuna descrizione fornita

handleWaterMovement

Returns if this entity is in water and will end up adding the waters velocity to the entity

Restituisce un booleano

myMCPlayerEntity.handleWaterMovement();

hasCustomName

Restituisce un booleano

myMCPlayerEntity.hasCustomName();

hasNoGravity

Restituisce un booleano

myMCPlayerEntity.hasNoGravity();

hasPermissionLevel

Restituisce un booleano

myMCPlayerEntity.hasPermissionLevel(p_211513_1_ as int);
ParameterTypeDescription
p211513_1intNessuna descrizione fornita

hasReducedDebug

Whether the "reducedDebugInfo" option is active for this player.

Restituisce un booleano

myMCPlayerEntity.hasReducedDebug();

hashCode

Restituisce un intero

myMCPlayerEntity.hashCode();

heal

Heal living entity (param: amount of half-hearts)

myMCPlayerEntity.heal(healAmount as float);
ParameterTypeDescription
healAmountfloatNessuna descrizione fornita

ignoreItemEntityData

Controlla se i giocatori possono sfruttare questa entità per accedere sia direttamente sia indirettamente a comandi operatore (livello di permesso 2), come per esempio give o setblock. A similar method exists for entities at {@link net.minecraft.tileentity.TileEntity#onlyOpsCanSetNbt()}.

For example, {@link net.minecraft.entity.item.EntityMinecartCommandBlock#ignoreItemEntityData() command block minecarts} and {@link net.minecraft.entity.item.EntityMinecartMobSpawner#ignoreItemEntityData() mob spawner minecarts} (spawning command block minecarts or drops) are considered accessible.

Returns: true if this entity offers ways for unauthorized players to use restricted commands

Restituisce un booleano

myMCPlayerEntity.ignoreItemEntityData();

isActiveItemStackBlocking

Restituisce un booleano

myMCPlayerEntity.isActiveItemStackBlocking();

isAddedToWorld

Restituisce un booleano

myMCPlayerEntity.isAddedToWorld();

isAlive

Returns true if the entity has not been .

Restituisce un booleano

myMCPlayerEntity.isAlive();

isAllowEdit

Restituisce un booleano

myMCPlayerEntity.isAllowEdit();

isBeingRidden

If at least 1 entity is riding this one

Restituisce un booleano

myMCPlayerEntity.isBeingRidden();

isBurning

Returns true if the entity is on fire. Used by render to add the fire effect on rendering.

Restituisce un booleano

myMCPlayerEntity.isBurning();

isChild

If Animal, checks if the age timer is negative

Restituisce un booleano

myMCPlayerEntity.isChild();

isCreative

Restituisce un booleano

myMCPlayerEntity.isCreative();

isCustomNameVisible

Restituisce un booleano

myMCPlayerEntity.isCustomNameVisible();

isElytraFlying

Restituisce un booleano

myMCPlayerEntity.isElytraFlying();

isEntityInsideOpaqueBlock

Checks if this entity is inside of an opaque block

Restituisce un booleano

myMCPlayerEntity.isEntityInsideOpaqueBlock();

isEntityUndead

Returns true if this entity is undead.

Restituisce un booleano

myMCPlayerEntity.isEntityUndead();

isGlowing

Restituisce un booleano

myMCPlayerEntity.isGlowing();

isHandActive

Restituisce un booleano

myMCPlayerEntity.isHandActive();

isImmuneToExplosions

Restituisce un booleano

myMCPlayerEntity.isImmuneToExplosions();

isImmuneToFire

Restituisce un booleano

myMCPlayerEntity.isImmuneToFire();

isInLava

Restituisce un booleano

myMCPlayerEntity.isInLava();

isInRangeToRender3d

Restituisce un booleano

myMCPlayerEntity.isInRangeToRender3d(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

isInRangeToRenderDist

Checks if the entity is in range to render.

Restituisce un booleano

myMCPlayerEntity.isInRangeToRenderDist(distance as double);
ParameterTypeDescription
distancedoubleNessuna descrizione fornita

isInWater

Checks if this entity is inside water (if inWater field is true as a result of handleWaterMovement() returning true)

Restituisce un booleano

myMCPlayerEntity.isInWater();

isInWaterOrBubbleColumn

Restituisce un booleano

myMCPlayerEntity.isInWaterOrBubbleColumn();

isInWaterRainOrBubbleColumn

Restituisce un booleano

myMCPlayerEntity.isInWaterRainOrBubbleColumn();

isInvisible

Restituisce un booleano

myMCPlayerEntity.isInvisible();

isInvisibleToPlayer

Only used by renderer in EntityLivingBase subclasses. Determines if an entity is visible or not to a specific player, if the entity is normally invisible. For EntityLivingBase subclasses, returning false when invisible will render the entity semi-transparent.

Restituisce un booleano

myMCPlayerEntity.isInvisibleToPlayer(player as crafttweaker.api.entity.player.MCPlayerEntity);
ParameterTypeDescription
playercrafttweaker.api.entity.player.MCPlayerEntityNessuna descrizione fornita

isInvulnerable

Restituisce un booleano

myMCPlayerEntity.isInvulnerable();

isLiving

Restituisce un booleano

myMCPlayerEntity.isLiving();

isNonBoss

Returns false if this Entity is a boss, true otherwise.

Restituisce un booleano

myMCPlayerEntity.isNonBoss();

isOffsetPositionInLiquid

Checks if the offset position from the entity's current position is inside of a liquid.

Restituisce un booleano

myMCPlayerEntity.isOffsetPositionInLiquid(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

isOnLadder

Returns true if this entity should move as if it were on a ladder (either because it's actually on a ladder, or for AI reasons)

Restituisce un booleano

myMCPlayerEntity.isOnLadder();

isOnePlayerRiding

Restituisce un booleano

myMCPlayerEntity.isOnePlayerRiding();

isPassenger

Restituisce un booleano

myMCPlayerEntity.isPassenger();

isPlayerFullyAsleep

Returns whether or not the player is asleep and the screen has fully faded.

Restituisce un booleano

myMCPlayerEntity.isPlayerFullyAsleep();

isPotionActive

Restituisce un booleano

myMCPlayerEntity.isPotionActive(potionIn as crafttweaker.api.potion.MCPotionEffect);
ParameterTypeDescription
potionIncrafttweaker.api.potion.MCPotionEffectNessuna descrizione fornita

isPotionApplicable

Restituisce un booleano

myMCPlayerEntity.isPotionApplicable(potioneffectIn as crafttweaker.api.potion.MCPotionEffectInstance);
ParameterTypeDescription
potioneffectIncrafttweaker.api.potion.MCPotionEffectInstanceNessuna descrizione fornita

isPushedByWater

Restituisce un booleano

myMCPlayerEntity.isPushedByWater();

isServerWorld

Returns whether the entity is in a server world

Restituisce un booleano

myMCPlayerEntity.isServerWorld();

isSilent

Returns: True if this entity will not play sounds

Restituisce un booleano

myMCPlayerEntity.isSilent();

isSleeping

Returns whether player is sleeping or not

Restituisce un booleano

myMCPlayerEntity.isSleeping();

isSneaking

Returns if this entity is sneaking.

Restituisce un booleano

myMCPlayerEntity.isSneaking();

isSpawnForced

Restituisce un booleano

myMCPlayerEntity.isSpawnForced();

isSpectator

Returns true if the player is in spectator mode.

Restituisce un booleano

myMCPlayerEntity.isSpectator();

isSpinAttacking

Restituisce un booleano

myMCPlayerEntity.isSpinAttacking();

isSprinting

Get if the Entity is sprinting.

Restituisce un booleano

myMCPlayerEntity.isSprinting();

isSwimming

Restituisce un booleano

myMCPlayerEntity.isSwimming();

isUser

returns true if this is an EntityPlayerSP, or the logged in player.

Restituisce un booleano

myMCPlayerEntity.isUser();

isWet

Checks if this entity is either in water or on an open air block in rain (used in wolves).

Restituisce un booleano

myMCPlayerEntity.isWet();

jump

Causes this entity to do an upwards motion (jumping).

myMCPlayerEntity.jump();

livingTick

Called frequently so the entity can update its state every tick as required. For example, zombies and skeletons use this to react to sunlight and start to burn.

myMCPlayerEntity.livingTick();

moveToBlockPosAndAngles

myMCPlayerEntity.moveToBlockPosAndAngles(pos as crafttweaker.api.util.BlockPos, rotationYawIn as float, rotationPitchIn as float);
ParameterTypeDescription
poscrafttweaker.api.util.BlockPosNessuna descrizione fornita
rotationYawInfloatNessuna descrizione fornita
rotationPitchInfloatNessuna descrizione fornita

onAddedToWorld

myMCPlayerEntity.onAddedToWorld();

onCollideWithPlayer

Called by a player entity when they collide with an entity

myMCPlayerEntity.onCollideWithPlayer(entityIn as crafttweaker.api.entity.player.MCPlayerEntity);
ParameterTypeDescription
entityIncrafttweaker.api.entity.player.MCPlayerEntityNessuna descrizione fornita

onEnchant

myMCPlayerEntity.onEnchant(enchantedItem as crafttweaker.api.item.IItemStack, cost as int);
ParameterTypeDescription
enchantedItemcrafttweaker.api.item.IItemStackNessuna descrizione fornita
costintNessuna descrizione fornita

onEnterBubbleColumn

myMCPlayerEntity.onEnterBubbleColumn(downwards as boolean);
ParameterTypeDescription
downwardsbooleanNessuna descrizione fornita

onEnterBubbleColumnWithAirAbove

myMCPlayerEntity.onEnterBubbleColumnWithAirAbove(downwards as boolean);
ParameterTypeDescription
downwardsbooleanNessuna descrizione fornita

onKillCommand

Called by the /kill command.

myMCPlayerEntity.onKillCommand();

onRemovedFromWorld

myMCPlayerEntity.onRemovedFromWorld();

performHurtAnimation

Setups the entity to do the hurt animation. Only used by packets in multiplayer.

myMCPlayerEntity.performHurtAnimation();

preparePlayerToSpawn

Keeps moving the entity up so it isn't colliding with blocks and other requirements for this entity to be spawned (only actually used on players though its also on Entity)

myMCPlayerEntity.preparePlayerToSpawn();

recalculateSize

myMCPlayerEntity.recalculateSize();

remove

myMCPlayerEntity.remove();
myMCPlayerEntity.remove(keepData as boolean);
ParameterTypeDescription
keepDatabooleanNessuna descrizione fornita

removeActivePotionEffect

Returns crafttweaker.api.potion.MCPotionEffectInstance

myMCPlayerEntity.removeActivePotionEffect(arg0 as crafttweaker.api.potion.MCPotionEffect);
ParameterTypeDescription
arg0crafttweaker.api.potion.MCPotionEffectNessuna descrizione fornita

removePassengers

Dismounts all entities riding this entity from this entity.

myMCPlayerEntity.removePassengers();

removePotionEffect

Restituisce un booleano

myMCPlayerEntity.removePotionEffect(effectIn as crafttweaker.api.potion.MCPotionEffect);
ParameterTypeDescription
effectIncrafttweaker.api.potion.MCPotionEffectNessuna descrizione fornita

removeTag

Restituisce un booleano

myMCPlayerEntity.removeTag(tag as String);
ParameterTypeDescription
tagStringNessuna descrizione fornita

replaceItemInInventory

Restituisce un booleano

myMCPlayerEntity.replaceItemInInventory(inventorySlot as int, itemStackIn as crafttweaker.api.item.IItemStack);
ParameterTypeDescription
inventorySlotintNessuna descrizione fornita
itemStackIncrafttweaker.api.item.IItemStackNessuna descrizione fornita

resetActiveHand

myMCPlayerEntity.resetActiveHand();

resetCooldown

myMCPlayerEntity.resetCooldown();

resetPositionToBB

Resets the entity's position to the center (planar) and bottom (vertical) points of its bounding box.

myMCPlayerEntity.resetPositionToBB();

respawnPlayer

myMCPlayerEntity.respawnPlayer();

revive

myMCPlayerEntity.revive();

rotateTowards

myMCPlayerEntity.rotateTowards(yaw as double, pitch as double);
ParameterTypeDescription
yawdoubleNessuna descrizione fornita
pitchdoubleNessuna descrizione fornita

sendEndCombat

Sends an END_COMBAT packet to the client

myMCPlayerEntity.sendEndCombat();

sendEnterCombat

Sends an ENTER_COMBAT packet to the client

myMCPlayerEntity.sendEnterCombat();

sendPlayerAbilities

Sends the player's abilities to the server (if there is one).

myMCPlayerEntity.sendPlayerAbilities();

setAIMoveSpeed

set the movespeed used for the new AI system

myMCPlayerEntity.setAIMoveSpeed(speedIn as float);
ParameterTypeDescription
speedInfloatNessuna descrizione fornita

setAbsorptionAmount

myMCPlayerEntity.setAbsorptionAmount(amount as float);
ParameterTypeDescription
amountfloatNessuna descrizione fornita

setAir

myMCPlayerEntity.setAir(air as int);
ParameterTypeDescription
airintNessuna descrizione fornita

setArrowCountInEntity

myMCPlayerEntity.setArrowCountInEntity(count as int);
ParameterTypeDescription
countintNessuna descrizione fornita

setBedPosition

myMCPlayerEntity.setBedPosition(p_213369_1_ as crafttweaker.api.util.BlockPos);
ParameterTypeDescription
p213369_1crafttweaker.api.util.BlockPosNessuna descrizione fornita

setCustomNameVisible

myMCPlayerEntity.setCustomNameVisible(alwaysRenderNameTag as boolean);
ParameterTypeDescription
alwaysRenderNameTagbooleanNessuna descrizione fornita

setEntityId

myMCPlayerEntity.setEntityId(id as int);
ParameterTypeDescription
idintNessuna descrizione fornita

setFire

Sets entity to burn for x amount of seconds, cannot lower amount of existing fire.

myMCPlayerEntity.setFire(seconds as int);
ParameterTypeDescription
secondsintNessuna descrizione fornita

setFireTimer

myMCPlayerEntity.setFireTimer(p_223308_1_ as int);
ParameterTypeDescription
p223308_1intNessuna descrizione fornita

setGlowing

myMCPlayerEntity.setGlowing(glowingIn as boolean);
ParameterTypeDescription
glowingInbooleanNessuna descrizione fornita

setHeadRotation

myMCPlayerEntity.setHeadRotation(yaw as float, pitch as int);
ParameterTypeDescription
yawfloatNessuna descrizione fornita
pitchintNessuna descrizione fornita

setHealth

myMCPlayerEntity.setHealth(health as float);
ParameterTypeDescription
healthfloatNessuna descrizione fornita

setIdleTime

myMCPlayerEntity.setIdleTime(idleTimeIn as int);
ParameterTypeDescription
idleTimeInintNessuna descrizione fornita

setInLava

myMCPlayerEntity.setInLava();

setInvisible

myMCPlayerEntity.setInvisible(invisible as boolean);
ParameterTypeDescription
invisiblebooleanNessuna descrizione fornita

setInvulnerable

Sets whether this Entity is invulnerable.

myMCPlayerEntity.setInvulnerable(isInvulnerable as boolean);
ParameterTypeDescription
isInvulnerablebooleanNessuna descrizione fornita

setJumping

myMCPlayerEntity.setJumping(jumping as boolean);
ParameterTypeDescription
jumpingbooleanNessuna descrizione fornita

setLocationAndAngles

Sets the location and Yaw/Pitch of an entity in the world

myMCPlayerEntity.setLocationAndAngles(x as double, y as double, z as double, yaw as float, pitch as float);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita
yawfloatNessuna descrizione fornita
pitchfloatNessuna descrizione fornita

setMotion

myMCPlayerEntity.setMotion(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

setNoGravity

myMCPlayerEntity.setNoGravity(noGravity as boolean);
ParameterTypeDescription
noGravitybooleanNessuna descrizione fornita

setPartying

Called when a record starts or stops playing. Used to make parrots start or stop partying.

myMCPlayerEntity.setPartying(pos as crafttweaker.api.util.BlockPos, isPartying as boolean);
ParameterTypeDescription
poscrafttweaker.api.util.BlockPosNessuna descrizione fornita
isPartyingbooleanNessuna descrizione fornita

setPortal

Marks the entity as being inside a portal, activating teleportation logic in onEntityUpdate() in the following tick(s).

myMCPlayerEntity.setPortal(pos as crafttweaker.api.util.BlockPos);
ParameterTypeDescription
poscrafttweaker.api.util.BlockPosNessuna descrizione fornita

setPosition

Sets the x,y,z of the entity from the given parameters. Also seems to set up a bounding box.

myMCPlayerEntity.setPosition(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

setPositionAndRotation

Sets position and rotation, clamping and wrapping params to valid values. Used by network code.

myMCPlayerEntity.setPositionAndRotation(x as double, y as double, z as double, yaw as float, pitch as float);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita
yawfloatNessuna descrizione fornita
pitchfloatNessuna descrizione fornita

setPositionAndRotationDirect

Sets a target for the client to interpolate towards over the next few ticks

myMCPlayerEntity.setPositionAndRotationDirect(x as double, y as double, z as double, yaw as float, pitch as float, posRotationIncrements as int, teleport as boolean);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita
yawfloatNessuna descrizione fornita
pitchfloatNessuna descrizione fornita
posRotationIncrementsintNessuna descrizione fornita
teleportbooleanNessuna descrizione fornita

setPositionAndUpdate

Sets the position of the entity and updates the 'last' variables

myMCPlayerEntity.setPositionAndUpdate(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

setPositionNonDirty

Restituisce un booleano

myMCPlayerEntity.setPositionNonDirty();

setReducedDebug

myMCPlayerEntity.setReducedDebug(reducedDebug as boolean);
ParameterTypeDescription
reducedDebugbooleanNessuna descrizione fornita

setRenderYawOffset

Set the render yaw offset

myMCPlayerEntity.setRenderYawOffset(offset as float);
ParameterTypeDescription
offsetfloatNessuna descrizione fornita

setRotationYawHead

Sets the head's yaw rotation of the entity.

myMCPlayerEntity.setRotationYawHead(rotation as float);
ParameterTypeDescription
rotationfloatNessuna descrizione fornita

setScore

Set player's score

myMCPlayerEntity.setScore(scoreIn as int);
ParameterTypeDescription
scoreInintNessuna descrizione fornita

setSilent

When set to true the entity will not play sounds.

myMCPlayerEntity.setSilent(isSilent as boolean);
ParameterTypeDescription
isSilentbooleanNessuna descrizione fornita

setSneaking

Sets the sneaking flag.

myMCPlayerEntity.setSneaking(sneaking as boolean);
ParameterTypeDescription
sneakingbooleanNessuna descrizione fornita

setSpawnPoint

myMCPlayerEntity.setSpawnPoint(pos as crafttweaker.api.util.BlockPos, forced as boolean);
ParameterTypeDescription
poscrafttweaker.api.util.BlockPosNessuna descrizione fornita
forcedbooleanNessuna descrizione fornita

setSprinting

Set sprinting switch for Entity.

myMCPlayerEntity.setSprinting(sprinting as boolean);
ParameterTypeDescription
sprintingbooleanNessuna descrizione fornita

setSwimming

myMCPlayerEntity.setSwimming(p_204711_1_ as boolean);
ParameterTypeDescription
p204711_1booleanNessuna descrizione fornita

setVelocity

Updates the entity motion clientside, called by packets from the server

myMCPlayerEntity.setVelocity(x as double, y as double, z as double);
ParameterTypeDescription
xdoubleNessuna descrizione fornita
ydoubleNessuna descrizione fornita
zdoubleNessuna descrizione fornita

shouldHeal

Checks if the player's health is not full and not zero.

Restituisce un booleano

myMCPlayerEntity.shouldHeal();

shouldReceiveErrors

Restituisce un booleano

myMCPlayerEntity.shouldReceiveErrors();

shouldReceiveFeedback

Restituisce un booleano

myMCPlayerEntity.shouldReceiveFeedback();

shouldRenderSneaking

Restituisce un booleano

myMCPlayerEntity.shouldRenderSneaking();

shouldRiderFaceForward

Returns true if the entity's rider (EntityPlayer) should face forward when mounted. currently only used in vanilla code by pigs.

Restituisce un booleano

myMCPlayerEntity.shouldRiderFaceForward(player as crafttweaker.api.entity.player.MCPlayerEntity);
ParameterTypeDescription
playercrafttweaker.api.entity.player.MCPlayerEntityThe player who is riding the entity.

shouldRiderSit

Restituisce un booleano

myMCPlayerEntity.shouldRiderSit();

spawnRunningParticles

Attempts to create sprinting particles if the entity is sprinting and not in water.

myMCPlayerEntity.spawnRunningParticles();

spawnSweepParticles

myMCPlayerEntity.spawnSweepParticles();

startSleeping

myMCPlayerEntity.startSleeping(p_213342_1_ as crafttweaker.api.util.BlockPos);
ParameterTypeDescription
p213342_1crafttweaker.api.util.BlockPosNessuna descrizione fornita

startSpinAttack

myMCPlayerEntity.startSpinAttack(p_204803_1_ as int);
ParameterTypeDescription
p204803_1intNessuna descrizione fornita

stopActiveHand

myMCPlayerEntity.stopActiveHand();

stopRiding

Dismounts this entity from the entity it is riding.

myMCPlayerEntity.stopRiding();

teleportKeepLoaded

myMCPlayerEntity.teleportKeepLoaded(p_223102_1_ as double, p_223102_3_ as double, p_223102_5_ as double);
ParameterTypeDescription
p223102_1doubleNessuna descrizione fornita
p223102_3doubleNessuna descrizione fornita
p223102_5doubleNessuna descrizione fornita

tick

Called to update the entity's position/logic.

myMCPlayerEntity.tick();

toString

Ritorna una stringa

myMCPlayerEntity.toString();

updateRidden

Handles updating while riding another entity

myMCPlayerEntity.updateRidden();

updateSwimming

myMCPlayerEntity.updateSwimming();

wakeUp

myMCPlayerEntity.wakeUp();

wakeUpPlayer

Wake up the player if they're sleeping.

myMCPlayerEntity.wakeUpPlayer(immediately as boolean, updateWorldFlag as boolean, setSpawn as boolean);
ParameterTypeDescription
immediatelybooleanNessuna descrizione fornita
updateWorldFlagbooleanNessuna descrizione fornita
setSpawnbooleanNessuna descrizione fornita

xpBarCap

This method returns the cap amount of experience that the experience bar can hold. With each level, the experience cap on the player's experience bar is raised by 10.

Restituisce un intero

myMCPlayerEntity.xpBarCap();