Class RegisterParticleProvidersEvent
- All Implemented Interfaces:
- IModBusEvent
ParticleTypes must be registered during RegisterEvent as usual;
 this event is only for the ParticleProviders.
This event is not cancellable, and does not have a result.
This event is fired on the mod-specific event bus, only on the logical client.
- 
Nested Class SummaryNested classes/interfaces inherited from class net.minecraftforge.eventbus.api.Eventnet.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescription<T extends ParticleOptions>
 voidregisterSpecial(ParticleType<T> type, ParticleProvider<T> provider) Registers a ParticleProvider for a non-json-based ParticleType.<T extends ParticleOptions>
 voidregisterSprite(ParticleType<T> type, ParticleProvider.Sprite<T> sprite) Registers a ParticleProvider for a json-based ParticleType with a single texture; the resultingTextureSheetParticles will use that texture when created.<T extends ParticleOptions>
 voidregisterSpriteSet(ParticleType<T> type, ParticleEngine.SpriteParticleRegistration<T> registration) Registers a ParticleProvider for a json-based ParticleType.Methods inherited from class net.minecraftforge.eventbus.api.EventgetListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult
- 
Field Details- 
particleEngine
 
- 
- 
Constructor Details- 
RegisterParticleProvidersEvent
 
- 
- 
Method Details- 
registerSpecialpublic <T extends ParticleOptions> void registerSpecial(ParticleType<T> type, ParticleProvider<T> provider) Registers a ParticleProvider for a non-json-based ParticleType. These particles do not receive a list of texture sprites to use for rendering themselves. There must be no particle json with an ID matching the ParticleType, or a redundant texture list error will occur when particle jsons load. - Type Parameters:
- T- ParticleOptions used by the ParticleType and ParticleProvider.
- Parameters:
- type- ParticleType to register a ParticleProvider for.
- provider- ParticleProvider function responsible for providing that ParticleType's particles.
 
- 
registerSpritepublic <T extends ParticleOptions> void registerSprite(ParticleType<T> type, ParticleProvider.Sprite<T> sprite) Registers a ParticleProvider for a json-based ParticleType with a single texture; the resulting TextureSheetParticles will use that texture when created.A particle json with an ID matching the ParticleType must exist in the particlesasset folder, or a missing texture list error will occur when particle jsons load.- Type Parameters:
- T- ParticleOptions used by the ParticleType and Sprite function.
- Parameters:
- type- ParticleType to register a ParticleProvider for.
- sprite- Sprite function responsible for providing that ParticleType's particles.
 
- 
registerSpriteSetpublic <T extends ParticleOptions> void registerSpriteSet(ParticleType<T> type, ParticleEngine.SpriteParticleRegistration<T> registration) Registers a ParticleProvider for a json-based ParticleType. Particle jsons define a list of texture sprites which the particle can use to render itself. A particle json with an ID matching the ParticleType must exist in the particlesasset folder, or a missing texture list error will occur when particle jsons load.- Type Parameters:
- T- ParticleOptions used by the ParticleType and SpriteParticleRegistration function.
- Parameters:
- type- ParticleType to register a particle provider for.
- registration- SpriteParticleRegistration function responsible for providing that ParticleType's particles.
 
 
-