Lawyer FIRST. Illegal search may be your only defense if it gets that far, but in a first-offense case like that I personally would be trying to avoid going to trial at ALL. Best of luck to you and your friends, but they should have known better than to be smoking in an apartment complex with a grow in it and no odor control.
I hope you all get off with a quick smack on the wrist. Start putting together some character references right away to give to your attorney to better help him butter up the DA and push for a probation deal with no jail time.