This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Minecraft | |
( ClientToServerPacket | |
, ServerToClientPacket | |
, MCInventoryItem | |
, MCInventoryUpdate | |
, MCBlockChange | |
, MCMultiBlockChange | |
) where | |
import Data.Int |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
** error.h | |
** | |
** Copyright (c) 2008 Max Rupp (feelgood@cs.pdx.edu) All rights reserved. | |
*/ | |
#ifndef __ERROR_H__ | |
#define __ERROR_H__ | |
#ifdef DEBUG |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ([typeEncoding isEqualToString:@"@\"MCInventory\""]) { | |
MCShort itemcount; | |
if(![dataBuffer readBytes:&itemcount length:sizeof(MCShort)]) goto Failure; | |
MCInventory *inventory = [[[MCInventory alloc] init] autorelease]; | |
// Read in every inventory item | |
for(int slot = 0; slot < itemcount; slot++){ | |
// Read item id | |
MCShort itemid; | |
if(![dataBuffer readBytes:&itemid length:sizeof(MCShort)]) goto Failure; |