Hostile Neural Networks

Hostile Neural Networks

7M Downloads

Allow one data model to represent multiple related/duplicate entity types

James103 opened this issue ยท 4 comments

commented

Currently, each data model can only represent one entity.
This is problematic as some mod packs (including one with both this mod and Tinkers' Construct) may have two or more entities that look similar, behave similar, and have similar drops to each other, or that are exactly the same except their type IDs are different.

For example, Tinkers' Construct allows slimes to spawn on special islands, but those slimes have the ID tconstruct:earth_slime for the green slimes that are similar in looks, drops, and behavior to the vanilla minecraft:slime.

To rectify this and allow unification, I propose allowing each entity model to map to a tag (group) of entities.

Example usage in datapack:
data/hostilenetworks/data_models/slime.json

{
	"type": "minecraft:slime",
	"tag": "#hostilenetworks:slimes",
	"name": "entity.minecraft.slime",
	...
}

data/hostilenetworks/tags/entity_types/slimes.json

{
	"replace": false,
	"values": {
		"minecraft:slime",
		{"id": "tconstruct:earth_slime", "required": "false"}
	}
}
commented

A main problem with this is how do you convey that information to the user - how can they discern that an earth slime falls under the category of slime?

commented

There could be info in the lore of the item that says something along the lines of:

Tier: Faulty
Data Collected: 0/6
Data Per Kill: 1
Simulation Cost: 160 FE/t
Species:
- Slime
- Slime

where the last three lines are newly added information.
(The earth slime from Tinkers' Construct is actually called "Slime", but they're still a different ID compared to vanilla slimes)

The entity type rendered in the model could cycle through the represented species at a frequency of one hertz. For slimes, that would just be a color change once per second, but if all three main types of Overworld zombies (regular, husk, and drowned) are represented in one model, then the item would render a zombie for a second, then the next second it would render a husk, followed by a drowned before cycling back to zombie.

The lore for a custom model that represents the three main zombies could be:

Tier: Faulty
Data Collected: 0/18
Data Per Kill: 1
Simulation Cost: 240 FE/t
Species:
- Zombie
- Husk
- Drowned
commented

Subtypes have now been implemented through the json key subtypes, ex:

"subtypes": [
	"minecraft:stray"
]

Variants will now rotate in the Deep Learner screen.

Oakcoli.1.mp4

They will also be shown on data model tooltips:

commented

Another important thing to note is that subtypes are optional - you can add subtypes that may not necessarily be loaded into the game.
This allows the TiC earth slime to be added to the default subtypes of the slime model.