PlacedByInteractionComponent class
Пакет: com.hypixel.hytale.server.core.modules.interaction.components
Файл: com/hypixel/hytale/server/core/modules/interaction/components/PlacedByInteractionComponent.java
implements: Component<ChunkStore>
Поля (2)
| Модификаторы | Тип | Имя |
|---|---|---|
final |
BuilderCodec<PlacedByInteractionComponent> |
CODEC |
|
PlacedByInteractionComponent |
var1 |
Методы (2)
| Модификаторы | Возврат | Сигнатура |
|---|---|---|
static |
ComponentType<ChunkStore, PlacedByInteractionComponent> |
getComponentTypeComponentType<ChunkStore, PlacedByInteractionComponent> getComponentType() |
public |
UUID |
getWhoPlacedUuidUUID getWhoPlacedUuid() |
Исходный код
Показать/скрыть
class="kw">package com.hypixel.hytale.server.core.modules.interaction.components;
class="kw">import com.hypixel.hytale.codec.Codec;
class="kw">import com.hypixel.hytale.codec.KeyedCodec;
class="kw">import com.hypixel.hytale.codec.builder.BuilderCodec;
class="kw">import com.hypixel.hytale.component.Component;
class="kw">import com.hypixel.hytale.component.ComponentType;
class="kw">import com.hypixel.hytale.server.core.modules.interaction.InteractionModule;
class="kw">import com.hypixel.hytale.server.core.universe.world.storage.ChunkStore;
class="kw">import java.util.UUID;
class="kw">import javax.annotation.Nullable;
class="kw">public class PlacedByInteractionComponent class="kw">implements Component<ChunkStore> {
class="kw">public class="kw">static class="kw">final BuilderCodec<PlacedByInteractionComponent> CODEC = BuilderCodec.builder(
PlacedByInteractionComponent.class, PlacedByInteractionComponent::new
)
.appendInherited(
new KeyedCodec<>("WhoPlacedUuid", Codec.UUID_BINARY),
(var0, var1) -> var0.whoPlacedUuid = var1,
var0 -> var0.whoPlacedUuid,
(var0, var1) -> var0.whoPlacedUuid = var1.whoPlacedUuid
)
.add()
.build();
class="kw">private UUID whoPlacedUuid;
class="kw">public class="kw">static ComponentType<ChunkStore, PlacedByInteractionComponent> getComponentType() {
class="kw">return InteractionModule.get().getPlacedByComponentType();
}
class="kw">public PlacedByInteractionComponent() {
}
class="kw">public PlacedByInteractionComponent(UUID var1) {
this.whoPlacedUuid = var1;
}
class="kw">public UUID getWhoPlacedUuid() {
class="kw">return this.whoPlacedUuid;
}
@Nullable
@Override
class="kw">public Component<ChunkStore> clone() {
PlacedByInteractionComponent var1 = new PlacedByInteractionComponent();
var1.whoPlacedUuid = this.whoPlacedUuid;
class="kw">return var1;
}
}