summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Mahone <andrew.mahone@gmail.com>2008-12-11 01:53:48 +0000
committerAndrew Mahone <andrew.mahone@gmail.com>2008-12-11 01:53:48 +0000
commit5a7454e8785d6044b91cfef32a60b173b41f9cdf (patch)
treeb0901d428cd2ef679a4f48b943d484659b650e4d
parent2e8266df12c66667da1403abf36b2a67254ea163 (diff)
downloadrockbox-5a7454e8785d6044b91cfef32a60b173b41f9cdf.tar.gz
rockbox-5a7454e8785d6044b91cfef32a60b173b41f9cdf.zip
add yields in superdom, patch from FS#7528
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19389 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/plugins/superdom.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/apps/plugins/superdom.c b/apps/plugins/superdom.c
index d375879eb5..c9ad603d8b 100644
--- a/apps/plugins/superdom.c
+++ b/apps/plugins/superdom.c
@@ -1808,6 +1808,7 @@ void computer_allocate(void) {
}
}
}
+ rb->yield();
}
}
if(offensive) {
@@ -1837,6 +1838,7 @@ void computer_allocate(void) {
i, j));
k++;
}
+ rb->yield();
}
}
}
@@ -1903,6 +1905,7 @@ void computer_allocate(void) {
}
compres.bank += compres.cash;
compres.cash = 0;
+ rb->yield();
}
} else {
/* Work out what to place on each square to defend it.
@@ -1933,6 +1936,7 @@ void computer_allocate(void) {
draw_board();
rb->sleep(HZ);
}
+ rb->yield();
}
} else if((total_str_diff+20)*15 < compres.cash) {
/* Enough money to pay their way by planes */
@@ -1966,6 +1970,7 @@ void computer_allocate(void) {
}
}
}
+ rb->yield();
}
} else {
/* Tanks it is */
@@ -1999,6 +2004,7 @@ void computer_allocate(void) {
}
}
}
+ rb->yield();
}
}
compres.bank += compres.cash;
@@ -2082,6 +2088,7 @@ void computer_war(void) {
}
}
}
+ rb->yield();
}
}
if(compres.moves) {
@@ -2120,6 +2127,7 @@ void computer_war(void) {
compres.moves--;
}
}
+ rb->yield();
}
}
while(compres.moves > 0) {