This page has been translated automatically.
Programming
Fundamentials
Setting Up Development Environment
UnigineScript
High-Level Systems
C++
C#
UUSL (Unified UNIGINE Shader Language)
File Formats
Rebuilding the Engine and Tools
GUI
Double Precision Coordinates
API
Bounds-Related Classes
Containers
Controls-Related Classes
Core Library
Engine-Related Classes
GUI-Related Classes
Node-Related Classes
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
Rendering-Related Classes
Utility Classes
Внимание! Эта версия документация УСТАРЕЛА, поскольку относится к более ранней версии SDK! Пожалуйста, переключитесь на самую актуальную документацию для последней версии SDK.
Внимание! Эта версия документации описывает устаревшую версию SDK, которая больше не поддерживается! Пожалуйста, обновитесь до последней версии SDK.

WorldExternBase Class

Unigine Base WorldExtern class.

To use this class, include the UnigineWorldExtern.h file.

WorldExternBase Class

Members


int isOwner ()

Returns the owner flag of the pointer. If the pointer is owner, on its deletion the object also will be deleted.

Return value

The owner flag.

void grab ()

Sets the owner flag to 1 for the world pointer. The world should not be handled by the class after this function is called.

Ptr<Node> getNode ()

Returns the Node smart pointer.

Return value

Node smart pointer.

void renderVisualizer ()

Renders the visualizer.
Notice
You should enable the engine visualizer by the show_visualizer 1 console command.

void update (float ifps)

Update function. It is called when the node is visible.

Arguments

  • float ifps - Inverse FPS value.

void updatePosition ()

Updates a position of the external world.

int getClassID ()

Returns a unique class ID.

Return value

Unique class ID.

int saveWorld (const Ptr<Xml> & xml)

Saves a world state into the Xml.

Arguments

  • const Ptr<Xml> & xml - Xml smart pointer.

Return value

Returns 1 if the world state was successfully saved; otherwise, 0.

int restoreState (const Ptr<Stream> & stream)

Restores a world state from the stream.

Arguments

  • const Ptr<Stream> & stream - Stream smart pointer.

Return value

Returns 1 if the world state was successfully restored; otherwise, 0.

void flush (float ifps)

Flush function. It is called when the node is visible.

Arguments

  • float ifps - Inverse FPS value.

void renderHandler ()

Renders the handler for the external world.

int saveState (const Ptr<Stream> & stream)

Saves a world state into the stream.

Arguments

  • const Ptr<Stream> & stream - Stream smart pointer.

Return value

Returns 1 if the world state was successfully saved; otherwise, 0.

void release ()

Sets the owner flag to 0 for the world pointer. The world should be handled by the class after this function is called.

Ptr<WorldExtern> getWorldExtern ()

Returns the WorldExtern smart pointer.

Return value

WorldExtern smart pointer.

void updateEnabled ()

Updates enabled.

int loadWorld (const Ptr<Xml> & xml)

Loads a world state from the Xml.

Arguments

  • const Ptr<Xml> & xml - Xml smart pointer.

Return value

Returns 1 if the world state was successfully loaded; otherwise, 0.

void updateTransform ()

Updates transformation matrix of the external world.
Last update: 03.07.2017
Build: ()