class_meshlibrary - dragonsoulz/godot GitHub Wiki
MeshLibrary
####Inherits: Resource ####Category: Core
Brief Description
Library of meshes.
Member Functions
- void create_item ( int id )
- void set_item_name ( int id, String name )
- void set_item_mesh ( int id, Mesh mesh )
- void set_item_shape ( int id, Shape shape )
- String get_item_name ( int id ) const
- Mesh get_item_mesh ( int id ) const
- Shape get_item_shape ( int id ) const
- void remove_item ( int id )
- void clear ( )
- IntArray get_item_list ( ) const
- int get_last_unused_item_id ( ) const
Description
Library of meshes. Contains a list of Mesh resources, each with name and ID. Useful for GridMap or painting Terrain.
Member Function Description
create_item
- void create_item ( int id )
Create a new item in the library, supplied an id.
set_item_name
Set the name of the item.
set_item_mesh
Set the mesh of the item.
get_item_name
Return the name of the item.
get_item_mesh
Return the mesh of the item.
remove_item
- void remove_item ( int id )
Remove the item.
clear
- void clear ( )
Clear the library.
get_item_list
- IntArray get_item_list ( ) const
Return the list of items.
get_last_unused_item_id
- int get_last_unused_item_id ( ) const
Get an unused id for a new item.