focus_tree = {
    id = haiti_vic_empire_ft

    country = {
        factor = 0

        modifier = {
            add = 11
            tag = HAI
        }
    }

    default = no

    continuous_focus_position = { x = 2500 y = 2000 }

    ##Political branch
    focus = {
        id = HAI_create_the_republic
        icon = GFX_goal_support_democracy # WIP 

        cost = 35

        search_filters = {
            FOCUS_FILTER_RESEARCH # WIP
        }

        mutually_exclusive = {
            focus = HAI_strenghten_the_empire
        }

        x = 3 
        y = 0

        available = {
			custom_trigger_tooltip = {
				tooltip = USA_FN_focus_unlock_by_event
				always = no
			}
		}
    
        completion_reward = {
            HAI = {
                
                set_politics = { ruling_party = centrism }
                
            }
        }
    }

    focus = {
        id = HAI_geffrard_escapes
        icon = GFX_focus_generic_military_mission

        cost = 35 

        prerequisite = {
            focus = HAI_create_the_republic
        }
        
        relative_position_id  = HAI_create_the_republic
        x = 0
        y = 1

        available = {
			custom_trigger_tooltip = {
				tooltip = USA_FN_focus_unlock_by_event
				always = no
			}
		}

        completion_reward = {
            set_politics = { ruling_party = radical_democracy }
        }
    }

    focus = {
        id = HAI_sagets_republic
        icon = GFX_goal_generic_wolf_pack # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_geffrard_escapes
        }

        mutually_exclusive = {
            focus = HAI_salnaves_empire
        }
        
        relative_position_id  = HAI_create_the_republic 
        x = 0
        y = 2

        available = {
            custom_trigger_tooltip = {
				tooltip = USA_FN_focus_unlock_by_event
				always = no
			}
		}

        completion_reward = {
            
        }
    }

    focus = {
        id = HAI_salnaves_empire
        icon = GFX_focus_generic_monarchy_1 # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_geffrard_escapes
        }

        mutually_exclusive = {
            focus = HAI_sagets_republic
        }
        
        relative_position_id  = HAI_create_the_republic 
        x = 5
        y = 2

        available = {
            custom_trigger_tooltip = {
				tooltip = USA_FN_focus_unlock_by_event
				always = no
			}
		}

        completion_reward = {
            
        }
    }

    focus = {
        id = HAI_michel_domingue_presidency
        icon = GFX_focus_generic_self_management # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_sagets_republic
        }
        
        relative_position_id  = HAI_create_the_republic 
        x = -1
        y = 3

        completion_reward = {
           # HAI = {
                #add_ideas = {
                #    constitution_adopted
                #}
            #}
        }
    }

    focus = {
        id = HAI_treaty_with_the_dominicans
        icon = GFX_focus_generic_diplomatic_treaty # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_sagets_republic
        }
        
        relative_position_id  = HAI_create_the_republic
        x = 1
        y = 3

        available = {
            has_country_flag = HAI_michel_domingue_elected
		}

        completion_reward = {
            HAI = {
                diplomatic_relation = {
                    country = DOM 
                    relation = non_aggression_pact 
                }
            } #//TODO: ESTABLISH FREE TRADE
        }
    }

    focus = {
        id = HAI_michel_domingue_resigns
        icon = GFX_focus_generic_military_mission # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_treaty_with_the_dominicans
        }

        prerequisite = {
            focus = HAI_michel_domingue_presidency
        }
        
        relative_position_id  = HAI_create_the_republic
        x = 0
        y = 4
        
        available = {
            custom_trigger_tooltip = {
				tooltip = USA_FN_focus_unlock_by_event
				always = no
			}
		}

        completion_reward = {
            set_politics = { ruling_party = centrism }
        }
    }

    focus = {
        id = HAI_develop_the_capital
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_michel_domingue_resigns
        }
        
        mutually_exclusive = {
            focus = HAI_develop_the_rural_areas
        }

        relative_position_id  = HAI_create_the_republic
        x = -2
        y = 5

        completion_reward = {
            318 = {
                add_extra_state_shared_building_slots = 2
                add_building_construction = {
                    type = industrial_complex
                    level = 2
                    instant_build = yes
                }
                add_to_variable = { 
                    var = HAI_cacos_influence
                    value = -5
                }
            }
        }
    }

    focus = {
        id = HAI_develop_the_rural_areas
        icon = GFX_goal_generic_construction # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_michel_domingue_resigns
        }

        mutually_exclusive = {
            focus = HAI_develop_the_capital
        }

        
        
        relative_position_id  = HAI_create_the_republic
        x = 2
        y = 5
        

        completion_reward = {
            790 = {
                add_extra_state_shared_building_slots = 2
                add_building_construction = {
                    type = industrial_complex
                    level = 2
                    instant_build = yes
                }
            }
            add_to_variable = { 
                var = HAI_cacos_influence
                value = 5
            }
        }
    }

    focus = {
        id = HAI_salomon_presidency
        icon = GFX_focus_generic_support_the_left_right

        cost = 35

        prerequisite = {
            focus = HAI_develop_the_capital
            focus = HAI_develop_the_rural_areas
        }

        relative_position_id  = HAI_create_the_republic
        x = 0
        y = 6
        

        available = {
            custom_trigger_tooltip = {
                tooltip = USA_FN_focus_unlock_by_event
                always = no
            }
        }

        completion_reward = { 
            custom_effect_tooltip =  "Lysius Salomon becomes president."
        }
    }


    focus = {
        id = HAI_seek_foreign_aid
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_salomon_presidency
        }

        available = {
            custom_trigger_tooltip = {
                tooltip = "The Haitian anti French sentiment must be below 100."
                check_variable = { HAI_anti_french_sentiment < 100 }
            }
        }

        mutually_exclusive = {
            focus = HAI_preserve_sovereignty
        }

        relative_position_id  = HAI_create_the_republic
        x = 3
        y = 7

        completion_reward = {
            custom_effect_tooltip = "Haiti will seek foreign allies."
        }
    }

    focus = {
        id = HAI_pro_french_propaganda_campaign
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_seek_foreign_aid
        }

        relative_position_id  = HAI_create_the_republic
        x = 2
        y = 8

        completion_reward = {
            custom_effect_tooltip = "Lowers Haitian anti French sentiment by 5."
            add_to_variable = {
                var = HAI_anti_french_sentiment
                value = -5
            }
            hidden_effect = {
                if = {
                    limit = {
                        check_variable = { HAI_anti_french_sentiment < 25 }
                    }
                    remove_opinion_modifier = {
                        target = FRA
                        modifier = fra_hai_french_slave_trade
                    }
                }
            }
            
        }
    }

    focus = {
        id = HAI_issue_apologies_to_france
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_seek_foreign_aid
        }

        available = {
            custom_trigger_tooltip = {
                tooltip = "The Haitian anti French sentiment must be below 70."
                check_variable = { HAI_anti_french_sentiment < 70 }
            }
        }

        relative_position_id  = HAI_create_the_republic
        x = 4
        y = 8

        completion_reward = {
            custom_effect_tooltip = "Lowers French anti Haitian sentiment by 10."
            add_to_variable = {
                var = HAI_anti_haitian_sentiment
                value = -10
            }
        }
    }

    focus = {
        id = HAI_preserve_sovereignty
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_salomon_presidency
        }


        mutually_exclusive = {
            focus = HAI_seek_foreign_aid
        }
        relative_position_id  = HAI_create_the_republic
        x = -3
        y = 7

        completion_reward = {
            custom_effect_tooltip = "Haiti will stay independent."
        }

    }

    focus = {
        id = HAI_address_the_cacos_question
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_preserve_sovereignty
        }
        
        available = {
            date > 1915.1.1 # america invaded checks
        }

        relative_position_id  = HAI_preserve_sovereignty
        x = 0
        y = 10
        

        completion_reward = {
            790 = {
                add_extra_state_shared_building_slots = 1
            }
        }
    }

    focus = {
        id = HAI_war_with_the_cacos
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_address_the_cacos_question
        }

        mutually_exclusive = {
            focus = HAI_join_the_cacos
            focus = HAI_peace_with_the_cacos
        }
        
        relative_position_id  = HAI_preserve_sovereignty
        x = 2
        y = 11
        

        completion_reward = {

        }
    }

    focus = {
        id = HAI_peace_with_the_cacos
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_address_the_cacos_question
        }
        
        mutually_exclusive = {
            focus = HAI_join_the_cacos
            focus = HAI_war_with_the_cacos
        }

        relative_position_id  = HAI_preserve_sovereignty
        x = 0
        y = 11
        

        completion_reward = {

        }
    }

    focus = {
        id = HAI_join_the_cacos
        icon = GFX_goal_generic_construct_civ_factory # WIP

        cost = 35 

        prerequisite = {
            focus = HAI_address_the_cacos_question
        }

        mutually_exclusive = {
            focus = HAI_peace_with_the_cacos
            focus = HAI_war_with_the_cacos
        }
        
        relative_position_id  = HAI_preserve_sovereignty
        x = -2
        y = 11
        

        completion_reward = {

        }
    }
    
    focus = {
        id = HAI_strenghten_the_empire
        icon = GFX_focus_generic_monarchy_2 # WIP

        cost = 35

        mutually_exclusive = {
            focus = HAI_create_the_republic
        }

        search_filters = {
            FOCUS_FILTER_RESEARCH # WIP
        }

        available = {
			custom_trigger_tooltip = {
				tooltip = USA_FN_focus_unlock_by_event
				always = no
			}
		}

        x = 10
        y = 0

        completion_reward = {
            add_popularity = { ideology = autocracy popularity = 0.1 }
        }
    }
}