Hello, I have been working on making an item for a mod in Forge. Most of the resources I could find use PlayerEntity.setActiveHand, but that no longer seems to exist, and I can't seem to find an equivalent method in PlayerEntity. My code is below in case it helps, though it's not particularly specific.
@Override
public ActionResult<ItemStack> use(World worldIn, PlayerEntity playerIn, Hand hand) {
ItemStack mainHandItem = playerIn.getMainHandItem();
// cannot resolve method
playerIn.SetActiveHand(hand);
return new ActionResult<ItemStack>(ActionResultType.SUCCESS, mainHandItem);