Your concern about being “screwed over” is a legitimate concern. These things happen all the time. For that reason, your best strategy would be to consult with an attorney who can probably develop a checklist for you. But, in general, here are some things you should worry about.
Formation — the form of your business (partnership, LLC, C-Corp, etc.) will typically govern what happens when a founder leaves the business. So, depending on how your business is set up, a founder’s departure could dissolve the business or could change how the shares are split up. The form of your business will also determine how you need to formally exit.
Governing documents — you definitely need to check the governing documents (founders agreement, bylaws, articles of incorporation, etc.) to see if there are any conflicts that could arise upon your departure. Theoretically, the governing documents could provide contingencies for any situation and departure of a founder could be one. The governing documents could also spell out a procedure that needs to be followed in order for a founder to leave.
Interest — seems like an obvious point, but if you are worried about retaining your vested equity, you should carefully determine what your vested interest actually is. Once you know how your equity is calculated, you can better protect it against dilution. You also need to determine your level of interest in any intellectual property that you may have been involved with.
Contracts — your employment contract with the company could provide things that would bring trouble after you left. For example, it could contain a non-compete clause which would not allow you to work for a competitor. Also look at any stock agreements / vesting schedules to understand where you stand in terms of ownership percentage.
Again, these are only a few general things to keep in mind. The actual legal process of a founder leaving a startup is challenging and can lead to unfair results if not done properly. An experienced attorney can help you protect your interests. If you still have questions and want to learn more about how to protect yourself, you should visitwhere you can get a free consultation with an experienced attorney.