Creating a new Resource =========================================== To set up a new resource, you need to create a ``ResourceData`` asset in the **Project Manager** window: .. image:: create-resource-data.png :width: 600px :align: center In this data, you can set up the ``text Id`` and ``Icon`` fields. .. warning:: Currently, these fields are not used by the asset, but you can use them from your own code for UI and other purposes. Future asset versions will introduce a more feature-packed Multi-resources system. After this, you need to add the new resource to the **Game Settings**: .. image:: add-resource-data-to-game-settings.png :width: 600px :align: center Now you can use your resource data in different asset settings by simply linking your created ``ResourceData`` asset in the fields: .. image:: resource-data-usage-example.png :width: 600px :align: center How to use Resource system from code **************************************** .. note:: More info about this will be added to the Scripting API and Programming partitions soon. ``Player`` class contains these methods to work with resources: .. code-block:: csharp // to get resource id, use method resourceData.GetResourceId() public void SetResource(string id, int amount) public int GetResourceAmount(string id) public void AddResource(string id, int amount) public void SpendResource(string id, int amount) // etc. .. toctree::