Exemplo n.º 1
0
void ColorPalette::refresh(void) {
	selected.setFillColor(color);
	label.setColor(color);

	label.setString(ColorPalette::interpret(color, str));

	rgb_c.setOutlineColor(Utility::Color::getInverseColor(color));
	bw_c.setOutlineColor(Utility::Color::getInverseColor(color));
}
Exemplo n.º 2
0
 // Draw a ring around the object to show it's selected
 inline void set_select_state(bool select)
 {
     select_state = select;
     if (select)
     {
         circ.setOutlineColor(sf::Color::Green);
         circ.setOutlineThickness(OBJECT_SIZE/5);
     }
     else
     {
         circ.setOutlineColor(sf::Color::Black);
         circ.setOutlineThickness(OBJECT_SIZE/10);
     }
 }
Exemplo n.º 3
0
		void createGeometry() {
			fill = type == Type::Follower ? sf::Color(198, 156, 109, 255) : sf::Color(0, 191, 243, 255);
			outline = type == Type::Follower ?  sf::Color(166, 124, 82, 255) : sf::Color(64, 140, 203, 255);

			geometry.setRadius(radius);
			geometry.setPointCount(6);
			geometry.setFillColor(fill);
			geometry.setOutlineColor(outline);
			geometry.setOutlineThickness(2);
			geometry.setOrigin(radius, radius);
		}
Exemplo n.º 4
0
static void init(sf::RenderWindow &window)
{
	window.setMouseCursorVisible(false);
	window.setVerticalSyncEnabled(true);

	crosshair.setFillColor(sf::Color(0, 0, 0, 0));
	crosshair.setOutlineColor(sf::Color(0, 0, 0));
	crosshair.setOutlineThickness(2.0f);

	srand(static_cast<unsigned>(time(0)));
}