Beat the cream cheese until creamy.
Add the granulated sugar and beat until smooth.
Add the melted chocolate and beat until creamy.
Add the eggs one at a time, beating well after each addition. Make sure the eggs are fully incorporated, but do not overbeat the batter.
Spread the cheesecake batter over the cookie dough in the pan. Crumble the remaining cookie dough over the cheesecake batter.
Sprinkle the remaining M&M's on top.
Bake for 35-40 minutes.
Remove the pan from the oven and place it on a wire rack for 1 hour, then refrigerate for 4 hours or until completely chilled.
Cut it into 24 bars before serving.