default.gd 511 B

12345678910111213141516171819
  1. # meta-description: Base template for rich text effects
  2. @tool
  3. # Having a class name is handy for picking the effect in the Inspector.
  4. class_name RichText_CLASS_
  5. extends _BASE_
  6. # To use this effect:
  7. # - Enable BBCode on a RichTextLabel.
  8. # - Register this effect on the label.
  9. # - Use [_CLASS_SNAKE_CASE_ param=2.0]hello[/_CLASS_SNAKE_CASE_] in text.
  10. var bbcode := "_CLASS_SNAKE_CASE_"
  11. func _process_custom_fx(char_fx: CharFXTransform) -> bool:
  12. var param: float = char_fx.env.get("param", 1.0)
  13. return true