本文整理汇总了Java中com.watabou.utils.Bundle.put方法的典型用法代码示例。如果您正苦于以下问题:Java Bundle.put方法的具体用法?Java Bundle.put怎么用?Java Bundle.put使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.watabou.utils.Bundle
的用法示例。
在下文中一共展示了Bundle.put方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(TALKEDTO, talkedTo);
bundle.put(FIRSTSUMMON, firstSummon);
bundle.put(SPAWNED, spawned);
bundle.put(PETALS, droppedPetals);
}
示例2: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(SANDBAGS, sandBags);
if (activeBuff != null)
bundle.put(BUFF, activeBuff);
}
示例3: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(HEAPSTOGEN, heapstogen);
bundle.put(HEAPGENSPOTS, heapgenspots);
bundle.put(TELEPORTSPOTS, teleportspots);
bundle.put(PORTSWITCHSPOTS, portswitchspots);
bundle.put(DESTINATIONSPOTS, destinationspots);
bundle.put(DESTINATIONASSIGN, destinationassign);
bundle.put(TELEPORTASSIGN, teleportassign);
bundle.put(PRIZENO, prizeNo);
}
示例4: storePlaceholders
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
/**
* Placements array is used as order is preserved while bundling, but exact index is not, so if we
* bundle both the placeholders (which preserves their order) and an array telling us where the placeholders are,
* we can reconstruct them perfectly.
*/
public void storePlaceholders(Bundle bundle){
ArrayList<Item> placeholders = new ArrayList<Item>(SIZE);
boolean[] placements = new boolean[SIZE];
for (int i = 0; i < SIZE; i++)
if (isPlaceholder(i)) {
placeholders.add(getItem(i));
placements[i] = true;
}
bundle.put( PLACEHOLDERS, placeholders );
bundle.put( PLACEMENTS, placements );
}
示例5: saveLevel
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
public static void saveLevel() throws IOException {
Bundle bundle = new Bundle();
bundle.put(LEVEL, level);
OutputStream output = Game.instance.openFileOutput(
Utils.format(depthFile(hero.heroClass), depth),
Context.MODE_PRIVATE);
Bundle.write(bundle, output);
File file = new File(TextureCache.context.getExternalFilesDir(null), Utils.format(depthFile(hero.heroClass), depth));
Bundle.writeext(bundle, file);
output.close();
}
示例6: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(VALUE, quantity);
}
示例7: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle( Bundle bundle ) {
super.storeInBundle( bundle );
bundle.put( "rooms", rooms );
}
示例8: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle( Bundle bundle ) {
super.storeInBundle( bundle );
bundle.put( LEVEL, level );
}
示例9: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(ITEMS, items);
}
示例10: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle( Bundle bundle ) {
bundle.put( POS, pos );
}
示例11: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle( Bundle bundle ) {
super.storeInBundle( bundle );
bundle.put( BLOODSTAINED, bloodStained );
}
示例12: saveGame
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
public static void saveGame( String fileName ) throws IOException {
try {
Bundle bundle = new Bundle();
bundle.put( VERSION, Game.version );
bundle.put( CHALLENGES, challenges );
bundle.put( HERO, hero );
bundle.put( GOLD, gold );
bundle.put( DEPTH, depth );
for (int d : droppedItems.keyArray()) {
bundle.put( Utils.format( DROPPED, d ), droppedItems.get( d ) );
}
bundle.put( POS, potionOfStrength );
bundle.put( SOU, scrollsOfUpgrade );
bundle.put( SOE, scrollsOfEnchantment );
bundle.put( DV, dewVial );
int count = 0;
int ids[] = new int[chapters.size()];
for (Integer id : chapters) {
ids[count++] = id;
}
bundle.put( CHAPTERS, ids );
Bundle quests = new Bundle();
Ghost .Quest.storeInBundle( quests );
Wandmaker .Quest.storeInBundle( quests );
Blacksmith .Quest.storeInBundle( quests );
Imp .Quest.storeInBundle( quests );
bundle.put( QUESTS, quests );
Room.storeRoomsInBundle( bundle );
Statistics.storeInBundle( bundle );
Journal.storeInBundle( bundle );
QuickSlot.save( bundle );
Scroll.save( bundle );
Potion.save( bundle );
Wand.save( bundle );
Ring.save( bundle );
Bundle badges = new Bundle();
Badges.saveLocal( badges );
bundle.put( BADGES, badges );
OutputStream output = Game.instance.openFileOutput( fileName);
Bundle.write( bundle, output );
output.close();
} catch (Exception e) {
GamesInProgress.setUnknown( hero.heroClass );
}
}
示例13: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(LEFT, left);
}
示例14: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle);
bundle.put(ENTERED, entered);
}
示例15: storeInBundle
import com.watabou.utils.Bundle; //导入方法依赖的package包/类
@Override
public void storeInBundle(Bundle bundle) {
bundle.put(ITEMS, items);
super.storeInBundle(bundle);
}