(2) The use of deadly force is not justifiable under this section unless the actor believes that such force is necessary to protect himself against death, serious bodily injury, kidnapping or sexual intercourse compelled by force or threat; nor is it justifiable if:
(i) the actor, with the intent of causing death or serious bodily injury, provoked the use of force against himself in the same encounter; or
(ii) the actor knows that he can avoid the necessity of using such force with complete safety by retreating or by surrendering possession of a thing to a person asserting a claim of right thereto or by complying with a demand that he abstain from any action which he has no duty to take, except that:
(A) the actor is not obliged to retreat from his dwelling or place of work, unless he was the initial aggressor or is assailed in his place of work by another person whose place of work the actor knows it to be; and
(B) a public officer justified in using force in the performance of his duties or a person justified in using force in his assistance or a person justified in using force in making an arrest or preventing an escape is not obliged to desist from efforts to perform such duty, effect such arrest or prevent such escape because of resistance or threatened resistance by or on behalf of the person against whom such action is directed.
http://reference.pafoa.org/statutes/PA/18/I/5/505/use-of-force-in-self-protection/
(4) (i) The use of deadly force is justifiable under this section if:
(A) there has been an entry into the actor's dwelling;
(B) the actor neither believes nor has reason to believe that the entry is lawful; and
(C) the actor neither believes nor has reason to believe that force less than deadly force would be adequate to terminate the entry.
http://reference.pafoa.org/statutes/PA/18/I/5/507/use-of-force-for-the-protection-of-property/