当前位置: 首页>>代码示例>>Java>>正文


Java TiledSprite类代码示例

本文整理汇总了Java中org.andengine.entity.sprite.TiledSprite的典型用法代码示例。如果您正苦于以下问题:Java TiledSprite类的具体用法?Java TiledSprite怎么用?Java TiledSprite使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


TiledSprite类属于org.andengine.entity.sprite包,在下文中一共展示了TiledSprite类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: showWordCollection

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
private void showWordCollection() {
    final WordsStop stop = this;
    this.overlay.clearFocus();
    final WordBuilderHUD hud = new WordBuilderHUD(this.tour.game, this.tour.game.getCurrentLevel(), this.wordTile) {
        @Override
        protected void collectWord(final TiledSprite wordSprite, final WordBuilder builder) {
            super.collectWord(wordSprite, builder);
            next();
        }

        @Override
        public void putChar(Letter letter) {
            // Don't allow spelling
            return;
        }

        @Override
        public void finish() {
            overlay.clearManagedHUD();
        }
    };
    this.overlay.setSpotlight(TourOverlay.SPOTLIGHT_NONE);
    this.overlay.setManagedHUD(hud);
    this.overlay.showMessage(this.getMessage(MSG_COLLECTION), TourOverlay.MessageBox.Top);
}
 
开发者ID:Linguaculturalists,项目名称:Phoenicia,代码行数:26,代码来源:WordsStop.java

