Entity: make getNetworkTypeId non-static (#6037)

This was static to permit ItemFactory to register spawn eggs for all known entity types in early PM4. However, nowadays we provide a callback to the spawn egg instead, and spawn eggs must be manually implemented, so this is no longer needed.

In addition, having this static forces everyone to make a new entity class for every unique type of entity, which isn't ideal.
This commit is contained in:
Doge
2023-09-06 17:26:32 +03:00
committed by GitHub
parent 4dc9d696d0
commit ed61a68013
19 changed files with 20 additions and 20 deletions

View File

@@ -39,7 +39,7 @@ class EntityShortFallSound implements Sound{
LevelSoundEvent::FALL_SMALL,
$pos,
-1,
$this->entity::getNetworkTypeId(),
$this->entity->getNetworkTypeId(),
false, //TODO: does isBaby have any relevance here?
false
)];