Whether or not you are entitled to be paid for unused flexi-leave depends on your contract of employment.
Many contracts now include 'flexi-time' or 'flexi-leave' arrangements. These involve employees working extra hours and then taking these hours as time off in lieu (TOIL) at a later date, or sometimes taking the time off in advance and making it up at a later date, within whatever scheme rules have been agreed.
In workplaces where a union is recognised, there may be a collective agreement in place on flexi-time.
In general, you are not entitled to be paid for flexi-time you have built up but have not used, unless your scheme rules say something different, even on dismissal.