GameSetting

Description

Edits the opening state and settings for some functions in the game (for example, number of players, mini-map, rank screen, etc.).

Properties

        string    Name
    The custom name of this object.

        string    ClassName
    The object-type name.

        bool    isShow
    Check it to use.

        bool    isTeamShow
    Check it to display by team.

        bool    isShow
    Check it to use.

        float    distance
    Players mini-map view distance.

        int    Size
    Mini-map Size (Using default size if you don't set).

        int    startTime
    The in-game time when the server runs for the first time (unit: hour).

        int    minNum
    Players required to start game.

        int    maxNum
    Players the server can hold.

        int    FalenPartsDestroyHeight
    The distance to determine your Avatar's death when the Avatar falls from the horizon line.

        bool    NavMeshOpen
    When turned on, navigation mesh will be generated in maps to aid in bypassing obstacles in pathfinding automatically. However, as this function will increase the game pressure, it is recommended not to turn it on if you don't need pathfinding.

Functions

    DelAllChild()
    Deletes all child objects.

    GetAncestorByName(Name)
    Returns the object's first parent node with the same name.

    GetAncestorByClassName(className)
    Returns the object's first parent node of the same class.

    GetChildByName(Name,recursive)
    Returns the object's first child object with the same name. If the second parameter is true, it will search through descendants of all hierarchies.

    GetChildByClassName(className,recursive)
    Returns the object's first child object of the same type. If the second parameter is true, it will search through descendants of all hierarchies.

    GetAllChild()
    Seeks all its child objects and returns as a list.

    GetAllDescendant()
    Recursively seeks all its descendants and returns as a list.

    IsClass(ClassName)
    Judges whether it is the class the same as the given object class or not.

    IsAncestor(TarObj)
    Judges whether itself is the ancestor of the target object or not.

    IsDescendant(TarObj)
    Judges whether itself is the descendant of the target object or not.

    WaitForChild(childName,timeout)
    Seeks its own child object.

    Child(childName)
    Seeks its own child object by a given name.

    Equals(TarObj)
    Judges whether the target object is the same as itself or not.

    AddToStorage(TarObj)
    Stores the specified object into ServerStorage.

Events

    ChildAdded(childobject)
    Triggered when a child object is added.

    ChildRemoved(childobject)
    Deletes all child objects.

    DescendantAdded(descendantobject)
    Triggered when a descendant is added.

    DescendantRemoved(descendantobject)
    Triggered when a descendant is removed.

    AncestryChanged(AncestryChanged)
    Triggered when the ancestry is changed.