The oil is used in cooking , as well as cosmetics , traditional medicine , and as a fuel for oil lamps . It is commonly used in cooking , cosmetics , pharmaceuticals , and soaps and as a fuel for traditional oil lamps .