If a piece (rook, knight, bishop or queen) attacks another friendly one, it borrows powers from it and can move (and capture) like it.
Students from the UCF Chess Club (2020).
See also their Discord server :-)