Skip to content

Commit 202b9c1

Browse files
committed
update README
1 parent 44f524d commit 202b9c1

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

README.md

+2-10
Original file line numberDiff line numberDiff line change
@@ -49,17 +49,9 @@ $myInt->setValue(42);
4949
echo $myInt->getValue(); // 42
5050
```
5151

52-
On String tags, `getValue()` and `setValue()` will use the raw string data, which uses Java's modified
53-
UTF-8 encoding. To use different encodings,
54-
use `getDecodedValue($encoding = "UTF-8")` and `setDecodedValue($value, $encoding = "UTF-8")` instead.
55-
A list of supported encodings is returned by the `mb_list_encodings()` function.
52+
On String tags, `getValue()` and `setValue()` use the UTF-8 encoding and convert strings based on the selected NBT flavor
53+
when being serialized.
5654

57-
```php
58-
$myString new \Aternos\Nbt\Tag\StringTag();
59-
60-
$myString->setDecodedValue("Hello world!");
61-
echo $myString->getDecodedValue(); // Hello world!
62-
```
6355

6456
Compound tags, list tags, and array tags implement the `ArrayAccess`, `Countable`,
6557
and `Iterator` interfaces and can therefore be accessed as arrays.

0 commit comments

Comments
 (0)