Advertisement
Guest User

Untitled

a guest
Aug 20th, 2019
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.63 KB | None | 0 0
  1. function lam.pickForm(formType)
  2.   if not formType then
  3.     lam.echo("No argument given to lam.pickForm", "red")
  4.     return
  5.   end
  6.   local valid = {"iceLegs", "iceArms", "dust"}
  7.   if not table.contains(valid, formType) then
  8.     lam.echo("Invalid argument given to lam.pickForm", "red")
  9.     return
  10.   end
  11.   local stance = lam.getStance()
  12.   if formType == "dust" then
  13.     lam.nextForm = "dust"
  14.     if stance == "k" then
  15.       lam.nextForm = "dustgrapple"
  16.     end
  17.   end
  18.   if formType == "iceLegs" then
  19.     if lam.didIceOpen == false then
  20.       lam.nextForm = "icegrapple"
  21.       if stance == "b" or stance == "n" then
  22.         lam.boostNext = true
  23.       elseif stance == "th" then
  24.         lam.headbuttNext = true
  25.         lam.didIceOpen = true
  26.       end
  27.     else
  28.       lam.nextForm = "rlm"
  29.       if stance == "n" then
  30.         lam.didIceOpen = false
  31.         lam.nextForm = "icegrapple"
  32.         lam.boostNext = true
  33.       elseif stance == "b" and tonumber(gmcp.Char.Vitals.pow) > 6 then
  34.         lam.boostNext = true
  35.       elseif stance == "th" and tonumber(gmcp.Char.Vitals.pow) > 7 then
  36.         lam.headbuttNext = true
  37.       elseif stance == "c" then
  38.         lam.lowNext = true
  39.         if target.hasAff("LLegDamaged") and not target.hasAff("RLegDamaged") then
  40.           lam.nextForm = "llm"
  41.         end
  42.      
  43.       elseif stance == "k" then
  44.         if tonumber(gmcp.Char.Vitals.pow) > 7 then
  45.           lam.regressNext = true
  46.           lam.lowNext = true
  47.           if target.hasAff("RLegMutilated") and target.hasAff("LLegDamaged") then
  48.             lam.nextForm = "llm"
  49.           end
  50.         end
  51.       end
  52.     end
  53.   end
  54. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement