In this tutorial you will learn how to overlap components over one another. So, let’s keep it short here and get straight to the point
For this tutorial, I’m using the components listed below, but you can change them as per your needs.
- Horizontal_Arrangement2(Color: Translucent pink)
- So, first of all, we will trigger the
when Checkbox1.Changedevent. If it’s checked we will call the
Overshoot Verticalmethod from the Animation Util component for overlapping HVA2 (Horizontal Arrangement2) over HVA1 (Horizontal Arrangement1) or else we will remove them from each other.
- In the first case, the value of
For example: If Y position of HVA1 is 406 and that of HVA2 is 596 then the result will be -190. And so HA2 will move 190 units vertically above (above because it is negative) from its original position, overlapping the HVA1.
Note: You can play with the blocks to define how much one arrangement will overlap with other.
- The blocks in the
elsesocket are just for testing purpose and hence, are redundant, so, I’m not going to explain it (but if you understood the above blocks you would understand this too).
So, it worked.