SPluginsSPlugins

Esta página foi traduzida do inglês com ajuda de IA. Melhore esta tradução ou leia o original.

🧮 SCore Variables

SCore variables

O SCore tem uma integração de variáveis onde você pode armazenar textos/números em variáveis de forma global ou por jogador. Elas não estão integradas no EI nem no EB, mas estão integradas como comandos (então podem ser usadas em combinação com EI / EB)

Elas são armazenadas em plugins/Score/variables

Variable Types

TipoExplicação
STRINGPermite armazenar texto
NUMBERPermite armazenar números
LISTPermite armazenar vários valores

Variable Scope (For)

TipoExplicação
GLOBALVariável armazenada de forma global significa que existe um único valor e ele é o mesmo para todos
PLAYERVariável armazenada para cada jogador significa que o valor é independente para cada jogador. Então o valor de dois jogadores diferentes pode não ser o mesmo.

Modification Types

TipoExplicação
SETVocê define um valor estático para a variável
MODIFICATIONVocê modifica a variável (útil para variáveis INT, para somar um valor a um valor inteiro ou subtrair um certo valor)
LIST-ADDEspecífico para LIST, adiciona um novo valor à lista
LIST-REMOVEEspecífico para LIST, remove um valor da lista
Perigo

O ID das variáveis não pode ter underscores, pontos ou espaços, mas - é permitido

Variables tools

  • /score variables list
    • Exibe os IDs de todas as variáveis existentes
  • /score variables info {variable-id} [player]
    • Exibe o valor de uma variável específica (Opcional: para um jogador específico)
  • /score variables-create {variable-id}
    • Cria uma nova variável com o id mencionado e abre o editor in-game
  • /score variables-define {variable-id} {type_of_variable} {for} [material_icon] [default_values...]
    • Permite criar uma nova variável usando um comando
  • /score variables-delete {variable-id}
    • Exclui a variável com o id mencionado
  • /score variables
    • Abre o editor in-game de variáveis
  • /score variables clear {type_of_variable} {variable-id} [player]
    • Limpa o valor da variável (Opcional: para um jogador específico)
    • Se você substituir [player] por all, o valor será limpo para todos os jogadores
  • /score variables set-default {variable-id} {value}
    • Altera o valor padrão da variável (uma palavra, sem espaços). Ele é salvo no arquivo da variável, então permanece após um reload
  • /score variables {modification_type} {variable_scope} {variable-id} {value} [player]
    • Permite modificar o valor de uma variável existente.
    • Exemplos:
      • Variáveis GLOBAL:
        • /score variables SET GLOBAL exemple1 100
          • Define o valor 100 para a variável global exemple1
        • /score variables MODIFICATION GLOBAL plop 100
          • Aumenta a variável global plop em +100
        • /score variables MODIFICATION GLOBAL plop -50
          • Diminui a variável global plop em -50
      • Variáveis PLAYER
        • /score variables SET PLAYER my-variable -20 Ssomar
          • Define o valor -20 para a variável my-variable do jogador Ssomar
        • /score variables MODIFICATION PLAYER my-variable -50 Ssomar
          • Diminui a variável de jogador my-variable em -50 para Ssomar
      • Exemplos específicos para o tipo LIST
        • /score variables list-add PLAYER ThisIsTheNameOfMyVariable TEXT1 Ssomar
          • Adiciona valores à lista
        • /score variables list-add PLAYER ThisIsTheNameOfMyVariable TEXT3 Ssomar index
          • Para especificar uma posição para adicionar o valor na lista, use o recurso index (0 é o primeiro elemento da lista, então TEXT3 será adicionado no início da lista)
        • /score variables list-remove PLAYER ThisIsTheNameOfMyVariable Ssomar
          • Remove o último valor
        • /score variables list-remove PLAYER ThisIsTheNameOfMyVariable Ssomar index
          • Remove um índice específico
        • /score variables list-remove PLAYER ThisIsTheNameOfMyVariable Ssomar value:Test
          • Remove um valor específico
