if your guna do it yourself mate, start with the basics.
Time it to TDC and check the cam belt timing. Obviously if thats out it will cause problems, if not you need find why it won't idle right and so forth, ignition timing will be tricky if the engine isn't running right.
But in the long run yes you want to set the ignition timing to standard settings and then take it to have the emissions set up.