class
Rosegold::DataComponents::PotionContents::PotionEffect
- Rosegold::DataComponents::PotionContents::PotionEffect
- Reference
- Object
Overview
Potion effect structure
Defined in:
rosegold/inventory/slot.crConstructors
- .new(type_id : UInt32, amplifier : UInt32, duration : Int32, ambient : Bool = false, show_particles : Bool = true, show_icon : Bool = true, has_hidden_effect : Bool = false, hidden_effect : Nil | Rosegold::DataComponents::PotionContents::PotionEffect = nil)
-
.read(io) : PotionEffect
Outer PotionEffect wire format = MobEffect Holder (VarInt) + Details.
- .read_details(io, type_id : UInt32) : PotionEffect
Instance Method Summary
- #ambient=(ambient : Bool)
- #ambient? : Bool
- #amplifier : UInt32
- #amplifier=(amplifier : UInt32)
- #duration : Int32
- #duration=(duration : Int32)
- #has_hidden_effect=(has_hidden_effect : Bool)
- #has_hidden_effect? : Bool
- #hidden_effect : PotionEffect | Nil
- #hidden_effect=(hidden_effect : PotionEffect | Nil)
- #show_icon=(show_icon : Bool)
- #show_icon? : Bool
- #show_particles=(show_particles : Bool)
- #show_particles? : Bool
- #type_id : UInt32
- #type_id=(type_id : UInt32)
- #write(io) : Nil
- #write_details(io) : Nil
Constructor Detail
def self.read(io) : PotionEffect
#
Outer PotionEffect wire format = MobEffect Holder (VarInt) + Details.
Details recursion on #hidden_effect is into Details only (no repeat of the
leading MobEffect VarInt). See MobEffectInstance.java Details.STREAM_CODEC.