aboutsummaryrefslogtreecommitdiff
path: root/games/asc/files/patch-source::ai::misc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'games/asc/files/patch-source::ai::misc.cpp')
-rw-r--r--games/asc/files/patch-source::ai::misc.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/games/asc/files/patch-source::ai::misc.cpp b/games/asc/files/patch-source::ai::misc.cpp
new file mode 100644
index 000000000000..e16c1d738031
--- /dev/null
+++ b/games/asc/files/patch-source::ai::misc.cpp
@@ -0,0 +1,23 @@
+
+$FreeBSD$
+
+--- source/ai/misc.cpp 2002/10/18 11:37:58 1.1
++++ source/ai/misc.cpp 2002/10/18 11:41:35
+@@ -86,7 +86,7 @@
+
+ float value = veh->aiparam[getPlayerNum()]->getValue();
+ if ( veh->typ->movement[j] )
+- value *= log( veh->typ->movement[j] );
++ value *= log( (double)veh->typ->movement[j] );
+
+ float threat = sec.avgFieldThreat.threat[ veh->aiparam[getPlayerNum()]->valueType ];
+ if ( minAvgFieldThreat > 0 ) {
+@@ -834,7 +834,7 @@
+ danger = enemyThreat.threat[ typ->aiparam[getPlayerNum()]->valueType] / typ->aiparam[getPlayerNum()]->getValue();
+ }
+
+- rating /= 1 + log ( danger );
++ rating /= 1 + log ( (double)danger );
+
+ int cost = 0;
+ for ( int j = 0; j < resourceTypeNum; j++ )