Changeset 457e9a7b5ef93afd2f8d200c55907734744983ad

Show
Ignore:
Timestamp:
09/09/07 18:35:14 (1 year ago)
Author:
Christopher Jung <bktheg@web.de>
git-committer:
Christopher Jung <bktheg@web.de> 1189355714 +0200
git-parent:

[6e3b14935474012cbccb2c44c6a0d53a632c9023]

git-author:
Christopher Jung <bktheg@web.de> 1189355714 +0200
Message:

Werften: Moduleinbau gefixt

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • src/net/driftingsouls/ds2/server/werften/WerftObject.java

    r7131457 r457e9a7  
    535535                org.hibernate.Session db = ContextMap.getContext().getDB(); 
    536536                 
    537                 int jdockcount = (Integer)db.createQuery("select count(*) from Ship where docked=? and id>0") 
     537                long jdockcount = (Long)db.createQuery("select count(*) from Ship where docked=? and id>0") 
    538538                        .setString(0, "l "+ship.getId()) 
    539539                        .iterate().next(); 
     
    541541                        List ships = db.createQuery("from Ship where docked=? and id>0") 
    542542                                .setString(0, "l "+ship.getId()) 
    543                                 .setMaxResults(jdockcount-shiptype.getJDocks()) 
     543                                .setMaxResults((int)(jdockcount-shiptype.getJDocks())) 
    544544                                .list(); 
    545545                         
     
    557557                } 
    558558                                 
    559                 int adockcount = (Integer)db.createQuery("select count(*) from Ship where docked=? and id>0") 
     559                long adockcount = (Long)db.createQuery("select count(*) from Ship where docked=? and id>0") 
    560560                        .setString(0, Integer.toString(ship.getId())) 
    561561                        .iterate().next(); 
     
    563563                        List ships = db.createQuery("from Ship where docked=? and id>0") 
    564564                                .setString(0, Integer.toString(ship.getId())) 
    565                                 .setMaxResults(adockcount-shiptype.getADocks()) 
     565                                .setMaxResults((int)(adockcount-shiptype.getADocks())) 
    566566                                .list(); 
    567567