def get_core_blockdata(core_index, spltcore_index, core_bases):
    """
    Get Core Offset and Length
    :param core_index: Index of the Core
    :param splitcore_index: Index of last core before split
    :param core_bases: Array with base offset and offset after split
    :return: Array with core offset and core length
    """

    core_base = int(core_bases[0])
    core_len = int(core_bases[1])

    core_split = 0
    if len(core_bases) > 4:
        core_split = int(core_bases[4])

    core_offset = core_base + core_index * core_len
    if core_split and core_index + 2 > spltcore_index:
        core_offset = core_split + (core_index - spltcore_index + 1) * core_len

    return [core_offset, core_len]