Merge branch 'master' into 1.16

This commit is contained in:
gnembon committed 2020-04-29 00:48:26 -03:00
commit e64f6c87d4
6 files changed
+177 -6

No files matched your search

@@ -0,0 +1,40 @@
package carpet.script.value;
import net.minecraft.text.BaseText;
public class FormattedTextValue extends StringValue
{
BaseText text;
public FormattedTextValue(BaseText text)
{
super(null);
this.text = text;
}
@Override
public String getString() {
return text.getString();
}
@Override
public boolean getBoolean() {
return text.getSiblings().size() > 0;
}
@Override
public Value clone()
{
return new FormattedTextValue(text);
}
@Override
public String getTypeString()
{
return "text";
}
public BaseText getText()
{
return text;
}
}