Unity3D and Fungus Tutorial: PickUps
03 Create the PickUp Coins
Two Flowchart in a scene are independent, so how can make them communicate? In particular, we need to let the MainFlowchart know that a coin has been picked up, an event that at the moment is known only by the coin Flowchart.
The quickest way to communicate between _Flowchart_s is the Send Flowchart command, that sends a message that can be listened by the same Flowcart or by another one.
In our game, when a coin will be picked up, the corresponding Flowchart will send a message that will be intercepted by the MainFlowchart, that will store points gained.
Create your playground on Tech.io
This playground was created on Tech.io, our hands-on, knowledge-sharing platform for developers.