This tutorial shows you how to create custom items for the player to pickup that will go into their inventory, e.g. the evidence on Aquatone, the relics on Theatre, etc.
These can be used as objective items, e.g. Find at least 3 relics.
Make sure ThieveryMod.u and ThieveryObjects.u are both loaded.
Making your custom class
Customising your object
- Open the class browser and navigate to Actor->Inventory->Pickup->ThieveryPickup->ThPickupObjectiveItem.
- Right click on ThPickupObjectiveItem and choose "New".
- Enter "MyLevel" as the package.
- Choose a meaningful name for the class, e.g. "ThPickupMagicRuby" if you are making a special ruby for people to collect.
You will want to give your item the correct mesh, sounds and names:
Placing your item
- In the actor browser, navigate back to the custom class you made, it will be under ThPickupObjectiveItem.
- Right click on it and choose "default properties". This is where you can change the item's appearance. Note, if there is a already a loot item or something with the appearance you want, it's a good idea to bring up the default properties of that item too, so you can copy the Mesh and other values across.
- First of all you should change the mesh. This has to be done in a number of places, firstly under Display->Mesh. You also have to change it under Inventory->PickupViewMesh and Inventory->PlayerViewMesh. PickupViewMesh is the appearance of the item when it is on the map, PlayerViewMesh is the appearance when you are holding it. There are also scale values there you can alter if you want to change the object's size.
- Next, change the collision cylinder. Under Collision, put in the correct CollisionRadius and CollisionHeight.
- Set the names and messages. Under ThieveryPickup, set the HUDName, this is the name that comes up underneath the item in the corner. Under Inventory, you should set the PickupMessage as desired.
- You may also like to set the Inventory->PickupSound to something special that fits the item.
Your item is now ready to drop into the level as normal, or with a loot spawner. Note: If you change any properties at a later date, be sure to change them in the default properties of your class (as well as the actual object placed on the map).