Clear[molecule,@maxbl,@natom,@nbond,@bond,@bonds,@i,@species,@gr1,@gr2,@spec,
@@@@h,@c,@o,@n,@f,@cl,@br,@fe,@pt,@pnth,@pntc,@pnto,@pntn,@pntf,@pntcl,@pntbr,
@@@@@pntfe,@pntpt,@pts];

makebond[natom_,@molecule_,@nbond_,@bond_,@maxbl_]@:=@Module[{a,@b,@i,@j},
@@@@@@nbond@=@0;
@@@@@@bond@=@{};
@@@@@@natom@=@Length[molecule];
@@@@@@
@@@@@@Do[
@@@@@@@@Do[a@=@Rest[molecule[[i]]]@-@Rest[molecule[[j]]];
@@@@@@@@@@@@b@=@Sqrt[a.a];
@@@@@@@@@@@@If[b@<=@maxbl,@nbond@=@nbond@+@1;
@@@@@@@@@@@@@@bond@=@AppendTo[bond,@{i,@j}];,]
@@@@@@@@@@@@,@{j,@i@+@1,@natom}];
@@@@@@@@,@{i,@1,@natom}];
@@@@@@];

maxbl@=@1.7(*@max@bond@length@*);

(*@input@part@*)
molecule@=@{
@@@@@@{C,@-1.696121,@-0.670059,@0.95253},
@@@@@@{C,@-0.536362,@-0.580063,@-0.054153},
@@@@@@{C,@0.804138,@-0.649002,@0.680466},
@@@@@@{O,@1.882385,@-0.633392,@-0.256516},
@@@@@@{C,@-0.660538,@0.704819,@-0.8898},
@@@@@@{H,@-2.683273,@-0.655655,@0.435883},
@@@@@@{H,@-1.674377,@0.183929,@1.667435},
@@@@@@{H,@-1.644943,@-1.611786,@1.545654},
@@@@@@{H,@-0.605133,@-1.457214,@-0.744766},
@@@@@@{H,@0.892853,@-1.589417,@1.271454},
@@@@@@{H,@0.936813,@0.217331,@1.3676},
@@@@@@{H,@2.683273,@-0.693283,@0.236496},
@@@@@@{H,@0.134613,@0.766891,@-1.66745},
@@@@@@{H,@-0.582062,@1.6118,@-0.24794},
@@@@@@{H,@-1.639893,@0.74649,@-1.4198}
@@@@@@};
(*@input@end@*)

makebond[natom,@molecule,@nbond,@bond,@maxbl];

spec@=@{};
Do[AppendTo[spec,@Part[molecule[[i]],@1]];,@{i,@1,@natom}];

(*@determine@atom@colors@and@size@*)

h@=@{RGBColor[0.3,@0.8,@1],@PointSize[0.05]};
c@=@{GrayLevel[0.4],@PointSize[0.10]};
o@=@{RGBColor[0.8,@0.2,@0.5],@PointSize[0.10]};
b@=@{RGBColor[0.8,@0.5,@0.5],@PointSize[0.10]};
n@=@{RGBColor[0.5,@0.8,@0.5],@PointSize[0.10]};
f@=@{RGBColor[0.2,@0.5,@0.8],@PointSize[0.10]};
cl@=@{RGBColor[0.5,@0.2,@0.8],@PointSize[0.10]};
br@=@{RGBColor[0.5,@0.8,@0.2],@PointSize[0.10]};
fe@=@{RGBColor[0.2,@0.2,@0.2],@PointSize[0.10]};
pt@=@{RGBColor[0.8,@0.8,@0.8],@PointSize[0.10]};
@
pnth@=@{};@pntc@=@{};@pnto@=@{};@pntn@=@{};@pntf@=@{};
pntcl@=@{};@pntbr@=@{};@pntfe@=@{};@pntpt@=@{};

Do[
@@@@If[spec[[i]]@==@H,@pnth@=@AppendTo[h,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@C,@pntc@=@AppendTo[c,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@O,@pnto@=@AppendTo[o,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@N,@pntn@=@AppendTo[n,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@F,@pntf@=@AppendTo[f,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@Cl,@pntcl@=@AppendTo[cl,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@Br,@pntbr@=@AppendTo[br,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@Fe,@pntfe@=@AppendTo[fe,@Point[Rest[molecule[[i]]]]],];
@@@@If[spec[[i]]@==@Pt,@pntpt@=@AppendTo[pt,@Point[Rest[molecule[[i]]]]],];
@@@@,@{i,@1,@natom}];
pts@=@{pnto,@pnth,@pntc,@pntn,@pntf,@pntcl,@pntbr,@pntfe,@pntpt};
gr0@=@Graphics3D[pts];

bonds@=@Table[Line[{Rest[molecule[[bond[[i]][[1]]]]]
@@@@@@@@@@,@Rest[molecule[[bond[[i]][[2]]]]]}],@{i,@1,@nbond}];

gr1@=@Graphics3D[{Thickness[0.01],@GrayLevel[0.10],@bonds}];

species@=@
@@@@Table[Text[First[molecule[[i]]],@Rest[molecule[[i]]]],@{i,@1,@natom}];
gr2@=@Graphics3D[species];

Show[gr0,@gr2,@gr1,@ViewPoint@->@{0,@0,@3},@PlotRange@->@All,@Boxed@->@False]