You probably should do what Luke (and every other freelancer I've ever heard talk about this) says and run.
Unless...
The web design and Ap would not be a lot of work on your part and you'd like to do them anyhow for the experience.
It's probably a form of mental illness on my part, but I'm very entrepreneurial and always very tempted by sharing profits. In fact, I prefer that idea to being paid hourly for something I create.
If you don't mind rolling the dice you might go for it, but understand you ARE rolling the dice and you probably will lose.
I have no ideas how the legal side of this works. How do you know what their profits are? I have an agreement with a company that wants to resell some of my software for a percentage that says they can see my books if they want. How else would they know if I am being honest? I also have software on my website (FastSpring) that will automatically redirect a percentage of sales to others. But even that I could change on them if I wanted, so there has to be trust and legal paperwork that makes you a partner and gives you the right to audit their books.
Also - if they have NO budget, they are either:
1. Not good business people
2. brand new with no track record - you have no way of knowing if they'll ever sell a single thing. Most new businesses fail. OR
3. They do have money but are not confident enough in this website and app to risk their own money on it.
Personally, Many of my most profitable business ventures came from saying YES! to an opportunity from a near stranger where really I was mostly helping them out, but it led over time to greater things. So you don't want to be too closed off to opportunity. But don't get stars in your eyes and think this company with no budget and no track record is going to make you a lot of money. If you go for it, be emotionally prepared to waste your time.
Hopefully someone else can tell you how you could legally assure they're honest regarding profits. And profits should be a percentage of the sale price of the app, not a percentage of their actual "profit" 'cause they could make a bundle and spend it on other expenses and have no "profit" to speak of.