Package de.delinkedde.mobarenareborn.mob
Klasse MobRegistry
java.lang.Object
de.delinkedde.mobarenareborn.mob.MobRegistry
Registry of spawnable
MobType definitions.
Lookups are tolerant of formatting: identifiers are normalised by lower-casing and removing
every character that is not a letter or digit, so zombie_villager,
Zombie-Villager and zombievillager all resolve to the same type. The default
vanilla roster is registered on construction; further types can be added via
register(MobType).
-
Konstruktorübersicht
KonstruktorenKonstruktorBeschreibungCreates a registry pre-populated with the default vanilla mob roster. -
Methodenübersicht
-
Konstruktordetails
-
MobRegistry
public MobRegistry()Creates a registry pre-populated with the default vanilla mob roster.
-
-
Methodendetails
-
register
Registers (or replaces) a mob type.- Parameter:
type- the type to register
-
get
Resolves a mob type by identifier, ignoring case, underscores, hyphens and dots.- Parameter:
name- the identifier as written in configuration- Gibt zurück:
- the matching type, if registered
-
ids
- Gibt zurück:
- an unmodifiable view of all registered (normalised) identifiers
-
normalise
Normalises an identifier for tolerant lookup.- Parameter:
name- the raw identifier- Gibt zurück:
- the identifier reduced to lower-case letters and digits
-