本文整理汇总了Java中com.shatteredpixel.shatteredpixeldungeon.GamesInProgress类的典型用法代码示例。如果您正苦于以下问题:Java GamesInProgress类的具体用法?Java GamesInProgress怎么用?Java GamesInProgress使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
GamesInProgress类属于com.shatteredpixel.shatteredpixeldungeon包,在下文中一共展示了GamesInProgress类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: preview
import com.shatteredpixel.shatteredpixeldungeon.GamesInProgress; //导入依赖的package包/类
public static void preview( GamesInProgress.Info info, Bundle bundle ) {
info.level = bundle.getInt( LEVEL );
}
示例2: updateClass
import com.shatteredpixel.shatteredpixeldungeon.GamesInProgress; //导入依赖的package包/类
private void updateClass( HeroClass cl ) {
if (curClass == cl) {
add( new WndClass( cl ) );
return;
}
if (curClass != null) {
shields.get( curClass ).highlight( false );
}
shields.get( curClass = cl ).highlight( true );
if (cl != HeroClass.HUNTRESS || huntressUnlocked) {
unlock.visible = false;
float buttonPos = (Camera.main.height + HEIGHT) / 2 - BUTTON_HEIGHT;
float left = (Camera.main.width - WIDTH) / 2;
GamesInProgress.Info info = GamesInProgress.check( curClass );
if (info != null) {
btnLoad.visible = true;
btnLoad.secondary( Utils.format( TXT_DPTH_LVL, info.depth, info.level ) );
btnNewGame.visible = true;
btnNewGame.secondary( TXT_ERASE );
float w = (WIDTH - GAP) / 2;
btnLoad.setRect(
left, buttonPos, w, BUTTON_HEIGHT );
btnNewGame.setRect(
btnLoad.right() + GAP, buttonPos, w, BUTTON_HEIGHT );
} else {
btnLoad.visible = false;
btnNewGame.visible = true;
btnNewGame.secondary( null );
btnNewGame.setRect( left, buttonPos, WIDTH, BUTTON_HEIGHT );
}
} else {
unlock.visible = true;
btnLoad.visible = false;
btnNewGame.visible = false;
}
}
示例3: updateClass
import com.shatteredpixel.shatteredpixeldungeon.GamesInProgress; //导入依赖的package包/类
private void updateClass( HeroClass cl ) {
if (curClass == cl) {
add( new WndClass( cl ) );
return;
}
if (curClass != null) {
shields.get( curClass ).highlight( false );
}
shields.get( curClass = cl ).highlight( true );
if (cl != HeroClass.HUNTRESS || huntressUnlocked) {
unlock.visible = false;
GamesInProgress.Info info = GamesInProgress.check( curClass );
if (info != null) {
btnLoad.visible = true;
btnLoad.secondary( Messages.format( Messages.get(this, "depth_level"), info.depth, info.level ), info.challenges );
btnNewGame.visible = true;
btnNewGame.secondary( Messages.get(this, "erase"), false );
float w = (Camera.main.width - GAP) / 2 - buttonX;
btnLoad.setRect(
buttonX, buttonY, w, BUTTON_HEIGHT );
btnNewGame.setRect(
btnLoad.right() + GAP, buttonY, w, BUTTON_HEIGHT );
} else {
btnLoad.visible = false;
btnNewGame.visible = true;
btnNewGame.secondary( null, false );
btnNewGame.setRect( buttonX, buttonY, Camera.main.width - buttonX * 2, BUTTON_HEIGHT );
}
} else {
unlock.visible = true;
btnLoad.visible = false;
btnNewGame.visible = false;
}
}