//
// Message.cpp
//

// Engine includes.
#include "Color.h"
#include "WorldManager.h"

// Game includes.
#include "Message.h"

Message::Message(std::string message) {

  setType("Message");
  setColor(df::RED);
  setViewString(message);
  setDrawValue(false);
  setBorder(false);

  // Put in center, top 1/3 of window.
  df::Vector p;
  p.setX(WM.getView().getHorizontal() * 1/2);
  if (getBorder())
    p.setY(WM.getView().getVertical() * 1/3);
  else 
    p.setY(WM.getView().getVertical() * 1/3 - 1);
  setPosition(p);
}

