pingus-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pingus-CVS] r4160 - in branches/pingus-hanusz/src: . components


From: grumbel
Subject: [Pingus-CVS] r4160 - in branches/pingus-hanusz/src: . components
Date: Wed, 25 May 2011 15:52:19 +0200

Author: grumbel
Date: 2011-05-25 15:52:19 +0200 (Wed, 25 May 2011)
New Revision: 4160

Modified:
   branches/pingus-hanusz/src/components/pingus_counter.cpp
   branches/pingus-hanusz/src/result_screen.cpp
   branches/pingus-hanusz/src/start_screen.cpp
Log:
Added PINGUS_MODE_NEUTRAL changes

Modified: branches/pingus-hanusz/src/components/pingus_counter.cpp
===================================================================
--- branches/pingus-hanusz/src/components/pingus_counter.cpp    2011-05-25 
13:44:26 UTC (rev 4159)
+++ branches/pingus-hanusz/src/components/pingus_counter.cpp    2011-05-25 
13:52:19 UTC (rev 4160)
@@ -47,19 +47,27 @@
   World* world = server->get_world();
 
 #ifdef PINGUS_MODE_EVIL
-    snprintf(str, 128, _("Released:%3d/%d   Out:%3d   Killed:%3d/%d").c_str(),
-             world->get_pingus()->get_number_of_released(),
-             world->get_pingus()->get_number_of_allowed(),
-             world->get_pingus()->get_number_of_alive(),
-             world->get_pingus()->get_number_of_killed(),
-             server->get_plf().get_number_to_save());    
+  snprintf(str, 128, _("Released:%3d/%d   Out:%3d   Killed:%3d/%d").c_str(),
+           world->get_pingus()->get_number_of_released(),
+           world->get_pingus()->get_number_of_allowed(),
+           world->get_pingus()->get_number_of_alive(),
+           world->get_pingus()->get_number_of_killed(),
+           server->get_plf().get_number_to_save());
+#elif PINGUS_MODE_NEUTRAL
+  snprintf(str, 128, _("Released:%3d/%d   Out:%3d   Scored:%3d/%d").c_str(),
+           world->get_pingus()->get_number_of_released(),
+           world->get_pingus()->get_number_of_allowed(),
+           world->get_pingus()->get_number_of_alive(),
+           world->get_pingus()->get_number_of_exited(),
+           server->get_plf().get_number_to_save());
+
 #else
-    snprintf(str, 128, _("Released:%3d/%d   Out:%3d   Saved:%3d/%d").c_str(),
-             world->get_pingus()->get_number_of_released(),
-             world->get_pingus()->get_number_of_allowed(),
-             world->get_pingus()->get_number_of_alive(),
-             world->get_pingus()->get_number_of_exited(),
-             server->get_plf().get_number_to_save());
+  snprintf(str, 128, _("Released:%3d/%d   Out:%3d   Saved:%3d/%d").c_str(),
+           world->get_pingus()->get_number_of_released(),
+           world->get_pingus()->get_number_of_allowed(),
+           world->get_pingus()->get_number_of_alive(),
+           world->get_pingus()->get_number_of_exited(),
+           server->get_plf().get_number_to_save());
 #endif
 
   gc.print_center(font, gc.get_width()/2, -1, str);

Modified: branches/pingus-hanusz/src/result_screen.cpp
===================================================================
--- branches/pingus-hanusz/src/result_screen.cpp        2011-05-25 13:44:26 UTC 
(rev 4159)
+++ branches/pingus-hanusz/src/result_screen.cpp        2011-05-25 13:52:19 UTC 
(rev 4160)
@@ -201,6 +201,18 @@
                      "maybe you can do better?");
       else
         message = _("Not everybody was killed, but still good work!");