示例2: onUpdateColor

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateColor(final TiledSprite pTiledSprite) {
	final float[] bufferData = this.mBufferData;

	final float packedColor = pTiledSprite.getColor().getABGRPackedFloat();

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for (int i = 0; i < tileCount; i++) {
		bufferData[bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:22,代码来源:HighPerformanceTiledSpriteVertexBufferObject.java

示例3: onUpdateColor

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateColor(final TiledSprite pTiledSprite) {
	final FloatBuffer bufferData = this.mFloatBuffer;

	final float packedColor = pTiledSprite.getColor().getABGRPackedFloat();

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for (int i = 0; i < tileCount; i++) {
		bufferData.put(bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:22,代码来源:LowMemoryTiledSpriteVertexBufferObject.java

示例4: onUpdateColor

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateColor(final TiledSprite pTiledSprite) {
	final float[] bufferData = this.mBufferData;

	final float packedColor = pTiledSprite.getColor().getABGRPackedFloat();

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for(int i = 0; i < tileCount; i++) {
		bufferData[bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;
		bufferData[bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX] = packedColor;

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:22,代码来源:HighPerformanceTiledSpriteVertexBufferObject.java

示例5: onUpdateColor

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateColor(final TiledSprite pTiledSprite) {
	final FloatBuffer bufferData = this.mFloatBuffer;

	final float packedColor = pTiledSprite.getColor().getABGRPackedFloat();

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for(int i = 0; i < tileCount; i++) {
		bufferData.put(bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);
		bufferData.put(bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.COLOR_INDEX, packedColor);

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:22,代码来源:LowMemoryTiledSpriteVertexBufferObject.java

示例6: createActor

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
private void createActor() {
	dandelion = new TiledSprite(200, 400, res.dandelionRegion, vbom);
	dandelion.setZIndex(999);
	dandelion.registerUpdateHandler(new IUpdateHandler() {

		@Override
		public void onUpdate(float pSecondsElapsed) {
			if (dandelionBody.getLinearVelocity().y > -0.01) {
				dandelion.setCurrentTileIndex(0);
			} else {
				dandelion.setCurrentTileIndex(1);
			}
		}

		@Override
		public void reset() { }
	});
	dandelionBody = PhysicsFactory.createCircleBody(
			physics, dandelion, BodyType.DynamicBody, Constants.DANDELION_FIXTURE);
	dandelionBody.setFixedRotation(true);
	dandelionBody.setUserData(Constants.BODY_ACTOR);
	physics.registerPhysicsConnector(new PhysicsConnector(dandelion, dandelionBody));
	attachChild(dandelion);
}
 
开发者ID:sm4,项目名称:FlyingDandelion,代码行数:25,代码来源:GameScene.java

示例7: initTalk

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
private void initTalk(int scenarioNo, int seqNo) {
	TalkLogic talkLogic = new TalkLogic();
	// 会話内容取得
	List<PlayerTalkDto> talks = talkLogic.getTalkDtoList(getBaseScene(), scenarioNo, seqNo);
	// 顔リスト作成
	SparseArray<TiledSprite> actorFaces = talkLogic.getTalkFaceSparse(getBaseScene(), talks);
	// 会話レイヤー作成
	TalkLayer talkLayer = new TalkLayer(getBaseScene());
	talkLayer.initTalk(actorFaces, talks);
	talkLayer.hide();
	talkLayer.setZIndex(LayerZIndexType.TALK_LAYER.getValue());
	talkLayer.setTag(CommonTag.TALK_LAYER_TAG.getValue());
	getBaseScene().attachChild(talkLayer);
	// 会話表示
	talkLayer.nextTalk();
}
 
开发者ID:kyokomi,项目名称:AndEngineSRPGQuest,代码行数:17,代码来源:SRPGPart.java

示例8: getTalkFaceSparse

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
public SparseArray<TiledSprite> getTalkFaceSparse(KeyListenScene pBaseScene, List<PlayerTalkDto> talks) {
	pBaseScene.getBaseActivity().openDB();
	MActorDao mActorDao = new MActorDao();
	// 顔画像作成
	SparseArray<TiledSprite> actorFaces = new SparseArray<TiledSprite>();
	int count = talks.size();
	for (int i = 0; i < count; i++) {
		PlayerTalkDto playerTalkDto = talks.get(i);
		MActorEntity mActorEntity = mActorDao.selectById(pBaseScene.getBaseActivity().getDB(), playerTalkDto.getPlayerId());
		playerTalkDto.setName(mActorEntity.getActorName());
		if (actorFaces.indexOfKey(mActorEntity.getActorId()) >= 0 ) {
			continue;
		}
		String faceName = ActorSpriteUtil.getFaceFileName(mActorEntity.getImageResId());
		TiledSprite faceSprite = SRPGSpriteUtil.getResourceFaceSprite(pBaseScene,
				mActorEntity.getActorId(), faceName);
		actorFaces.put(mActorEntity.getActorId(), faceSprite);
	}
	pBaseScene.getBaseActivity().closeDB();
	return actorFaces;
}
 
开发者ID:kyokomi,项目名称:AndEngineSRPGQuest,代码行数:22,代码来源:TalkLogic.java

示例9: initTalk

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
public void initTalk(SparseArray<TiledSprite> faces, List<PlayerTalkDto> talks) {
	// 初期化
	this.talkIndex = 0;
	this.textMaxLength = 0;
	
	// 会話する顔を登録
	this.faces = faces;
	
	// 会話内容を登録
	this.talks = talks;
	
	// 設定された会話内容を元に最大テキストサイズで初期化してTextを用意する
	textMaxLength = getMaxLength(talks);
	talkText = new Text(16, 16, font, 
			getSizeToStr("-", textMaxLength), 
			new TextOptions(HorizontalAlign.LEFT), 
			baseScene.getBaseActivity().getVertexBufferObjectManager());
	talkText.setAutoWrap(AutoWrap.WORDS);
	nameText = new Text(16, 16, font, 
			getSizeToStr("-", textMaxLength), 
			new TextOptions(HorizontalAlign.LEFT), 
			baseScene.getBaseActivity().getVertexBufferObjectManager());
	nameText.setColor(Color.GREEN);
	
	nextTalk();
}
 
开发者ID:kyokomi,项目名称:AndEngineSRPGQuest,代码行数:27,代码来源:TalkLayer.java

示例10: collectWord

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
protected void collectWord(final TiledSprite wordSprite, final WordBuilder builder) {
    game.playBlockSound(buildWord.sound);
    Inventory.getInstance().add(builder.item_name.get());
    game.session.addExperience(buildWord.points);
    int builderIndex = this.buildQueue.indexOf(builder);
    Debug.d("Removing queue item at " + builderIndex);
    for (int i = builderIndex+1; i >= 0 && i < this.buildQueue.size(); i++) {
        Debug.d("Moving queue item at "+i);
        WordBuilder nextInQueue = this.buildQueue.get(i);
        TiledSprite nextSprite = this.queueSpriteMap.get(nextInQueue);
        nextSprite.registerEntityModifier(new MoveXModifier(0.5f, nextSprite.getX(), nextSprite.getX()-64));
        Text nextProgress = this.queueProgressMap.get(nextInQueue);
        nextProgress.registerEntityModifier(new MoveXModifier(0.5f, nextProgress.getX(), nextProgress.getX()-64));
    }
    this.queueSpriteMap.remove(builder);
    wordSprite.registerEntityModifier(new ParallelEntityModifier(
            new MoveYModifier(0.5f, wordSprite.getY(), wordSprite.getY() + 128),
            new FadeOutModifier(0.5f)
    ));

    this.unregisterTouchArea(this.queueTouchAreaMap.get(builder));
    this.queueTouchAreaMap.remove(builder);

    this.buildQueue.remove(builder);
    tile.checkAttention();
    builder.delete(PhoeniciaContext.context);
}
 
开发者ID:Linguaculturalists,项目名称:Phoenicia,代码行数:28,代码来源:WordBuilderHUD.java

示例11: onUpdateVertices

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateVertices(final TiledSprite pTiledSprite) {
	final float[] bufferData = this.mBufferData;

	final float width = pTiledSprite.getWidth(); // TODO Optimize with field access?
	final float height = pTiledSprite.getHeight(); // TODO Optimize with field access?

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for (int i = 0; i < tileCount; i++) {
		bufferData[bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = 0;
		bufferData[bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = 0;

		bufferData[bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = 0;
		bufferData[bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = height;

		bufferData[bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = width;
		bufferData[bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = 0;

		bufferData[bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = width;
		bufferData[bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = 0;

		bufferData[bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = 0;
		bufferData[bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = height;

		bufferData[bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = width;
		bufferData[bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = height;

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:34,代码来源:HighPerformanceTiledSpriteVertexBufferObject.java

示例12: onUpdateVertices

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateVertices(final TiledSprite pTiledSprite) {
	final FloatBuffer bufferData = this.mFloatBuffer;

	final float width = pTiledSprite.getWidth(); // TODO Optimize with field access?
	final float height = pTiledSprite.getHeight(); // TODO Optimize with field access?

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for (int i = 0; i < tileCount; i++) {
		bufferData.put(bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, 0);
		bufferData.put(bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, 0);

		bufferData.put(bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, 0);
		bufferData.put(bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, height);

		bufferData.put(bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, width);
		bufferData.put(bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, 0);

		bufferData.put(bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, width);
		bufferData.put(bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, 0);

		bufferData.put(bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, 0);
		bufferData.put(bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, height);

		bufferData.put(bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, width);
		bufferData.put(bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, height);

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:34,代码来源:LowMemoryTiledSpriteVertexBufferObject.java

示例13: onUpdateVertices

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateVertices(final TiledSprite pTiledSprite) {
	final float[] bufferData = this.mBufferData;

	final float x = 0;
	final float y = 0;
	final float x2 = pTiledSprite.getWidth(); // TODO Optimize with field access?
	final float y2 = pTiledSprite.getHeight(); // TODO Optimize with field access?

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for(int i = 0; i < tileCount; i++) {
		bufferData[bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = x;
		bufferData[bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = y;

		bufferData[bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = x;
		bufferData[bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = y2;

		bufferData[bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = x2;
		bufferData[bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = y;

		bufferData[bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = x2;
		bufferData[bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = y;

		bufferData[bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = x;
		bufferData[bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = y2;

		bufferData[bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X] = x2;
		bufferData[bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y] = y2;

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:36,代码来源:HighPerformanceTiledSpriteVertexBufferObject.java

示例14: onUpdateVertices

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void onUpdateVertices(final TiledSprite pTiledSprite) {
	final FloatBuffer bufferData = this.mFloatBuffer;

	final float x = 0;
	final float y = 0;
	final float x2 = pTiledSprite.getWidth(); // TODO Optimize with field access?
	final float y2 = pTiledSprite.getHeight(); // TODO Optimize with field access?

	final int tileCount = pTiledSprite.getTileCount();
	int bufferDataOffset = 0;
	for(int i = 0; i < tileCount; i++) {
		bufferData.put(bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, x);
		bufferData.put(bufferDataOffset + 0 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, y);

		bufferData.put(bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, x);
		bufferData.put(bufferDataOffset + 1 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, y2);

		bufferData.put(bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, x2);
		bufferData.put(bufferDataOffset + 2 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, y);

		bufferData.put(bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, x2);
		bufferData.put(bufferDataOffset + 3 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, y);

		bufferData.put(bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, x);
		bufferData.put(bufferDataOffset + 4 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, y2);

		bufferData.put(bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_X, x2);
		bufferData.put(bufferDataOffset + 5 * TiledSprite.VERTEX_SIZE + Sprite.VERTEX_INDEX_Y, y2);

		bufferDataOffset += TiledSprite.TILEDSPRITE_SIZE;
	}

	this.setDirtyOnHardware();
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:36,代码来源:LowMemoryTiledSpriteVertexBufferObject.java

示例15: init

import org.andengine.entity.sprite.TiledSprite; //导入依赖的package包/类
@Override
public void init(SaveDataDto saveDataDto) {
	Sprite backImg = getBaseScene().getResourceSprite(saveDataDto.getBackImgFilePath());
	backImg.setSize(getBaseScene().getWindowWidth(), getBaseScene().getWindowHeight());
	getBaseScene().attachChild(backImg);
	
	// 会話内容取得
	TalkLogic talkLogic = new TalkLogic();
	List<PlayerTalkDto> talks = talkLogic.getTalkDtoList(getBaseScene(),
			saveDataDto.getScenarioNo(), 
			saveDataDto.getSeqNo());
	// 顔画像作成
	SparseArray<TiledSprite> actorFaces = talkLogic.getTalkFaceSparse(getBaseScene(), talks);
	// 会話レイヤー作成
	TalkLayer talkLayer = new TalkLayer(getBaseScene());
	talkLayer.initTalk(actorFaces, talks);
	talkLayer.hide();
	talkLayer.setZIndex(LayerZIndexType.TALK_LAYER.getValue());
	talkLayer.setTag(CommonTag.TALK_LAYER_TAG.getValue());
	getBaseScene().attachChild(talkLayer);
	
	// まずは章開始カットイン
	if (saveDataDto.getSeqNo().intValue() == 1) {
		ScenarioStartCutInTouchLayer scenarioStartCutInTouchLayer = 
				new ScenarioStartCutInTouchLayer(getBaseScene(), saveDataDto);
		getBaseScene().attachChild(scenarioStartCutInTouchLayer);
		scenarioStartCutInTouchLayer.showTouchLayer();
	} else {
		talkLayer.nextTalk();
	}
}
 
开发者ID:kyokomi,项目名称:AndEngineSRPGQuest,代码行数:32,代码来源:NovelPart.java


注:本文中的org.andengine.entity.sprite.TiledSprite类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。