Informação

Variable-list também funciona com variáveis GLOBAL, mas você precisaria trocar PLAYER -> GLOBAL e remover o jogador do comando

Variables placeholders

Isso requer o PlaceholderAPI.

  • %score_variables_<variable-id>%
  • %score_variables_<variable-id>_int%
Informação

Como os placeholders de variáveis do SCore são suportados pelo PlaceholderAPI, você pode usar as variáveis do SCore assim:

%math_{score_variables_userLevel}*10%

Placeholders specific for LIST

  • %score_variables_<variable-id>_<index>%
    • Retorna o valor no índice específico da lista
    • O índice pode vir de outro placeholder escrito entre colchetes, ele é interpretado primeiro: %score_variables_myList_{score_variables_myIndex_int}%
  • %score_variables_<variable-id>%
    • Retorna todos os elementos da lista
  • %score_variables-contains_<variable-name>_<value>%
    • Retorna um booleano para verificar se a lista contém um valor (true ou false)
  • %score_variables-size_<variable-name>%
    • Retorna o tamanho da lista

O que você pode fazer com este recurso -> Item criado por Ssomar

Terminator

Ability :
- RIGHT CLICK to select entities
- SHIFT+RIGHT CLICK to explode them

You need to first create the variable, you can use this command:
/score variables-define myList LIST PLAYER
# Le nom ou nom d'affichage
name: '&6&l>> &7Terminator stick &6&l<<'
# La description de l'item
lore:
- '&7Select entites by right'
- '&7clicking on them !'
- '&eLimit: &63 entities'
- '&e'
- '&7Then shift + right click'
- '&7to make them explode !'
# Le matériau
material: STICK
usage: 1
usageLimit: -1
config_5: true
config_update: true
# Fonctionnalités de nourriture
foodFeatures:
  # La nutrition de la nourriture
  nutrition: 1
  # La saturation de la nourriture
  saturation: 1
  # La nourriture est-elle de la viande?
  isMeat: false
  # Le joueur peut-il toujours manger cette nourriture?
  canAlwaysEat: false
# Les fonctionnalités de masquage
# Masquer:
# Attributs, Enchantements, ...
hiders:
  # Masquer l'utilisation
  hideUsage: true
