Specification of network messages
=================================

////////////////////////////////////////
Messages From Client to Server
////////////////////////////////////////
 
 Move Character
        appxxxxxyyyyyd
                p = Player index
                x = new x position
                y = new y position
                d = new direction

 Get Resource
        bpprrxxxyyynnnnn
                p = Player index
                r = resource id
                x = tile number x
                y = tile number y
                n = amount of resources to get

 Get Item
        cppxxxyyy
                p = Player index
                x = tile number x
                y = tile number y

Place new Building
	fppttxxxyyy

Get resources from building
	gpprraaaaaxxxyyy

 Add Player
     "m" + (Format specified as returned by PlayerBase::getProperties())

 Delete Player
        n

 Get Price List
        rpp
                p = player id (Why do we need the player index?)

trade
	rpptrraaaaa

shop
	spptrraaaaa

 Request player info
	ipp
                p = player id

 null message
        x

////////////////////////////////////////
Messages sent from Server to Client
////////////////////////////////////////

 Player Position Update
        Appxxxxxyyyyyd
                p = player id
                x = x position
                y = y position
                d = direction

 Add/Subtract Resources
        Bpprr+nnnnn
                p = player id
                r = resource id
                + = + or -
                n = amount to add/subtract
 
 Add item to player inventory
        Cppii
                p = player id
                i = item (tool) id
 
 Remove item from map
        Diixxxyyy
                i = item id
                x = tile position in x
                y = tile position in y
 
 Resource out at Tile
        Errxxxyyy
                r = resource id
                x = tile position in x
                y = tile position in y

 Information about a player
	I....
		.... = to be specified
 
 New building
	Fppttxxxyyy
		p = player id
		t = building type
		x = x tile
		y = y tile

 Send Resources from Building
	Gpprraaaaaxxxyyy
		p = player id
		r = resource type
		a = amount of resource
		x = tile location of building
		y = tile location of building

 Add Player
     "m" + (Format specified as returned by PlayerBase::getProperties())
 
 Delete Player
        Npp
                p = player id

 Timeout notice
	O

 Trade Message
	Rpptrraaaaa

 Shop Message
	Spprttaaaaa

 Chat Message
	Tppm...
		p = player id (from)
		m = message

 Temperature update
	Uaaaaa
		a = new tempurature

 Null Message
        X