Which function should I use to update a node through the comment form?
You could implement the same hook hook_comment_create() but just inverse the assignment you do on the comment as in your code, for example:

function mymodule_comment_create(\Drupal\comment\CommentInterface $comment) {
  $node = $comment-&gt;getCommentedEntity();
  if ($node &amp;&amp; $node instanceof \Drupal\node\NodeInterface) {
    if ($node-&gt;hasField('node_field') &amp;&amp; $comment-&gt;hasField('comment_field') &amp;&amp; !empty($comment-&gt;comment_field-&gt;value)) {
      $node-&gt;node_field-&gt;value = $comment-&gt;comment_field-&gt;value;
    }
  }
}