def head_addon_post(entry, body, cells):

    head_id = entry.head_id
    head_feature = entry.head_feature
    feature = entry.feature
    equipment = entry.equipment
    weapon = entry.weapon
    addon = entry.addon

    head_feature = name(HeadFeature, head_feature)
    feature = name(Feature, feature)
    equipment = name(Equipment, equipment)
    weapon = name(Weapon, weapon)

    cells = cell('Feature', 25, [head_feature])
    vcells = vcell('equipment', 30, [equipment])
    vcells = vcell('weapon', 30, [weapon], vcells)
    vcells = vcell('feature', 30, [feature], vcells)
    cells = vcell_add('Item', addon, vcells, cells)

    body = send(cells, body)

    cells.clear()

    return (body)
Exemplo n.º 2
0
def weap_condition_post(entry, body, cells):

    weapon_id = entry.weapon_id
    condition_type = entry.condition_type
    condition = entry.condition
    condition_null = entry.condition_null
    condition1 = entry.condition1
    condition2 = entry.condition2
    damage_value = entry.damage_value
    damage = entry.damage

    condition = get_name(Condition, condition)
    condition_null = get_name(Condition, condition_null)
    condition1 = get_name(Condition, condition1)
    condition2 = get_name(Condition, condition2)

    damage_value = integer_convert(damage_value)

    updown_select = [{'type': 1, 'name': 'Up'}, {'type': -1, 'name': 'Down'}]
    damage = selects(damage, updown_select)

    vcells = vcell('active', 40, [condition, 'Active'])
    vcells = vcell('change', 60, [condition1, 'to', condition2], vcells)
    vcells = vcell('damage', 40, [damage_value, 'Condition', damage], vcells)
    vcells = vcell('null', 40, [condition_null, 'Nullified'], vcells)
    cells = vcell_add('Condition Effect', condition_type, vcells, cells)

    body = send(cells, body)

    cells.clear()

    return (body)
Exemplo n.º 3
0
def equip_belt_post(entry, body, cells):

    equip_id = entry.equip_id
    feature = entry.feature
    weapon = entry.weapon
    equipment = entry.equipment
    cost = entry.cost
    belt_item_type = entry.belt_item_type

    feature = get_name(Feature, feature)
    weapon = get_name(Weapon, weapon)
    equipment = get_name(Equipment, equipment)

    cost = str(cost)

    vcells = vcell('equip', 30, [equipment])
    vcells = vcell('weapon', 30, [weapon], vcells)
    vcells = vcell('feature', 30, [feature], vcells)
    cells = vcell_add('Item', belt_item_type, vcells, cells)
    cells = cell('Cost', 10, [cost], cells)
    body = send(cells, body)

    cells.clear()

    print('\n\n')
    print(cost)
    print('\n')

    return (body)
Exemplo n.º 4
0
def veh_feature_post(entry, body, cells):

    vehicle_id = entry.vehicle_id
    feature = entry.feature
    cost = entry.cost
    equipment = entry.equipment
    weapon = entry.weapon
    addon = entry.addon

    feature = name(Feature, feature)
    equipment = name(Equipment, equipment)
    weapon = name(Weapon, weapon)

    vcells = vcell('equipment', 30, [equipment])
    vcells = vcell('weapon', 30, [weapon], vcells)
    vcells = vcell('feature', 30, [feature], vcells)
    cells = vcell_add('Item', addon, vcells, cells)
    cells = cell('Cost', 10, [cost], cells)

    body = send(cells, body)

    cells.clear()

    return (body)