# Les activateurs / déclencheurs
activators:
  activator0:
    option: PLAYER_RIGHT_CLICK
    typeTarget: NO_TYPE_TARGET
    # Les emplacements où
    # l'activateur fonctionnera
    detailedSlots:
    - -1
    playerCommands:
    - SWING_MAIN_HAND
    - LAUNCH DEFAULT_INVISIBLE_ARROW_NO_GRAVITY_SPEED
  activator5:
    option: PROJECTILE_HIT_ENTITY
    # Les emplacements où
    # l'activateur fonctionnera
    detailedSlots:
    - -1
    playerCommands:
    - 'SENDMESSAGE &7You &cunselected &7the entity: &e%entity_name%'
    - score variables list-remove player myList %player% value:%entity_uuid%
    # Les conditions placeholders
    placeholdersConditions:
      plchCdt0:
        type: PLAYER_STRING
        comparator: EQUALS
        # La première partie de la condition
        part1: '%score_variables-contains_myList_%entity_uuid%%'
        # La deuxième partie de la condition
        part2: 'true'
    detailedEntities: []
    entityCommands: []
  activator2:
    option: PLAYER_LEFT_CLICK
    typeTarget: NO_TYPE_TARGET
    # Les emplacements où
    # l'activateur fonctionnera
    detailedSlots:
    - -1
    playerCommands:
    - FOR %score_variables_myList% > for1
    - score run-entity-command entity:%for1% JUMP 1
    - END_FOR for1
    - DELAYTICK 5
    - FOR %score_variables_myList% > for1
    - score run-entity-command entity:%for1% DAMAGE 100
    - END_FOR for1
    - execute at %player% run playsound minecraft:entity.ender_dragon.death master
      @a
    - score variables clear player myList %player%
    - SEND_MESSAGE &7You &cpulverized &7the selected entities &7but you can do many
      other things let's talk your imagination
    #
    playerConditions:
      ifSneaking: true
      # The message displayed
      # when the condition is not met
      ifSneakingMsg: ''
    # Les conditions placeholders
    placeholdersConditions:
      plchCdt0:
        type: PLAYER_NUMBER
        comparator: SUPERIOR
        # La première partie de la condition
        part1: '%score_variables-size_myList%'
        # La deuxième partie de la condition
        part2: '0'
        # Message si la condition n'est pas valide?
        messageIfNotValid: '&7To execute the ability you must to &cselect at least
          1 entity'
  activator1:
    option: PROJECTILE_HIT_ENTITY
    # Les emplacements où
    # l'activateur fonctionnera
    detailedSlots:
    - -1
    playerCommands:
    - 'SEND_MESSAGE &7You &aselected &7the entity: &e%entity_name%'
    - score variables list-add player myList %entity_uuid% %player%
    # Les conditions placeholders
    placeholdersConditions:
      plchCdt0:
        type: PLAYER_STRING
        comparator: EQUALS
        # La première partie de la condition
        part1: '%score_variables-contains_myList_%entity_uuid%%'
        # La deuxième partie de la condition
        part2: 'false'
      plchCdt1:
        type: PLAYER_NUMBER
        comparator: INFERIOR
        # La première partie de la condition
        part1: '%score_variables-size_myList%'
        # La deuxième partie de la condition
        part2: '3'
        # Message si la condition n'est pas valide?
        messageIfNotValid: '&4&l>> &7&oYou can''t select more than 3 entities'
    detailedEntities: []
    entityCommands: []
  activator3:
    # Le nom ou nom d'affichage
    name: cancelProjectileSelection
    option: PROJECTILE_HIT_ENTITY
    # Annuler l'événement vanilla
    cancelEvent: true
    # Les emplacements où
    # l'activateur fonctionnera
    detailedSlots:
    - -1
    playerCommands: []
    detailedEntities: []
    entityCommands: []

ExecutableItems (Item variables)

O ExecutableItems tem uma integração de variáveis onde você pode armazenar textos/números/listas em variáveis dentro do item. Com elas você pode criar várias mecânicas nos seus itens.

Informação

Existem formas de alterar a variável fora do item, usando estes métodos:
\

Modify a variable

  • VIA CONSOLE
    • Comando:
      • /ei console-modification {set/modification} variable {player} {slot} {variableName} {value}
  • VIA in-game
    • Comando:
      • /ei modification {set/modification} variable {slot} {variableName} {value}

Para ver os placeholders de "Internal item variables", consulte aqui

ExecutableBlocks (Block variables)

O ExecutableBlocks tem uma integração de variáveis onde você pode armazenar textos/números/listas em variáveis dentro do bloco. Com elas você pode criar várias mecânicas nos seus blocos.

Para ver os placeholders de "Internal item/block variables", consulte aqui

Experimente agora

Copie isto no ExecutableItems e recarregue

Da referência de custom commands do SCore. Cole em uma config, execute o comando de reload do plugin e você terá um ponto de partida funcional para editar.

activators:
  activator0: # Activator ID, you can create as many activator on the activators list
    option: # Here goes an activator that is at least instance of player
    playerCommands:
    - ABSORPTION amount:5 time:200 # Gives the player absorption
  activator1: # Activator ID, you can create as many activator on the activators list
    option: # Here goes an activator that is at least instance of target
    targetCommands:
    - ABSORPTION amount:5 time:200 # Gives the target absorption
E

Plugin usado nesta página

ExecutableItems

Itens personalizados com habilidades, ativadores e comandos, sem código.

Criado em 3 de out. de 2026Última atualização em 13 de nov. de 2026 por Ssomar
Editar esta página no GitHub