+#elif PINGUS_MODE_NEUTRAL
+       if (result.killed == 0 && result.saved == result.total)
+         message = _("Perfect! You have got a perfect score!");
+       else if (result.killed == 0)
+         message = _("Pretty good work.");
+       else if (result.saved == result.needed)
+         message = _("You scored exactly what you needed - you made it, but\n"
+                     "maybe you can do better?");
+       else if (result.killed >= 5)
+         message = _("Good work!");
+       else
+         message = _("What can I say, you made it - congratulations!");
 #else
       if (result.killed == 0 && result.saved == result.total)
         message = _("Perfect! You saved everyone possible - great!");
@@ -222,6 +234,19 @@
         message = _("You are not a killer, aren't you.");
       else
         message = _("Better luck next time!");
+#elif PINGUS_MODE_NEUTRAL
+      if (result.killed == result.total)
+        message = _("Not good.");
+      else if (result.saved == 0)
+        message = _("I know you can do better.");
+      else if (result.saved > 0)
+        message = _("Next time you might do better.");
+      else if (result.saved + 1 >= result.needed)
+        message = _("Only one more and you would have made it - try again!");
+      else if (result.saved + 5 >= result.needed)
+        message = _("Only a handful more and you would have made it - try 
again!");
+      else
+        message = _("Better luck next time!");     
 #else
       if (result.killed == result.total)
         message = _("You killed everybody, not good.");
@@ -256,16 +281,23 @@
 #ifdef PINGUS_MODE_EVIL
   gc.print_left(Fonts::chalk_normal,  left_x,  y, _("Killed: "));
   gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(result.killed)
-                  + "/" + StringUtil::to_string(result.needed));;
+                  + "/" + StringUtil::to_string(result.needed));
+#elif PINGUS_MODE_NEUTRAL
+  gc.print_left(Fonts::chalk_normal,  left_x,  y, _("Scored: "));
+  gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(result.saved)
+                 + "/" + StringUtil::to_string(result.needed));  
 #else
   gc.print_left(Fonts::chalk_normal,  left_x,  y, _("Saved: "));
   gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(result.saved)
-                 + "/" + StringUtil::to_string(result.needed));;
+                 + "/" + StringUtil::to_string(result.needed));
 #endif
 
 #ifdef PINGUS_MODE_EVIL
   gc.print_left(Fonts::chalk_normal,  left_x,  (y+=30), _("Survived: "));
   gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(result.saved));
+#elif PINGUS_MODE_NEUTRAL
+  gc.print_left(Fonts::chalk_normal,  left_x,  (y+=30), _("Lost: "));
+  gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(result.killed));
 #else
   gc.print_left(Fonts::chalk_normal,  left_x,  (y+=30), _("Died: "));
   gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(result.killed));

Modified: branches/pingus-hanusz/src/start_screen.cpp
===================================================================
--- branches/pingus-hanusz/src/start_screen.cpp 2011-05-25 13:44:26 UTC (rev 
4159)
+++ branches/pingus-hanusz/src/start_screen.cpp 2011-05-25 13:52:19 UTC (rev 
4160)
@@ -160,11 +160,18 @@
   y += 32;
   y += 30;
 
+#ifdef PINGUS_MODE_NEUTRAL
+  gc.print_left (Fonts::chalk_normal, left_x,  y, _("Number of Balls: "));
+#else
   gc.print_left (Fonts::chalk_normal, left_x,  y, _("Number of Pingus: "));
+#endif
+
   gc.print_right(Fonts::chalk_normal, right_x, y, 
StringUtil::to_string(plf.get_number_of_pingus()));
 
 #ifdef PINGUS_MODE_EVIL
   gc.print_left (Fonts::chalk_normal, left_x,  (y += 30), _("Number to Kill: 
"));
+#elif PINGUS_MODE_NEUTRAL
+  gc.print_left (Fonts::chalk_normal, left_x,  (y += 30), _("Number to Win: 
"));
 #else
   gc.print_left (Fonts::chalk_normal, left_x,  (y += 30), _("Number to Save: 
"));
 #endif




reply via email to

[Prev in Thread] Current Thread [Next in Thread]