Start Info Community Spielen
 
 

Morgengrauner Dokumentation

Dateipfad: /home/mud/mudlib/doc//efun/struct_info

SYNOPSIS
        #include 
        #include 

        mixed * struct_info (struct st, int what)

DESCRIPTION
        Return information about the structure of struct  in an array.
        If  has a base struct,  determines how the information
        is returned:

         == SINFO_FLAT:
            All members of , including those inherited from the base
            struct, are returned on the top level of the result.
            The base struct is signified by just its name.

         == SINFO_NESTED:
            Only the members defined in  itself are returned on
            the top level of the result. The information for the base
            struct is a array by itself, as it would be returned
            by a call to struct_info() for a base struct instance.

        The elements in the resulting array are:

          string [SI_NAME]:        the name of the struct
          string [SI_PROG_NAME]:   the name of program defining the struct
          string [SI_PROG_ID]:     the id of the program defining the struct
          mixed  [SI_BASE]:        0, or the base struct information
          mixed* [SI_MEMBER+0]:    the first member information
          mixed* [SI_MEMBER+n]:    the last member information

        The member information entries are arrays themselves with
        these elements:

          string [SIM_NAME]:  name of the member
          int    [SIM_TYPE]:  the type of the member (compile-time value)
          string [SIM_EXTRA]: 0, or if the member is a struct, the
                              struct name

HISTORY
        Introduced in LDMud 3.3.344.
        LDMud 3.3.417 introduced SI_PROG_NAME and SI_PROG_ID in exchange
          for SI_UNIQUE_NAME.

SEE ALSO
        structs(LPC)


zurück zur Übersicht

YOUTUBE | FACEBOOK | TWITTER | DISCORD | FEEDBACK | IMPRESSUM | DATENSCHUTZ 1992–2023 © MorgenGrauen.