When a company files for bankruptcy there is no guarantee that they will be able to satisfy any of their debts. Assuming chapter 7 bankruptcy, the employees with unpaid wages become creditors. Assets will be liquidated and creditors will be paid based on priority. Employees with unpaid wages are high on the priority list, but not always at the top. If the company has no/insufficient assets then those employees would go unpaid.
There's not much you can do to guarantee your pay. If you are still working for them hopefully that gives you some leverage. Something like, "I understand things are tight, but if you can pay me 80% of my back-pay now then I can keep working." You'd have to know how dire things are to know what is reasonable to ask for. Meanwhile you should definitely be seeking other employment. Even if they do pay you, I'd seek other employment. If you aren't still working for them or they have absolutely no cash on hand, then likely you'll either be out of luck or have to wait for the dust to settle in bankruptcy.
An attorney could be worthwhile here, there are instances where the owner of the company can be held liable, but you can't squeeze blood from a turnip.