Skip to content
David Ricardo edited this page Jul 30, 2022 · 3 revisions

How to Create Items


Using BP

New Blueprint Class

image

Set WorldActor as Parent Class

image

Set the ID

image

We could initialize all the item by hand, but on this project, they are all being loaded from one DataTable using the previous ID.

More details about updating DataTable in the next section.

Recommended to set Static Mesh, to be visible on Client, otherwise, it will be only visible on Server.

If you are playing on Standalone Mode, it's recommended but not mandatory

image

Finally, it is possible to drag and drop our new item easily into the world.

image


Using C++

New C++ Class

image

Set WorldActor as Parent Class

image

Set a name and Create Class.

image image

On code, it will need necessary to set ID and StaticMesh for that Item.

We could initialize all the item by hand, but on this project, they are all being loaded from one DataTable using the previous ID.

More details about updating DataTable in the next section.

image

Finally, it is possible to drag and drop our new item easily into the world.

image


Updating DataTable

If you are loading the items' information through a DataTable, you will need to update it with the new item.

Add new row for our new item

image

Set all the information that you wish.

image

Both on BP and C++ Class, it's only necessary to set our ID.

Clone this wiki locally