Phone overheats while playing games, stop playing give your device some rest.
Normal body temperature is 37° Celsius so 42 degrees is not that much high in summer time.
Same here where any application is being used then phone get heated and feel warm.
I think android 11 can't best for SDM855 and also it may be oxygen os Fault
Use the pinned OnePlus 7 Pro battery/heating feedback thread for further discussion -
OnePlus Brainstorm Room v.2 Design Contest
by Daniel D., 2021-09-21