using namespace PlaQui::Model;
-Drainage::Drainage(const std::string &_name):Drain(_name)
+Drainage::Drainage(const std::string &_name):Drain(_name),Control(_name)
{
in_slots = 1;
out_slots = 0;
void Drainage::simulate()
{
+ std::list<IConector *>::iterator i = in_list.begin();
+ if (i != in_list.end()) {
+ PlantItem *o = (PlantItem *)(*i);
+ set_color( o->get_color() );
+ }
std::cout << name << "::Flujo recibido = " << actual_flow << std::endl;
updated = false;
actual_flow = 0;
case MSG_QUERY_MAX_FLOW_OUT:
// FIXME Hacer INFINITO !!!
actual_flow = *((float *)data);
- std::cout << "DD" << std::endl;
tmp = 999999;
who->recieve_msg(MSG_RESPONSE_MAX_FLOW, this, &tmp);
updated = true;