Optimized setHandValue()