Repository navigation
Read Packets
Reading a Data Packet means evaluating a stored value on an entity against an expected one, using a comparator appropriate to its type. It's always used as a condition.
This page only covers the read_data object itself:
"read_data": {
"AND": [
{
"type": "int", "dataId": "my_sword.air_slash.executed.count",
"comparator": "greater_equal", "value": 3, "delete": true
}
]
}read_data is split into four lists AND, OR, XOR, NOT each holding zero or more conditions like the one above. See Data Packets for how the four groups combine into a single pass/fail result; this page focuses on what goes inside one condition entry.
| Field | Type | Description |
|---|---|---|
type |
String | The kind of value stored under dataId. Determines which comparators are valid and how value/max/min are interpreted. |
dataId |
String | The key the value is read from on the entity. Must match the dataId it was written under. |
comparator |
String | How to evaluate the stored value. Not used for bool (see below). |
value |
Number / String | The value to compare against. Used by every comparator except the *_RANGE family. |
max / min
|
Number | Used instead of value by the *_RANGE comparators. |
expected |
Boolean | Used instead of comparator/value for bool the value the stored boolean must equal. |
delete |
Boolean | If the condition passes, removes the stored data as a side effect of reading it. Optional, defaults to false. |
| Comparator | Passes when |
|---|---|
EQUALS |
stored value == value
|
NOT_EQUALS |
stored value != value
|
GREATER_THAN |
stored value > value
|
GREATER_EQUAL |
stored value >= value
|
LESS_THAN |
stored value < value
|
LESS_EQUAL |
stored value <= value
|
IN_RANGE |
min < stored value < max (both bounds excluded) |
INCLUSIVE_LOWER_RANGE |
min <= stored value < max (lower bound included) |
INCLUSIVE_UPPER_RANGE |
min < stored value <= max (upper bound included) |
INCLUSIVE_RANGE |
min <= stored value <= max (both bounds included) |
In the example, "comparator": "greater_equal", "value": 3 passes once my_sword.air_slash.executed.count reaches 3 or more.
| Comparator | Passes when |
|---|---|
EQUALS |
stored value equals value exactly |
CONTAINS |
stored value contains value as a substring |
Booleans don't use a comparator at all the condition passes when the stored value equals expected:
{ "type": "bool", "dataId": "my_sword.air_slash.executed", "expected": true }delete removes the data the moment the condition passes useful for one-shot conditions (like the air-slash counter above, which resets itself after triggering).
Where the removal actually happens depends on whether the read is local or synced, same as writes:
- Local read the data is removed only from the side that evaluated it.
- Synced read the removal is propagated to both sides, same as a synced write.
-
typemust match whatever the data was written as comparing anintvalue against data that was written as astringwill not work correctly. - Mixing
valuewithmax/minon the same entry isn't meaningful only the*_RANGEcomparators usemax/min; every other comparator usesvalue. - An empty
AND/NOTlist is treated as passing for that group; an emptyOR/XORlist is also treated as passing only a non-empty list is actually evaluated.
EF: Extended Datapacks
📦 Data
🧰 Core
👁️ Visuals
- Zoom Types
- Weapon Models per Style
- Advanced Swing Trails
- Weapons Passive Particles
- Shader Effects I
- Shader Effects II
- Shader Effects III
⚔️ Combat
🗝️ Skill Builder
🛠️ Innate Builder
- Simple Innate Skills
- Holdable Innate Skills
- Conditional Innate Skills
- Conditional Data Innate Skills
- Conditional Holdable Innate Skills
- Sequential Innate Skills
- Per Combo Innate Skills
- Combo Innate Skills
🗡️ Animation Operations
- Animation Operations
- Animation Properties
⚙️ Third-Party