Skip to content

Commit c58e8cb

Browse files
committed
Danger is a bit overkill
1 parent 5e6d952 commit c58e8cb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

docs/datastorage/attachments.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,10 @@ The attachment type contains:
1212
- an optional serializer if the attachment should be persisted;
1313
- additional configuration options for the attachment, for example the `copyOnDeath` flag.
1414

15-
:::danger
15+
:::warning
1616
If you don't provide a serializer, the attachment will not be saved to disk.
17-
If your data attachment disappears when you reload the world, you probably forgot to provide a serializer.
17+
(This can be intended).
18+
If your data attachment disappears when you reload the world but you want it to persist, you probably forgot to provide a serializer.
1819
:::
1920

2021
There are a few ways to provide an attachment serializer: directly implementing `IAttachmentSerializer`, implementing `INBTSerializable` and using the static `AttachmentSerializer.serializable()` method to create the builder, or providing a codec to the builder. (This latter option is not recommended for item stacks due to relatively slowness).

0 commit comments

Comments
 (0)