It adds all the tools to the tools list.
1670 {
1671 int w = 33;
1672 int h = 33;
1673 string s = System.IO.Path.GetDirectoryName(Environment.ProcessPath) + "/";
1674 tools.Clear();
1675 if (tools.Count == 0)
1676 {
1677 int x = 0; int y = 0;
1678 foreach (Tool.Type t in (Tool.Type[])Enum.GetValues(typeof(Tool.Type)))
1679 {
1680 if (t != Type.script)
1681 if (t != Type.color1 && t != Type.color2)
1682 {
1683 Tool tool = new Tool(t, new ColorS(0, 0, 0));
1684 tool.bounds = new Rectangle(x * w, y * h, w, h);
1685 tool.image = new Pixbuf(s + "Images/" + tool.type.ToString() + ".png");
1686 tools.Add(tool.ToString(), tool);
1687 }
1688 else
1689 {
1690 Tool tool = new Tool(t, new ColorS(0, 0, 0));
1691 tool.bounds = new Rectangle(x * w, y * h, w, h);
1692 tools.Add(tool.ToString(), tool);
1693 }
1694 x++;
1695 if (x > Tools.gridW - 1)
1696 {
1697 x = 0;
1698 y++;
1699 }
1700 }
1701 }
1702 DrawColor = new ColorS(ushort.MaxValue, ushort.MaxValue, ushort.MaxValue);
1703 }