Hologram constructor
Hologram(})
A Hologram shows a floating text at a specific Location using Armorstands. Example:
Hologram('''
Hello,
World!
''',
location: Location.here(),
color:Color.Aqua,
)
Implementation
Hologram(
String str, {
required this.location,
Color? color,
this.tags,
this.space = 0.25,
}) {
if (tags == null) {
tags = ['objd_hologram'];
} else {
tags!.add('objd_hologram');
}
texts = str
.split('\n')
.where((line) => line.isNotEmpty)
.map((line) => TextComponent(line, color: color))
.toList();
}