case HERE_YOUR_STATS: proc_stats((Sint16 *)(msg+3)); break; case SEND_PARTIAL_STAT: proc_stat(*((Uint8 *)(msg+3)),SDL_SwapLE32(*((Sint32 *)(msg+4)))); break;
int process_message (unsigned char* msg, int len) {  switch (msg[0]) {  // Actor Stuff    case ADD_NEW_ENHANCED_ACTOR:                           check_actor_equip(msg+3);         break;          case ADD_ACTOR_COMMAND:        process_command(*((short *)(msg+3)),msg[5]);        break;    case ADD_NEW_ACTOR:        add_actor_from_server(msg+3, ((bot_map.map[bot_map.cur_map].id == CONFIG_NULL) ? 1 : 0));             // Kill monsters        break;          case REMOVE_ACTOR:		destroy_actor(*((Uint16 *)(msg+3)));		break;	case KILL_ALL_ACTORS:		destroy_all_actors();		break;      case YOU_ARE:		yourself=*((short *)(msg+3));	    break;  // Inventory Stuff   	case HERE_YOUR_INVENTORY:		get_inventory_from_server(msg+3);        break;	case GET_NEW_INVENTORY_ITEM:		get_new_inventory_item_from_server(msg+3);	    break;	case REMOVE_ITEM_FROM_INVENTORY:		remove_inventory_item(msg[3]);	    break; // Bag Stuff	case GET_NEW_BAG:         put_bag_on_ground(SDL_SwapLE16(*((Uint16 *)(msg+3))), SDL_SwapLE16(*((Uint16 *)(msg+5))),*((Uint8 *)(msg+7)));         break;	case GET_BAGS_LIST:         add_bag_list(&msg[3]);		 break;	case GET_NEW_GROUND_ITEM:		 get_bag_item(msg+3);		 break;    case HERE_YOUR_GROUND_ITEMS:		 get_bags_items_list(&msg[3]);		 break;    case CLOSE_BAG:		 // Destroy Bag Contents		 break;    case REMOVE_ITEM_FROM_GROUND:		 remove_item_from_ground(msg[3]);		 break;	case DESTROY_BAG:		 remove_bag(msg[3]);		 break; // Map Stuff     case CHANGE_MAP:		      {          bot_map.cur_map = -1;          load_map(msg+3);      }      break;  // Login stuff    case LOG_IN_OK:    case LOG_IN_NOT_OK:          logged_in = msg[0];      break;  // Text Stuff    case RAW_TEXT:      process_raw_text (msg+3, len-3);      break;    default:      /* ignore */ ;  }  return 1;}