Small mobs can no longer pin larger mobs

This commit is contained in:
HarpyEagle
2016-05-24 15:18:01 -04:00
committed by Yoshax
parent 69dd0bb5d0
commit 8fc62cdbbc
2 changed files with 6 additions and 2 deletions

View File

@@ -136,7 +136,7 @@
handle_eye_mouth_covering(affecting, assailant, assailant.zone_sel.selecting) handle_eye_mouth_covering(affecting, assailant, assailant.zone_sel.selecting)
if(force_down) if(force_down)
if(affecting.loc != assailant.loc) if(affecting.loc != assailant.loc || size_difference(affecting, assailant) > 0)
force_down = 0 force_down = 0
else else
affecting.Weaken(2) affecting.Weaken(2)
@@ -237,7 +237,7 @@
if(state < GRAB_AGGRESSIVE) if(state < GRAB_AGGRESSIVE)
if(!allow_upgrade) if(!allow_upgrade)
return return
if(!affecting.lying) if(!affecting.lying || size_difference(affecting, assailant) > 0)
assailant.visible_message("<span class='warning'>[assailant] has grabbed [affecting] aggressively (now hands)!</span>") assailant.visible_message("<span class='warning'>[assailant] has grabbed [affecting] aggressively (now hands)!</span>")
else else
assailant.visible_message("<span class='warning'>[assailant] pins [affecting] down to the ground (now hands)!</span>") assailant.visible_message("<span class='warning'>[assailant] pins [affecting] down to the ground (now hands)!</span>")

View File

@@ -131,6 +131,10 @@
return return
if(force_down) if(force_down)
attacker << "<span class='warning'>You are already pinning [target] to the ground.</span>" attacker << "<span class='warning'>You are already pinning [target] to the ground.</span>"
return
if(size_difference(affecting, assailant) > 0)
attacker << "<span class='warning'>You are too small to do that!</span>"
return
attacker.visible_message("<span class='danger'>[attacker] starts forcing [target] to the ground!</span>") attacker.visible_message("<span class='danger'>[attacker] starts forcing [target] to the ground!</span>")
if(do_after(attacker, 20) && target) if(do_after(attacker, 20) && target)