-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
create a neoforge registry for factions
- adapt faction holders - add faction tags
- Loading branch information
1 parent
3eeef36
commit 725f46c
Showing
217 changed files
with
1,499 additions
and
1,105 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
src/api/java/de/teamlapen/vampirism/api/VampirismFactions.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package de.teamlapen.vampirism.api; | ||
|
||
import de.teamlapen.vampirism.api.entity.factions.IPlayableFaction; | ||
import de.teamlapen.vampirism.api.entity.player.hunter.IHunterPlayer; | ||
import de.teamlapen.vampirism.api.entity.player.vampire.IVampirePlayer; | ||
import de.teamlapen.vampirism.api.registries.DeferredFaction; | ||
import net.minecraft.resources.ResourceLocation; | ||
|
||
import static de.teamlapen.vampirism.api.APIUtil.*; | ||
|
||
public class VampirismFactions { | ||
public static final DeferredFaction<IVampirePlayer, IPlayableFaction<IVampirePlayer>> VAMPIRE = factionHolder(Keys.VAMPIRE); | ||
public static final DeferredFaction<IHunterPlayer, IPlayableFaction<IHunterPlayer>> HUNTER = factionHolder(Keys.HUNTER); | ||
|
||
public static class Keys { | ||
public static final ResourceLocation VAMPIRE = new ResourceLocation(VReference.MODID, "vampire"); | ||
public static final ResourceLocation HUNTER = new ResourceLocation(VReference.MODID, "hunter"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
src/api/java/de/teamlapen/vampirism/api/VampirismTags.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package de.teamlapen.vampirism.api; | ||
|
||
import de.teamlapen.vampirism.api.entity.factions.IFaction; | ||
import net.minecraft.resources.ResourceLocation; | ||
import net.minecraft.tags.TagKey; | ||
import org.jetbrains.annotations.NotNull; | ||
|
||
public class VampirismTags { | ||
|
||
public static class Factions { | ||
public static final TagKey<IFaction<?>> ALL_FACTIONS = tag("all"); | ||
public static final TagKey<IFaction<?>> IS_HUNTER = tag("is_hunter"); | ||
public static final TagKey<IFaction<?>> IS_VAMPIRE = tag("is_vampire"); | ||
|
||
private static @NotNull TagKey<IFaction<?>> tag(@NotNull String name) { | ||
return TagKey.create(VampirismRegistries.Keys.FACTION, new ResourceLocation(VReference.MODID, name)); | ||
} | ||
|
||
} | ||
} |
9 changes: 5 additions & 4 deletions
9
src/api/java/de/teamlapen/vampirism/api/entity/factions/IDisguise.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.