Adding More Fuses / Boxes
Last updated
Last updated
Adding Additional Collectable Fuses:
Add your 3D Object that will act as a fuse to collect
Give this a tag of "InteractiveObject"
Give this object a "Box Collider"
Add a "CPItem" script and set this to "Chess Fuse"
Add a "CPFuseCollectable" script
Set the ChessPieceScriptable to a new SO you will create (See below)
Add the sound effect you desire
Creating a new ScriptableObject Fuse:
Visit the "ScriptableObjects" folder and find "ChessPieces":
Duplicate a current fuse and rename it
Click on this new SO and add:
A sprite so it can be used in the inventory
A prefab which will spawn in the fuse box
Adding another Fuse Box:
Duplicated a pre existing fuse box and make sure the setup is as below:
Give this an "InteractiveObject" tag
Add a "Box Collider"
Add a "CPItem" script and set this to "Fusebox"
Add a "CPFuseBoxInteractable" script
Add the Chess Piece Scriptable that will go with this Fusebox
Choose whether to have one inside it at the start
Add the empty GameObject as the spawn location of the fuse
Add the fuse light which will be a child of this object
Add the power manager that corresponds to your current set
Add an audio effect