def onPlayerSync(game, player, oldPlayers):
    """
    Event Hook: onPlayerSync
    Apply the updates to other player attributes from the server
    """
    isRiding = False
    if game.player.ridingEntity:
        vehicle = game.getVehicle(game.player.ridingEntity)
        if vehicle:
            isRiding = game.player.name in vehicle.riders['other']
        else:
            print(game.player.ridingEntity)
    if player.name == game.player.name:
        if isRiding:
            game.player.health = player.health
            game.player.pos = player.pos
        return
    for p in range(len(oldPlayers)):
        if oldPlayers[p].name == player.name:
            oldPlayers[p].health = player.health
            if oldPlayers[p].ridingEntity:
                oldPlayers[p].pos = game.getVehicle(oldPlayers[p].ridingEntity
                    ).pos
            else:
                oldPlayers[p].lastPos = oldPlayers[p].pos
                props = oldPlayers[p].getProperty('worldUpdate')
                props.newPos = player.pos
                props.updateTick = game.tick
                oldPlayers[p].setProperty('worldUpdate', props)
            return
    prop = game.getModInstance('ClientMod').worldUpdateProperty.copy()
    prop.newPos = player.pos
    player.setProperty('worldUpdate', prop)
    oldPlayers.append(player)
