So here's an idea:
Offer :
1) To pay a programmer $xyz per hour, to be paid if terminated short of the destiny.
And to pay that much at some specific payday when the success of the project can be measured.
State what success means and how to measure.
2) Pay the programmer along the...