Return all wordpress custom posts in specific multidimensional array

This does a query for all posts of type family guy, tosses them into the $fg_obj then loops through each post, grabs its tags, and creates a flat array of just the tag name. Then that array gets put into a new array with the post ID. This seems like a strange way of getting this info (because I don’t know the final purpose of this array), but it should be the format you’ve requested.

$args = array( 'post_type' => 'family_guy', 'posts_per_page' => -1 ); 
$fg_obj = get_posts($args);
$posts_with_tags = array();
foreach($fg_obj as $fg) {
  $tags = get_the_tags($fg->ID);
  $tag_arr = array();
  foreach($tags as $tag) $tag_arr[] = $tag->name;
  $posts_with_tags[$fg->ID] = $tag_arr;
}