INNER CODE UNIT · Java

getSelectedBlock

BSVogler/WurfelEngineSDK · core/src/main/java/editor/BlockTable.java:128

	public int getSelectedBlock() {
		return selectionId + (getValue() << 8) + (100 << 16);
	}

	/**
	 * Select a block. Will be highlighted in the table.
	 *
	 * @param blockId id of block data
	 * @param blockValue value of block data
	 */
	public void select(byte blockId, byte blockValue) {
		selectionId = blockId;

		byte i = 0;
		Iterator<BlockDrawable> iter = blockDrawables.iterator();
		while (iter.hasNext()) {
			if (iter.next().getRenderBlock().getId() == blockId) {
				selectItem(i);

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…