SignLink

From BergerHealer Wiki
Jump to navigation Jump to search
(Marked this version for translation)
 
(17 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{WIP|RyanDo}}
<languages />
<translate><!--T:1-->
{{Plugin|SignLink|A bridge between plugins and signs to easily display text on signs|https://www.spigotmc.org/resources/signlink.39593/|https://github.com/bergerhealer/SignLink|SignLink.png}}


<languages/>
<!--T:2-->
'''SignLink''' acts as a bridge between plugins and signs to easily display text on signs. Instead of entering commands, clicking the sign, or any other routine plugins could use, players can enter 'variables', key values starting (and ending) with %, to show information at that spot.


==Command blocks==
<!--T:3-->
It also includes features no other plugin is needed for, such as custom text and ticker values you can set in values.yml. Signs are stored on file, they survive reloads and server restarts.
 
== Command blocks == <!--T:4-->
 
<!--T:5-->
To change variables using command blocks, you can chain the edit and set commands.
To change variables using command blocks, you can chain the edit and set commands.


<!--T:6-->
<pre>/variable edit varname set newvalue</pre>
<pre>/variable edit varname set newvalue</pre>


==Variabels in variables==
== Variables in variables == <!--T:7-->
 
<!--T:8-->
As of version 1.16.5-v1, it is possible to declare variable names inside the value for a variable. For example, you can do:
As of version 1.16.5-v1, it is possible to declare variable names inside the value for a variable. For example, you can do:


<!--T:9-->
<pre>/variable edit message set Hello, %playername%! It is %time%</pre>
<pre>/variable edit message set Hello, %playername%! It is %time%</pre>


<!--T:10-->
And now putting %message% on signs (or in other variables!) will display the values of playername and time in-place. This can also be used to alias long variable names, so they can fit on signs.
And now putting %message% on signs (or in other variables!) will display the values of playername and time in-place. This can also be used to alias long variable names, so they can fit on signs.


==Commands==
== Commands == <!--T:11-->
 
<!--T:12-->
The following commands are supported by SignLink. For in-game information you can use /help. The /variable command has alias /var.
The following commands are supported by SignLink. For in-game information you can use /help. The /variable command has alias /var.


<pre>'''/togglesignupdate'''
<!--T:13-->
Turns sign updating on or off​
{| class="wikitable"
'''/reloadsignlink'''
|-
Reloads the variable values in values.yml​
! style="width: 20%" | Command
/variable list
! Description
Lists all variables you can edit​
|-
/variable deleteall
| /togglesignupdate
Deletes all variables​
| Turns sign updating on or off
/variable deleteunused
|-
Deletes all unused (not on sign) variables​
| /reloadsignlink
/variable edit [name]
| Reloads the variable values in values.yml​
Changes the variable you are editing. Can be chained with other commands.​
|-
/variable forplayers [names]
| /variable list
Changes for which players the variable is edited Only the set players will see the changes you do on the variable​
| Lists all variables you can edit​
/variable set [value]
|-
Sets the currently editing variable's value​
| /variable deleteall
/variable get
| Deletes all variables​
Gets the currently editing variable's value​
|-
/variable setticker [args]
| /variable deleteunused
Sets a ticker mode for a variable to animate the text. Arguments:
| Deletes all unused (not on sign) variables​
/variable setticker [left/right/blink/none] [interval]
|-
/variable setticker [interval] [left/right/blink/none]
| /variable edit [name]
/variable setticker [left/right/blink/none]
| Changes the variable you are editing. Can be chained with other commands.​
/variable setticker [interval]​
|-
/variable delete (force)
| /variable forplayers [names]
Deletes the variable if it is not used. If force is specified, the variable is removed anyhow.</pre>
| Changes for which players the variable is edited. Only the set players will see the changes you do on the variable​
|-
| /variable set [value]
| Sets the currently editing variable's value​
|-
| /variable get
| Gets the currently editing variable's value​
|-
| /variable setticker [args]
| Sets a ticker mode for a variable to animate the text. Arguments:<br> - /variable setticker [left/right/blink/none] [interval]<br> - /variable setticker [interval] [left/right/blink/none]<br> - /variable setticker [left/right/blink/none]<br> - /variable setticker [interval]​
|-
| /variable delete (force)
| Deletes the variable if it is not used. If force is specified, the variable is removed anyhow.
|}
 
== Configuration == <!--T:14-->


==Configuration==
<!--T:15-->
The linkedsigns.txt contains information of where signs are located. The values.yml sets the (standard) usable keys.
The linkedsigns.txt contains information of where signs are located. The values.yml sets the (standard) usable keys.


<!--T:16-->
<pre># In here you can set default values for this plugin.
<pre># In here you can set default values for this plugin.
# The ticker property can be LEFT, RIGHT or NONE and sets the direction message is 'ticked'.
# The ticker property can be LEFT, RIGHT or NONE and sets the direction message is 'ticked'.
Line 63: Line 94:
     value: 'This is a test message being ticked from right to left.'</pre>
     value: 'This is a test message being ticked from right to left.'</pre>


==Placeholders==
== Placeholders == <!--T:17-->
 
<!--T:18-->
Signlink supports the [https://www.spigotmc.org/resources/placeholderapi.6245/ PlaceholderAPI] plugin in both directions. This means that you can use Signlink to display placeholders on signs, or use signlink variables in other plugins that support placeholders.
Signlink supports the [https://www.spigotmc.org/resources/placeholderapi.6245/ PlaceholderAPI] plugin in both directions. This means that you can use Signlink to display placeholders on signs, or use signlink variables in other plugins that support placeholders.
* You can use signlink variables in other plugins by prefixing it with sl_. For example, %sl_time% will display the time variable.
* You can use signlink variables in other plugins by prefixing it with sl_. For example, %sl_time% will display the time variable.
Line 69: Line 102:
* To display long placeholder names on signs, you can use a shorter variable name and set its value to %placeholder_name%
* To display long placeholder names on signs, you can use a shorter variable name and set its value to %placeholder_name%


==Permissions and commands==
== Permissions and commands == <!--T:19-->
 
<!--T:20-->
Use /togglesignupdate to turn sign updating on or off, just in case someone made a huge amount of updating signs that causes lag. Permission nodes (Bukkit permissions):
Use /togglesignupdate to turn sign updating on or off, just in case someone made a huge amount of updating signs that causes lag. Permission nodes (Bukkit permissions):


<!--T:21-->
<pre>signlink.addsign:
<pre>signlink.addsign:
     description: Allows you to build signs containing variables
     description: Allows you to build signs containing variables
Line 81: Line 117:
     description: Allows you to reload the values.yml
     description: Allows you to reload the values.yml
     default: op</pre>
     default: op</pre>
</translate>

Latest revision as of 14:12, 31 December 2025

Other languages:
SignLink
SignLink.png
A bridge between plugins and signs to easily display text on signs
Spigot: SignLink
GitHub: SignLink


SignLink acts as a bridge between plugins and signs to easily display text on signs. Instead of entering commands, clicking the sign, or any other routine plugins could use, players can enter 'variables', key values starting (and ending) with %, to show information at that spot.

It also includes features no other plugin is needed for, such as custom text and ticker values you can set in values.yml. Signs are stored on file, they survive reloads and server restarts.

Command blocks

To change variables using command blocks, you can chain the edit and set commands.

/variable edit varname set newvalue

Variables in variables

As of version 1.16.5-v1, it is possible to declare variable names inside the value for a variable. For example, you can do:

/variable edit message set Hello, %playername%! It is %time%

And now putting %message% on signs (or in other variables!) will display the values of playername and time in-place. This can also be used to alias long variable names, so they can fit on signs.

Commands

The following commands are supported by SignLink. For in-game information you can use /help. The /variable command has alias /var.

Command Description
/togglesignupdate Turns sign updating on or off
/reloadsignlink Reloads the variable values in values.yml​
/variable list Lists all variables you can edit​
/variable deleteall Deletes all variables​
/variable deleteunused Deletes all unused (not on sign) variables​
/variable edit [name] Changes the variable you are editing. Can be chained with other commands.​
/variable forplayers [names] Changes for which players the variable is edited. Only the set players will see the changes you do on the variable​
/variable set [value] Sets the currently editing variable's value​
/variable get Gets the currently editing variable's value​
/variable setticker [args] Sets a ticker mode for a variable to animate the text. Arguments:
- /variable setticker [left/right/blink/none] [interval]
- /variable setticker [interval] [left/right/blink/none]
- /variable setticker [left/right/blink/none]
- /variable setticker [interval]​
/variable delete (force) Deletes the variable if it is not used. If force is specified, the variable is removed anyhow.

Configuration

The linkedsigns.txt contains information of where signs are located. The values.yml sets the (standard) usable keys.

# In here you can set default values for this plugin.
# The ticker property can be LEFT, RIGHT or NONE and sets the direction message is 'ticked'.
# tickerInterval sets the amount of ticks (1/20 of a second) are between the ticker update.
# The value is the thing to display or tick.
# To use colors in your text, use the § sign followed up by a value from 0 - F.
# Example: §cRed to display a red colored 'Red' message.
# You can find all color codes on the internet (they may use & there, ignore that!)
sign:
    ticker: NONE
    value: This is a regular message you can set and is updated only once.
test:
    tickerInterval: 3
    ticker: LEFT
    value: 'This is a test message being ticked from right to left.'

Placeholders

Signlink supports the PlaceholderAPI plugin in both directions. This means that you can use Signlink to display placeholders on signs, or use signlink variables in other plugins that support placeholders.

  • You can use signlink variables in other plugins by prefixing it with sl_. For example, %sl_time% will display the time variable.
  • Adding placeholder names to the 'autoUpdateVariables' list in SignLink's config.yml will make them work on signs, with the same name.
  • To display long placeholder names on signs, you can use a shorter variable name and set its value to %placeholder_name%

Permissions and commands

Use /togglesignupdate to turn sign updating on or off, just in case someone made a huge amount of updating signs that causes lag. Permission nodes (Bukkit permissions):

signlink.addsign:
    description: Allows you to build signs containing variables
    default: op
signlink.toggleupdate:
    description: Allows you to set if signs are being updated or not
    default: op
signlink.reload:
    description: Allows you to reload the values.yml
    default: op