PlayerSkinComponent class
Пакет: com.hypixel.hytale.server.core.modules.entity.player
Файл: com/hypixel/hytale/server/core/modules/entity/player/PlayerSkinComponent.java
implements: Component<EntityStore>
Поля (1)
| Модификаторы | Тип | Имя |
|---|---|---|
|
boolean |
var1 |
Методы (2)
| Модификаторы | Возврат | Сигнатура |
|---|---|---|
public |
boolean |
consumeNetworkOutdatedboolean consumeNetworkOutdated() |
public |
void |
setNetworkOutdatedvoid setNetworkOutdated() |
Исходный код
Показать/скрыть
class="kw">package com.hypixel.hytale.server.core.modules.entity.player;
class="kw">import com.hypixel.hytale.component.Component;
class="kw">import com.hypixel.hytale.component.ComponentType;
class="kw">import com.hypixel.hytale.protocol.PlayerSkin;
class="kw">import com.hypixel.hytale.server.core.modules.entity.EntityModule;
class="kw">import com.hypixel.hytale.server.core.universe.world.storage.EntityStore;
class="kw">import javax.annotation.Nonnull;
class="kw">public class PlayerSkinComponent class="kw">implements Component<EntityStore> {
@Nonnull
class="kw">private class="kw">final PlayerSkin playerSkin;
class="kw">private boolean isNetworkOutdated = true;
@Nonnull
class="kw">public class="kw">static ComponentType<EntityStore, PlayerSkinComponent> getComponentType() {
class="kw">return EntityModule.get().getPlayerSkinComponentType();
}
class="kw">public PlayerSkinComponent(@Nonnull PlayerSkin var1) {
this.playerSkin = var1;
}
class="kw">public boolean consumeNetworkOutdated() {
boolean var1 = this.isNetworkOutdated;
this.isNetworkOutdated = false;
class="kw">return var1;
}
@Nonnull
class="kw">public PlayerSkin getPlayerSkin() {
class="kw">return this.playerSkin;
}
class="kw">public void setNetworkOutdated() {
this.isNetworkOutdated = true;
}
@Nonnull
@Override
class="kw">public Component<EntityStore> clone() {
class="kw">return new PlayerSkinComponent(this.playerSkin);
}
}