无尽地图
parent
63ee75cc2d
commit
2cb3065187
|
|
@ -17,7 +17,7 @@ public class SEndlessDifficulty implements BaseConfig{
|
|||
|
||||
private int[] rewardId;
|
||||
|
||||
private int[] mapPool;
|
||||
private int mapPool;
|
||||
|
||||
public static Map<Integer,SEndlessDifficulty> difficultyMap;
|
||||
|
||||
|
|
@ -78,7 +78,7 @@ public class SEndlessDifficulty implements BaseConfig{
|
|||
return rewardId;
|
||||
}
|
||||
|
||||
public int[] getMapPool() {
|
||||
public int getMapPool() {
|
||||
return mapPool;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -382,12 +382,14 @@ public class GlobalDataManaager {
|
|||
}
|
||||
private static int getEndleeMapIdByLevel() throws Exception {
|
||||
ServerConfig config = MongoUtil.getInstence().getMyMongoTemplate().findById(1, ServerConfig.class);
|
||||
// Map<Integer, SEndlessDifficulty> difficultyMap = SEndlessDifficulty.difficultyMap;
|
||||
// for(Map.Entry<Integer, SEndlessDifficulty> entry:difficultyMap.entrySet()){
|
||||
// if(entry.getValue().getWorldLevel())
|
||||
//
|
||||
// }
|
||||
int mapId = config.getWorldLevel() * 0 + 4001;
|
||||
int mapId = 4001;
|
||||
Map<Integer, SEndlessDifficulty> difficultyMap = SEndlessDifficulty.difficultyMap;
|
||||
for(Map.Entry<Integer, SEndlessDifficulty> entry:difficultyMap.entrySet()){
|
||||
if(config.getWorldLevel()>entry.getValue().getWorldLevel()[0]&&config.getWorldLevel()<=entry.getValue().getWorldLevel()[1]){
|
||||
mapId = entry.getValue().getMapPool();
|
||||
}
|
||||
|
||||
}
|
||||
return mapId;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue