Last Edited: 2020-05-13
Just implemented the new tags:
Do you hate typing color codes? They can be hard to keep track of, especially if you like particularly colorful messages, especially if you need to reapply formats. This script allows you to shift-click the colors you need straight from the chat box to insert them directly into your chat box without erasing the rest of your message or forcing you to look at a reference to verify you have the right color code.
Here's an example of how it works: https://streamable.com/mvoll
Simply type
Here's the latest script, in a haste:
https://one.denizenscript.com/haste/68947
As well as right here in the thread:
Just implemented the new tags:
<&hover[HoverText]>
/<&end_hover>
| Returns a special chat code that makes the following text display the input hover text when the mouse is left over it!<&insertion[InsertText]>
/<&end_insertion>
| Returns a special chat code that makes the following text insert the input message to chat when shift-clicked!Do you hate typing color codes? They can be hard to keep track of, especially if you like particularly colorful messages, especially if you need to reapply formats. This script allows you to shift-click the colors you need straight from the chat box to insert them directly into your chat box without erasing the rest of your message or forcing you to look at a reference to verify you have the right color code.
Here's an example of how it works: https://streamable.com/mvoll
Simply type
/ccolors
and shift-click the colors you want.Here's the latest script, in a haste:
https://one.denizenscript.com/haste/68947
As well as right here in the thread:
Code:
CColors_Command:
type: command
name: ccolors
debug: false
description: Lists the colors in a click-menu
usage: /ccolors
script:
#@ Verify args
- if <context.args.size> != 0:
- narrate "<&c>Invalid usage! Just type<&2>: <&6>/<&e>ccolors"
- stop
#@ Create color lists
- define Colors <list[&0|&1|&2|&3|&4|&5|&6|&7|&8|&9|&a|&b|&c|&d|&e|&f]>
- foreach <list[1|2]> as:Line:
- define Math1 <[Loop_Index].add[<[Loop_Index].sub[1].mul[7]>]>
- define Math2 <[Loop_Index].add[<[Loop_Index].sub[1].mul[8]>].add[7]>
- foreach <[Colors].get[<[Math1]>].to[<[Math2]>]> as:Color:
- define Hover "<&a>Shift<&2>-<&a>Click to Insert<&2>:<&nl><[Color].parse_color>This Color!"
- define Text <[Color].parse_color><[Color]>
- define Insert <[Color]>
- define Key<[Loop_Index]> <&hover[<[Hover]>]><&insertion[<[Insert]>]><[Text]><&end_insertion><&end_hover>
- define List<[Line]>:->:<[Key<[Loop_Index]>]>
#@ Create format lists
- define formats "<List[&k/tacos|&l/Bold|&M/Strike|&r/ Reset|&o/Italic|&n/Underline]>"
- foreach <list[3|4|5]> as:line:
- define Math1 <[Loop_Index].mul[2].sub[1]>
- define Math2 <[Loop_Index].mul[2]>
- foreach <[Formats].get[<[Math1]>].to[<[Math2]>]> as:Format:
- define Hover "<&a>Shift<&2>-<&a>Click to Insert<&2>:<&nl><&e><[Format].before[/].parse_color><[Format].after[/]>!"
- define Text <[Format].before[/].parse_color><[Format].after[/]><&sp><&sp><&sp>
- define Insert <[Format].before[/]>
- define Key<[Loop_Index]> <&hover[<[Hover]>]><&insertion[<[Insert]>]><[Text]><&end_insertion><&end_hover>
- define List<[Line]>:->:<[Key<[Loop_Index]>]>
#@ Narrate
- narrate "<&2>+<element[<&a>Shift-Click To Insert].pad_left[28].with[-]><&2>-----+"
- repeat 5:
- narrate <&sp><&sp><[List<[Value]>].separated_by[<&sp><&sp>]>
- narrate "<&8>[<&7>Note<&8>]<&7>: Color before Formats!<&nl><&2>+<element[].pad_left[22].with[-]><&2>-----+"