CE AAPP
CE AAPP SpigotCE AAPP GitHubConditionalEvents
ConditionalEvents AAPP
ConditionalEvents AAPP
  • ๐Ÿ”ฎCE AAPP
    • ๐Ÿ“ŒStarting information
    • โš™๏ธInstallation or updation
    • ๐Ÿ—’๏ธLogical notations
    • Actions
      • ๐Ÿ”ŒPlugins actions
        • change_balance
        • change_oraxen_block
        • change_items_adder_block
        • drop_items_adder_item
        • show_end_credits
      • ๐ŸƒEvents actions
        • change_projectile
      • ๐ŸŒIndependent actions
        • manage_inventory
        • change_chat
        • change_block
        • change_AI
        • change_weather
        • change_time
        • change_freeze
        • change_fire
        • create_explosion
        • change_gravity
        • parse_placeholder
        • change_speed
        • change_ticks_lived
        • launch_projectile
        • change_gliding
        • change_invulnerable
        • change_movement
        • change_name
        • change_item
        • manage_recipe
        • change_fly
        • change_craft
        • change_air
        • drop_current_item
        • attack_entity
        • change_passenger
        • teleport_entities
        • change_entities
        • player_break_block
        • change_effect
        • make_damage
        • change_velocity
        • change_health
        • change_area
        • change_statistic
        • manage_mysql
    • Placeholders
      • ๐Ÿ”ŒPlugins placeholders
        • Placeholder for LuckPerms permissions with contexts
        • Placeholder for real nickname in Essentials based on custom nickname
      • ๐ŸŒIndependent placeholders
        • Placeholder for items
        • Placeholder for the highest block at a location
        • Placeholder for random block in area
        • Placeholder for biome by coordinates
        • Placeholder for entities in radius
        • Placeholder for processing arrays
        • Placeholder for different team information /team
        • Placeholder for custom data
        • Placeholder for different entity information
        • Placeholder for block lighting
        • Placeholder for working with MySQL
    • ๐Ÿ”งModifying the addon
Powered by GitBook
On this page
  1. CE AAPP
  2. Placeholders
  3. Independent placeholders

Placeholder for custom data

A placeholder that allows you to save, delete and obtain variables for players, coordinates and entities (in a file or temporarily).

PreviousPlaceholder for different team information /teamNextPlaceholder for different entity information

Last updated 8 days ago


Meaning

Allows you to save, delete and obtain variables for players, coordinates and entities (in a file or temporarily).


Format
%CEP_customData_<action>_<name>_(semi-mandatory) <data>_(optional) <entity_uuid|player_name|world,x,y,z>%

<action> โ€“ may be set, remove, get or getset, "getset" is needed to get a variable if it exists or set it if it does not exist, before the action you can write โ€œtempโ€ (for example: "tempset"), then instead of perpetual variables temporary variables will be used, which will be stored until the server restarts; (MANDATORY)

<name> โ€“ the name of the variable (do not use underscores); (MANDATORY)

<data> โ€“ the data to save in the variable (only in case of "set" or "getset" actions); (SEMI-MANDATORY)

<entity_uuid | player_name | world,x,y,z> โ€“ the target which own the variable (if no target is specified, a global variable will be used). (OPTIONAL)


Use "แต•" symbol instead of underscores in <data>!

The perpetual variables and temporary variables are different! The same variables names will point to different variables.

You will get back the specified or saved data in any case, nevermind using the "get" or "set". In case of "remove" you will get "true" or "false" depending on the removing result. You can also use expansion from PlaceholderAPI and its "%string_substring_<startIndex>,<endIndex>_<string>%" placeholder to trim your data placeholder to the zero characters if you do not want to get the data back.

If "temp" prefix will not be specified in the action, the variable will be stored in a file at the path plugins/TriggerReactor/var.json (you can change this file, changes will take effect after the command /trg reload confirm), otherwise the variable will be stored in the server memory until it is restarted.


Targets
  • Players;

  • Entities;

  • Blocks.


Where is useful

Can be useful in many cases to save, change, delete and obtain different data for different objects in a comfortable way. It can be used in many different systems and mini-games.


Examples
%CEP_customData_set_coins_2_{player}% # Set some "coins" data to "2" for the current player 
%CEP_customData_tempgetset_taxes_100_world,643,54,1542% # Set temporary variabe as some "taxes" data if it does not exist to "100" or get the current value otherwise for some block at the location 

๐Ÿ”ฎ
๐ŸŒ
String