]> ruin.nu Git - hbs.git/blobdiff - bs/planet.cpp
emp works now too..
[hbs.git] / bs / planet.cpp
index 41d92ac51eb2ed6004bab3b01c8009a46b8fdefb..8fd1726b3979c4d287eb004597758315c762a28b 100644 (file)
@@ -103,16 +103,18 @@ void Planet::runBattle(std::vector<Fleet*> friendly, std::vector<Fleet*> hostile
                        skipped = 0;
 
                Planet allFriends;
-               allFriends.addToThis(friends);
+               allFriends.addToThis(friends, tick);
                
                Fleet allHostiles;
-               allHostiles.addToThis(hostiles);
+               allHostiles.addToThis(hostiles, tick);
 
                map<string, map<string, int> > stealfriendly;
                map<string, map<string, int> > stealhostile;
                
                calcOneTick(&allFriends, &allHostiles, stealfriendly, stealhostile );
 
+               //allFriends.printFleet();
+
                allFriends.distributeLossesGains(friends, tick);
                allHostiles.distributeLossesGains(hostiles, tick);
        }
@@ -133,7 +135,7 @@ void Planet::calcOneTick(Planet* friendly, Fleet* hostile, std::map<std::string,
                
                string unittype = i->second;
 
-               cerr << "Initiative: " << s_Units[unittype].initiative() << " with unit: " << unittype << endl;
+               //cerr << "Initiative: " << s_Units[unittype].initiative() << " with unit: " << unittype << endl;
 
                if (s_Units[unittype].type() == "EMP")  
                {