Changeset 97537f776ae16a64662ba0dd7c796ff62c3b3ffe
- Timestamp:
- 04/29/07 23:28:50
(2 years ago)
- Author:
- Christopher Jung <bktheg@web.de>
- git-committer:
- Christopher Jung <bktheg@web.de> 1177882130 +0200
- git-parent:
[7365c4b17fcdb4d30ef7f9f9202d9817ab400b61]
- git-author:
- Christopher Jung <bktheg@web.de> 1177882130 +0200
- Message:
linfactor gefixt
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| rf700e8e |
r97537f7 |
|
| 1221 | 1221 | |
|---|
| 1222 | 1222 | // Kosten anpassen |
|---|
| 1223 | | if( shipdata.getInt("linfactor") > 0 ) { |
|---|
| | 1223 | if( shipdata.getDouble("linfactor") > 0 ) { |
|---|
| 1224 | 1224 | int count = db.first("SELECT count(*) count FROM ships WHERE id>0 AND type=",shipdata.getInt("type")," AND owner=",user.getID()).getInt("count"); |
|---|
| 1225 | 1225 | int count2 = db.first("SELECT count(t1.id) count FROM werften t1 JOIN bases t2 ON t1.col=t2.id WHERE t1.building=",shipdata.getInt("type")," AND t2.owner=",user.getID()).getInt("count"); |
|---|
| … | … | |
| 1227 | 1227 | |
|---|
| 1228 | 1228 | count = count + count2 + count3; |
|---|
| 1229 | | ((Cargo)shipdata.get("costs")).multiply( shipdata.getInt("linfactor")*count+1, Cargo.Round.NONE ); |
|---|
| | 1229 | ((Cargo)shipdata.get("costs")).multiply( shipdata.getDouble("linfactor")*count+1, Cargo.Round.NONE ); |
|---|
| 1230 | 1230 | } |
|---|
| 1231 | 1231 | } |
|---|