绑定user
parent
96abec7248
commit
1262ac5fda
|
@ -1,6 +1,7 @@
|
|||
package com.ljsd.jieling.logic.dao;
|
||||
|
||||
import com.ljsd.common.mogodb.MongoBase;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
@ -10,9 +11,12 @@ public class AdventureStateInfo extends MongoBase {
|
|||
private int startTime;
|
||||
private int hourDuration;
|
||||
|
||||
public AdventureStateInfo(){}
|
||||
public AdventureStateInfo(){
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
}
|
||||
|
||||
public AdventureStateInfo(int position,List<String> heroIds, int startTime, int hourDuration) {
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
this.heroIds = heroIds;
|
||||
this.startTime = startTime;
|
||||
this.hourDuration = hourDuration;
|
||||
|
|
|
@ -3,6 +3,7 @@ package com.ljsd.jieling.logic.dao;
|
|||
import com.ljsd.common.mogodb.MongoBase;
|
||||
import com.ljsd.jieling.config.*;
|
||||
import com.ljsd.jieling.core.GlobalsDef;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
import com.ljsd.jieling.util.KeyGenUtils;
|
||||
import com.ljsd.jieling.util.MathUtils;
|
||||
import com.ljsd.jieling.util.UUIDEnum;
|
||||
|
@ -29,10 +30,11 @@ public class Equip extends MongoBase {
|
|||
|
||||
|
||||
public Equip() {
|
||||
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
}
|
||||
|
||||
public Equip(String uid, int equipTid) {
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
this.id = KeyGenUtils.produceIdByModule(UUIDEnum.EQUIP, uid);
|
||||
this.equipId = equipTid;
|
||||
this.propertyValueByIdMap = new HashMap<>();
|
||||
|
@ -50,6 +52,7 @@ public class Equip extends MongoBase {
|
|||
|
||||
//锻造
|
||||
public Equip(String uid, int equipTid,int workShopLevle,List<Integer> runneIds) {
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
this.id =KeyGenUtils.produceIdByModule(UUIDEnum.EQUIP,uid);
|
||||
this.equipId = equipTid;
|
||||
this.propertyValueByIdMap = new HashMap<>();
|
||||
|
|
|
@ -18,6 +18,7 @@ public class Item extends MongoBase {
|
|||
}
|
||||
|
||||
public Item(int itemId,int itemNum){
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
this.itemId = itemId;
|
||||
this.itemNum = itemNum;
|
||||
this.endingTime = (int)(System.currentTimeMillis()/1000);
|
||||
|
|
|
@ -20,6 +20,7 @@ public class Pokemon extends MongoBase {
|
|||
}
|
||||
|
||||
public Pokemon(int id){
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
this.id = id;
|
||||
this.comonpentsLevelMap = new HashMap<>();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue