Skip to content

Commit

Permalink
chore: update api data types for 1.21.2 content
Browse files Browse the repository at this point in the history
Signed-off-by: Gabriel Harris-Rouquette <gabizou@me.com>
  • Loading branch information
gabizou committed Oct 15, 2024
2 parents 2a43df0 + 196f5d5 commit 7f4b70e
Show file tree
Hide file tree
Showing 31 changed files with 673 additions and 50 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public final class Triggers {

public static final DefaultedRegistryReference<Trigger<?>> ITEM_USED_ON_BLOCK = Triggers.key(ResourceKey.minecraft("item_used_on_block"));

public static final DefaultedRegistryReference<Trigger<?>> KILLED_BY_CROSSBOW = Triggers.key(ResourceKey.minecraft("killed_by_crossbow"));
public static final DefaultedRegistryReference<Trigger<?>> KILLED_BY_ARROW = Triggers.key(ResourceKey.minecraft("killed_by_arrow"));

public static final DefaultedRegistryReference<Trigger<?>> KILL_MOB_NEAR_SCULK_CATALYST = Triggers.key(ResourceKey.minecraft("kill_mob_near_sculk_catalyst"));

Expand Down
98 changes: 98 additions & 0 deletions src/main/java/org/spongepowered/api/block/BlockTypes.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
*/
package org.spongepowered.api.block;

import org.jetbrains.annotations.ApiStatus;
import org.spongepowered.api.ResourceKey;
import org.spongepowered.api.Sponge;
import org.spongepowered.api.registry.DefaultedRegistryReference;
Expand All @@ -32,6 +33,7 @@
import org.spongepowered.api.registry.RegistryScope;
import org.spongepowered.api.registry.RegistryScopes;
import org.spongepowered.api.registry.RegistryTypes;
import org.spongepowered.api.util.annotation.Experimental;

/**
* <!-- This file is automatically generated. Any manual changes will be overwritten. -->
Expand Down Expand Up @@ -496,6 +498,10 @@ public final class BlockTypes {

public static final DefaultedRegistryReference<BlockType> CRAFTING_TABLE = BlockTypes.key(ResourceKey.minecraft("crafting_table"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> CREAKING_HEART = BlockTypes.key(ResourceKey.minecraft("creaking_heart"));

public static final DefaultedRegistryReference<BlockType> CREEPER_HEAD = BlockTypes.key(ResourceKey.minecraft("creeper_head"));

public static final DefaultedRegistryReference<BlockType> CREEPER_WALL_HEAD = BlockTypes.key(ResourceKey.minecraft("creeper_wall_head"));
Expand Down Expand Up @@ -1336,6 +1342,86 @@ public final class BlockTypes {

public static final DefaultedRegistryReference<BlockType> PACKED_MUD = BlockTypes.key(ResourceKey.minecraft("packed_mud"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_HANGING_MOSS = BlockTypes.key(ResourceKey.minecraft("pale_hanging_moss"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_MOSS_BLOCK = BlockTypes.key(ResourceKey.minecraft("pale_moss_block"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_MOSS_CARPET = BlockTypes.key(ResourceKey.minecraft("pale_moss_carpet"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_BUTTON = BlockTypes.key(ResourceKey.minecraft("pale_oak_button"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_DOOR = BlockTypes.key(ResourceKey.minecraft("pale_oak_door"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_FENCE = BlockTypes.key(ResourceKey.minecraft("pale_oak_fence"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_FENCE_GATE = BlockTypes.key(ResourceKey.minecraft("pale_oak_fence_gate"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_HANGING_SIGN = BlockTypes.key(ResourceKey.minecraft("pale_oak_hanging_sign"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_LEAVES = BlockTypes.key(ResourceKey.minecraft("pale_oak_leaves"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_LOG = BlockTypes.key(ResourceKey.minecraft("pale_oak_log"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_PLANKS = BlockTypes.key(ResourceKey.minecraft("pale_oak_planks"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_PRESSURE_PLATE = BlockTypes.key(ResourceKey.minecraft("pale_oak_pressure_plate"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_SAPLING = BlockTypes.key(ResourceKey.minecraft("pale_oak_sapling"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_SIGN = BlockTypes.key(ResourceKey.minecraft("pale_oak_sign"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_SLAB = BlockTypes.key(ResourceKey.minecraft("pale_oak_slab"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_STAIRS = BlockTypes.key(ResourceKey.minecraft("pale_oak_stairs"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_TRAPDOOR = BlockTypes.key(ResourceKey.minecraft("pale_oak_trapdoor"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_WALL_HANGING_SIGN = BlockTypes.key(ResourceKey.minecraft("pale_oak_wall_hanging_sign"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_WALL_SIGN = BlockTypes.key(ResourceKey.minecraft("pale_oak_wall_sign"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> PALE_OAK_WOOD = BlockTypes.key(ResourceKey.minecraft("pale_oak_wood"));

public static final DefaultedRegistryReference<BlockType> PEARLESCENT_FROGLIGHT = BlockTypes.key(ResourceKey.minecraft("pearlescent_froglight"));

public static final DefaultedRegistryReference<BlockType> PEONY = BlockTypes.key(ResourceKey.minecraft("peony"));
Expand Down Expand Up @@ -1502,6 +1588,10 @@ public final class BlockTypes {

public static final DefaultedRegistryReference<BlockType> POTTED_OXEYE_DAISY = BlockTypes.key(ResourceKey.minecraft("potted_oxeye_daisy"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> POTTED_PALE_OAK_SAPLING = BlockTypes.key(ResourceKey.minecraft("potted_pale_oak_sapling"));

public static final DefaultedRegistryReference<BlockType> POTTED_PINK_TULIP = BlockTypes.key(ResourceKey.minecraft("potted_pink_tulip"));

public static final DefaultedRegistryReference<BlockType> POTTED_POPPY = BlockTypes.key(ResourceKey.minecraft("potted_poppy"));
Expand Down Expand Up @@ -1864,6 +1954,14 @@ public final class BlockTypes {

public static final DefaultedRegistryReference<BlockType> STRIPPED_OAK_WOOD = BlockTypes.key(ResourceKey.minecraft("stripped_oak_wood"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> STRIPPED_PALE_OAK_LOG = BlockTypes.key(ResourceKey.minecraft("stripped_pale_oak_log"));

@Experimental("winter_drop")
@ApiStatus.Experimental
public static final DefaultedRegistryReference<BlockType> STRIPPED_PALE_OAK_WOOD = BlockTypes.key(ResourceKey.minecraft("stripped_pale_oak_wood"));

public static final DefaultedRegistryReference<BlockType> STRIPPED_SPRUCE_LOG = BlockTypes.key(ResourceKey.minecraft("stripped_spruce_log"));

public static final DefaultedRegistryReference<BlockType> STRIPPED_SPRUCE_WOOD = BlockTypes.key(ResourceKey.minecraft("stripped_spruce_wood"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,8 @@ public final class BlockEntityTypes {

public static final DefaultedRegistryReference<BlockEntityType> CRAFTER = BlockEntityTypes.key(ResourceKey.minecraft("crafter"));

public static final DefaultedRegistryReference<BlockEntityType> CREAKING_HEART = BlockEntityTypes.key(ResourceKey.minecraft("creaking_heart"));

public static final DefaultedRegistryReference<BlockEntityType> DAYLIGHT_DETECTOR = BlockEntityTypes.key(ResourceKey.minecraft("daylight_detector"));

public static final DefaultedRegistryReference<BlockEntityType> DECORATED_POT = BlockEntityTypes.key(ResourceKey.minecraft("decorated_pot"));
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/*
* This file is part of SpongeAPI, licensed under the MIT License (MIT).
*
* Copyright (c) SpongePowered <https://www.spongepowered.org>
* Copyright (c) contributors
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
package org.spongepowered.api.block.entity;

import org.jetbrains.annotations.ApiStatus;
import org.spongepowered.api.util.annotation.Experimental;

/**
* Represents a CreakingHeart block entity.
*
* @see <a href="https://minecraft.wiki/Creaking_Heart">Creaking Heart</a>
*/
@Experimental("winter_drop")
@ApiStatus.Experimental
public interface CreakingHeart extends BlockEntity {

}
5 changes: 5 additions & 0 deletions src/main/java/org/spongepowered/api/data/BlockStateKeys.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import org.spongepowered.api.data.type.BellAttachmentType;
import org.spongepowered.api.data.type.ChestAttachmentType;
import org.spongepowered.api.data.type.ComparatorMode;
import org.spongepowered.api.data.type.CreakingHeart;
import org.spongepowered.api.data.type.DoorHinge;
import org.spongepowered.api.data.type.DripstoneSegment;
import org.spongepowered.api.data.type.InstrumentType;
Expand Down Expand Up @@ -116,6 +117,8 @@ public final class BlockStateKeys {

public static final Key<Value<Boolean>> CRAFTING = BlockStateKeys.key(ResourceKey.minecraft("property/crafting"), Boolean.class);

public static final Key<Value<CreakingHeart>> CREAKING = BlockStateKeys.key(ResourceKey.minecraft("property/creaking"), CreakingHeart.class);

public static final Key<Value<Integer>> DELAY = BlockStateKeys.key(ResourceKey.minecraft("property/delay"), Integer.class);

public static final Key<Value<Boolean>> DISARMED = BlockStateKeys.key(ResourceKey.minecraft("property/disarmed"), Boolean.class);
Expand Down Expand Up @@ -264,6 +267,8 @@ public final class BlockStateKeys {

public static final Key<Value<Tilt>> TILT = BlockStateKeys.key(ResourceKey.minecraft("property/tilt"), Tilt.class);

public static final Key<Value<Boolean>> TIP = BlockStateKeys.key(ResourceKey.minecraft("property/tip"), Boolean.class);

public static final Key<Value<TrialSpawnerState>> TRIAL_SPAWNER_STATE = BlockStateKeys.key(ResourceKey.minecraft("property/trial_spawner_state"), TrialSpawnerState.class);

public static final Key<Value<Boolean>> TRIGGERED = BlockStateKeys.key(ResourceKey.minecraft("property/triggered"), Boolean.class);
Expand Down
35 changes: 35 additions & 0 deletions src/main/java/org/spongepowered/api/data/type/CreakingHeart.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
/*
* This file is part of SpongeAPI, licensed under the MIT License (MIT).
*
* Copyright (c) SpongePowered <https://www.spongepowered.org>
* Copyright (c) contributors
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
package org.spongepowered.api.data.type;

import org.spongepowered.api.registry.DefaultedRegistryValue;
import org.spongepowered.api.registry.RegistryScope;
import org.spongepowered.api.registry.RegistryScopes;
import org.spongepowered.api.util.annotation.CatalogedBy;

@RegistryScopes(scopes = RegistryScope.GAME)
@CatalogedBy(CreakingHearts.class)
public interface CreakingHeart extends Comparable<CreakingHeart>, StringRepresentable, DefaultedRegistryValue {
}
44 changes: 44 additions & 0 deletions src/main/java/org/spongepowered/api/data/type/CreakingHearts.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/*
* This file is part of SpongeAPI, licensed under the MIT License (MIT).
*
* Copyright (c) SpongePowered <https://www.spongepowered.org>
* Copyright (c) contributors
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
package org.spongepowered.api.data.type;

import org.spongepowered.api.ResourceKey;
import org.spongepowered.api.Sponge;
import org.spongepowered.api.registry.DefaultedRegistryReference;
import org.spongepowered.api.registry.RegistryKey;
import org.spongepowered.api.registry.RegistryTypes;

public final class CreakingHearts {

public static final DefaultedRegistryReference<CreakingHeart> ACTIVE = CreakingHearts.key(ResourceKey.sponge("active"));

public static final DefaultedRegistryReference<CreakingHeart> DISABLED = CreakingHearts.key(ResourceKey.sponge("disabled"));

public static final DefaultedRegistryReference<CreakingHeart> DORMANT = CreakingHearts.key(ResourceKey.sponge("dormant"));

private static DefaultedRegistryReference<CreakingHeart> key(final ResourceKey location) {
return RegistryKey.of(RegistryTypes.CREAKING_HEART, location).asDefaultedReference(Sponge::game);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ public final class ParticleTypes {

public static final DefaultedRegistryReference<ParticleType> BLOCK = ParticleTypes.key(ResourceKey.minecraft("block"));

public static final DefaultedRegistryReference<ParticleType> BLOCK_CRUMBLE = ParticleTypes.key(ResourceKey.minecraft("block_crumble"));

public static final DefaultedRegistryReference<ParticleType> BLOCK_MARKER = ParticleTypes.key(ResourceKey.minecraft("block_marker"));

public static final DefaultedRegistryReference<ParticleType> BUBBLE = ParticleTypes.key(ResourceKey.minecraft("bubble"));
Expand Down Expand Up @@ -234,6 +236,8 @@ public final class ParticleTypes {

public static final DefaultedRegistryReference<ParticleType> TOTEM_OF_UNDYING = ParticleTypes.key(ResourceKey.minecraft("totem_of_undying"));

public static final DefaultedRegistryReference<ParticleType> TRAIL = ParticleTypes.key(ResourceKey.minecraft("trail"));

public static final DefaultedRegistryReference<ParticleType> TRIAL_OMEN = ParticleTypes.key(ResourceKey.minecraft("trial_omen"));

public static final DefaultedRegistryReference<ParticleType> TRIAL_SPAWNER_DETECTION = ParticleTypes.key(ResourceKey.minecraft("trial_spawner_detection"));
Expand Down
Loading

0 comments on commit 7f4b70e

Please sign in to comment.