MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame^] | 1 | SYNOPSIS |
| 2 | mixed *to_array(string arg); |
| 3 | mixed *to_array(symbol arg); |
| 4 | mixed *to_array(quotedarray arr); |
| 5 | mixed *to_array(mixed *arg); |
| 6 | mixed *to_array(struct); |
| 7 | |
| 8 | (int*)<value> |
| 9 | |
| 10 | BESCHREIBUNG |
| 11 | Strings und Symbole werden umgewandelt in ein Integer-Array, das aus |
| 12 | den Zeichen von <arg> besteht. |
| 13 | |
| 14 | Gequotete Arrays werden "entquotet", und Arrays bleiben, wie sie sind. |
| 15 | |
| 16 | Structs werden in normale Arrays umgewandelt. |
| 17 | |
| 18 | BEISPIELE: |
| 19 | to_array("12") liefert ({33,34}). |
| 20 | |
| 21 | BUGS |
| 22 | Die Cast-Schreibweise funktioniert nur, wenn der genaue Wert von |
| 23 | <value> zum Zeitpunkt der Kompilierung bekannt ist. Dies wird |
| 24 | nicht geaendert werden, da die Funktionsform verwendet werden kann. |
| 25 | |
| 26 | HISTORY |
| 27 | LDMud 3.3.250 added structs to the accepted data types. |
| 28 | |
| 29 | SIEHE AUCH |
| 30 | to_int(E), to_string(E), to_struct(E) |