示例#1
0
文件: ogre_obj.hpp 项目: dvbuntu/ogre
 // 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);
     }
 }
示例#2
0
文件: main.cpp 项目: Windsdon/zombie
		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);
		}
示例#3
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)));
}