Exemplo n.º 5
0
def equip_modifiers_post(entry, body, cells):

    equip_id = entry.equip_id
    feature = entry.feature
    effect = entry.effect
    bonus = entry.bonus
    bonus_type = entry.bonus_type
    penalty = entry.penalty
    penalty_type = entry.penalty_type
    trigger = entry.trigger
    bonus_effect = entry.bonus_effect
    penalty_effect = entry.penalty_effect
    environment = entry.environment
    environment_other = entry.environment_other
    sense = entry.sense
    mod_range = entry.mod_range
    subsense = entry.subsense
    cover = entry.cover
    conceal = entry.conceal
    maneuver = entry.maneuver
    weapon_melee = entry.weapon_melee
    weapon_ranged = entry.weapon_ranged
    tools = entry.tools
    condition = entry.condition
    power = entry.power
    consequence = entry.consequence
    creature = entry.creature
    creature_other = entry.creature_other
    emotion = entry.emotion
    emotion_other = entry.emotion_other
    conflict = entry.conflict
    profession = entry.profession
    profession_other = entry.profession_other
    bonus_trait_type = entry.bonus_trait_type
    bonus_trait = entry.bonus_trait
    bonus_trait = variable_trait(bonus_trait, bonus_trait_type)
    bonus_check = entry.bonus_check
    bonus_check_range = entry.bonus_check_range
    bonus_conflict = entry.bonus_conflict
    penalty_trait_type = entry.penalty_trait_type
    penalty_trait = entry.penalty_trait
    penalty_trait = variable_trait(penalty_trait, penalty_trait_type)
    penalty_check = entry.penalty_check
    penalty_check_range = entry.penalty_check_range
    penalty_conflict = entry.penalty_conflict
    bonus_active_defense = entry.bonus_active_defense
    bonus_conflict_defend = entry.bonus_conflict_defend
    penalty_active_defense = entry.penalty_active_defense
    penalty_conflict_defend = entry.penalty_conflict_defend
    multiple = entry.multiple
    multiple_count = entry.multiple_count
    lasts = entry.lasts
    skill = entry.skill
    light = entry.light

    bonus_trait = trait_select(bonus_trait, bonus_trait_type)
    penalty_trait = trait_select(penalty_trait, penalty_trait_type)

    bonus = integer_convert(bonus)
    penalty = integer_convert(penalty)
    multiple_count = integer_convert(multiple_count)
    lasts = integer_convert(lasts)

    modifier_type = [{
        'type': '',
        'name': 'Type'
    }, {
        'type': 'up',
        'name': 'Up to'
    }, {
        'type': 'value',
        'name': 'Exact'
    }, {
        'type': 'rank',
        'name': 'Per Rank'
    }, {
        'type': '-1',
        'name': 'Rank - 1'
    }]
    bonus_type = selects(bonus_type, modifier_type)
    penalty_type = selects(penalty_type, modifier_type)

    multiple_select = [{
        'type': '',
        'name': 'If Multiple'
    }, {
        'type': 'together',
        'name': 'All Work Together'
    }, {
        'type': 'round',
        'name': 'Choose for Round'
    }, {
        'type': 'turn',
        'name': 'Choose for Turn'
    }, {
        'type': 'pick',
        'name': 'Pick 1'
    }, {
        'type': 'rank',
        'name': '1 Per Rank'
    }]
    multiple = selects(multiple, multiple_select)

    environment = get_name(Environment, environment)
    sense = get_name(Sense, sense)
    mod_range = get_name(Ranged, mod_range)
    subsense = get_name(SubSense, subsense)
    cover = get_name(Cover, cover)
    conceal = get_name(Conceal, conceal)
    maneuver = get_name(Maneuver, maneuver)
    weapon_melee = get_name(WeaponType, weapon_melee)
    weapon_ranged = get_name(WeaponType, weapon_ranged)
    condition = get_name(Condition, condition)
    power = get_name(Power, power)
    consequence = get_name(Consequence, consequence)
    creature = get_name(Creature, creature)
    emotion = get_name(Emotion, emotion)
    conflict = get_name(ConflictAction, conflict)
    profession = get_name(Job, profession)
    bonus_conflict = get_name(ConflictAction, bonus_conflict)
    penalty_conflict = get_name(ConflictAction, penalty_conflict)
    skill = get_name(Skill, skill)
    light = get_name(Light, light)
    bonus_check = get_name(Check, bonus_check)
    bonus_check_range = get_name(Ranged, bonus_check_range)
    penalty_check = get_name(Check, penalty_check)
    penalty_check_range = get_name(Ranged, penalty_check_range)
    effect = name(EquipEffect, effect)
    feature = name(Feature, feature)

    bonus_active_defense = variable_value('trait', bonus_effect,
                                          bonus_active_defense)
    bonus_conflict_defend = variable_value('conflict', bonus_effect,
                                           bonus_conflict_defend)
    penalty_active_defense = variable_value('trait', penalty_effect,
                                            penalty_active_defense)
    penalty_conflict_defend = variable_value('conflict', penalty_effect,
                                             penalty_conflict_defend)

    modifier_trigger = [{
        'type': '',
        'name': 'Trigger'
    }, {
        'type': 'environment',
        'name': 'Environment'
    }, {
        'type': 'cover',
        'name': 'Cover'
    }, {
        'type': 'conceal',
        'name': 'Concealment'
    }, {
        'type': 'sense',
        'name': 'Sense'
    }, {
        'type': 'subsense',
        'name': 'Subsense'
    }, {
        'type': 'condition',
        'name': 'Condition'
    }, {
        'type': 'profession',
        'name': 'Characters Profession'
    }, {
        'type': 'creature',
        'name': 'Creature'
    }, {
        'type': 'power',
        'name': 'Power'
    }, {
        'type': 'emotion',
        'name': 'Emotion'
    }, {
        'type': 'consequence',
        'name': 'Consequence'
    }, {
        'type': 'range',
        'name': 'Range'
    }, {
        'type': 'critical',
        'name': 'Critical Attempt'
    }, {
        'type': 'conflict',
        'name': 'Conflict Action'
    }, {
        'type': 'maneuver',
        'name': 'Maneuver'
    }, {
        'type': 'tools',
        'name': 'Tool Requirement'
    }, {
        'type': 'ranged',
        'name': 'Ranged Weapon'
    }, {
        'type': 'melee',
        'name': 'Melee Weapon'
    }]

    cells = cell('Feature', 11, [feature])
    cells = cell('Effect', 11, [effect], cells)
    cells = cell('Bonus', 8, [bonus], cells)
    cells = cell('Type', 8, [bonus_type], cells)
    vcells = vcell('effect', 15, ['Effect Modifier'])
    vcells = vcell('attack', 12, ['Attack Bonus'], vcells)
    vcells = vcell('damage', 13, ['Damage Bonus'], vcells)
    vcells = vcell('defense', 16, ['Active Defenses'], vcells)
    vcells = vcell('trait', 18, [bonus_trait], vcells)
    word = string(', Range:', [bonus_check_range])
    vcells = vcell('check', 29, [bonus_check, word, bonus_check_range], vcells)
    vcells = vcell('conflict', 16, [bonus_conflict], vcells)
    cells = vcell_add('Bonus Effect', bonus_effect, vcells, cells)

    cells = check_cell('Active', 8, bonus_active_defense, cells)
    cells = check_cell('Only Active', 11, bonus_conflict_defend, cells)

    cells = cell('Penalty', 8, [penalty], cells)
    cells = cell('Type', 8, [penalty_type], cells)

    vcells = vcell('effect', 15, ['Effect Modifier'])
    vcells = vcell('attack', 12, ['Attack Bonus'], vcells)
    vcells = vcell('damage', 13, ['Damage Bonus'], vcells)
    vcells = vcell('defense', 16, ['Active Defenses'], vcells)
    vcells = vcell('trait', 18, [penalty_trait], vcells)
    word = string(', Range:', [penalty_check_range])
    vcells = vcell('check', 29, [penalty_check, word, penalty_check_range],
                   vcells)
    vcells = vcell('conflict', 16, [penalty_conflict], vcells)

    cells = vcell_add('Affects', penalty_effect, vcells, cells)

    cells = check_cell('Active', 8, penalty_active_defense, cells)
    cells = check_cell('Only Active', 11, penalty_conflict_defend, cells)

    vcells = vcell('environment', 20, [environment])
    vcells = vcell('cover', 20, [cover], vcells)
    vcells = vcell('conceal', 20, [conceal], vcells)
    vcells = vcell('sense', 20, [sense], vcells)
    vcells = vcell('subsense', 20, [subsense], vcells)
    vcells = vcell('condition', 20, [condition], vcells)
    vcells = vcell('profession', 20, [profession], vcells)
    vcells = vcell('creature', 20, [creature], vcells)
    vcells = vcell('power', 20, [power], vcells)
    vcells = vcell('emotion', 20, [emotion], vcells)
    vcells = vcell('consequence', 20, [consequence], vcells)
    vcells = vcell('range', 20, [mod_range], vcells)
    vcells = vcell('critical', 20, ['Critical Attempt'], vcells)
    vcells = vcell('conflict', 20, [conflict], vcells)
    vcells = vcell('maneuver', 20, [maneuver], vcells)
    vcells = vcell('tools', 20, [tools], vcells)
    vcells = vcell('ranged', 20, [weapon_ranged], vcells)
    vcells = vcell('melee', 20, [weapon_melee], vcells)
    vcells = vcell('skill', 20, [skill], vcells)
    vcells = vcell('light', 20, [light], vcells)
    cells = vcell_add('Trigger', trigger, vcells, cells)

    body = send(cells, body)

    cells.clear()

    return (body)