MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 1 | SYNOPSIS |
Zesstra | 01c0287 | 2019-03-01 21:51:21 +0100 | [diff] [blame] | 2 | int sizeof(mixed * val) |
| 3 | int sizeof(string val) |
| 4 | int sizeof(mapping val) |
| 5 | int sizeof(struct xxx val) |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 6 | |
| 7 | BESCHREIBUNG |
| 8 | Liefert die Anzahl Elemente in einem Array <val>, die Anzahl |
Zesstra | 01c0287 | 2019-03-01 21:51:21 +0100 | [diff] [blame] | 9 | Zeichen in einem String <val> oder die Anzal Keys in einem Mapping |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 10 | <val>. |
| 11 | |
| 12 | Als Spezialfall kann <val> auch 0 sein. In diesem Fall liefert die |
| 13 | Funktion 0 zurueck. |
| 14 | |
Zesstra | 01c0287 | 2019-03-01 21:51:21 +0100 | [diff] [blame] | 15 | Falls im Spiel Objekte zerstoert wurde, seit das Mapping zuletzt auf |
| 16 | zerstoerte Keys geprueft wurde, muss es zuerst auf zerstoerte Objekte |
| 17 | in Keys geprueft werden. In diesem Fall steigt die Laufzeit mit der |
| 18 | Anzahl der Keys im Mapping (O(n)). |
| 19 | Anderenfalls ist die Laufzeit unabhaengig der Anzahl der Schluessel |
| 20 | (O(1)). |
| 21 | |
| 22 | GESCHICHTE |
| 23 | LDMud 3.2.9 fuehrte Strings als moegliche Argumente ein. |
| 24 | LDMud 3.3 fuehrte Structs als moegliche Argumente ein. |
| 25 | |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 26 | SIEHE AUCH |
Zesstra | 01c0287 | 2019-03-01 21:51:21 +0100 | [diff] [blame] | 27 | strlen(E), allocate(E), pointerp(E), mappingp(E), m_allocate(E), |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 28 | widthof(E) |