The Resource Manager component defines the map’s resource types and keeps track of all factions resources.
When you’re creating a new map using the RTS Engine menu editor, this component is attached to an object called “ResourceManager”.
- Resource Parent: All resources in the map must be children of one empty object that you drag and drop in this field at the sole exception of Resource Generator buildings since they don’t have an actual Resource component.
- Resource Info: A list that holds the available types of resources in this map. The amount of resource types you want to have in the map is the size of this list. Each resource type has a series of settings:
- Type: Drag and drop the Resource Type Info asset from the project tab into this field.
- Show UI: Show the local player the amount he has from this resource type in the UI? When disabled, the following two fields can be skipped.
- UI Image: The UI object with an “Image” component that shows the resource’s icon.
- UI Text: The UI object with a “Text” component that shows the resource’s current amount.
- Auto Collect: When disabled, the resource collectors will have to carry collected resources to a drop off building before they can be added to the and used by the faction. When enabled, the resources will be automatically added to the faction once collected.
- Resource Selection Color: This is the color of the selection texture of each resource that is shown when a resource is selected.