[MUA1] The Guide to Wolverine's Rage System

Started by Outsider, May 04, 2017, 08:05PM

Previous topic - Next topic
May 04, 2017, 08:05PM Last Edit: June 08, 2020, 07:52AM by Outsider
What's up -- The Outsider here, back again with another lesson to help modders expand their projects to new heights. In this tutorial, I will discuss :wolverine: Wolverine's Rage System, and the secrets behind it. Class is now in session.



LECTURE
Ever since the vanilla version of Marvel: Ultimate Alliance back in 2006, Wolverine was THE standout character because of one reason -- his rage system. As Logan attacked or got attacked, a special meter of red dots would increase, and when it was filled, red smoke engulfed the berzerker mutant. He got stronger, faster, and most importantly, gained exclusive powers.



CODING -- TALENTS FILE
Wolverine's rage system is the very first special affecter, where certain events are triggered if a requirement has been met. (For more info on special affecters, see my tutorial about them.) However, Logan's special affecter is done a bit differently, in a more complicated method. So, what is this method? I'll show you. Let's now look at Wolverine's talents file...

This is the coding entry for his first power, his Claw Slash. Pay close attention to what is highlighted in bold red.

   talent {
   descname = Claw Slash ;
   description = Increased melee attack that causes bleed damage. ;
   descshort = Melee ;
   icon = 0 ;
   icon_texture = textures/ui/wolverine_icons.png ;
   name = wolv_p1 ;
   power = power4 ;
      talentvalues {
         talentvalue {
         level = 1 ;
         name = wolv_p1_req ;
         value = 1 ;
         }

         talentvalue {
         level = 5 ;
         name = wolv_p1_req ;
         value = 13 ;
         }

         talentvalue {
         level = 6 ;
         name = wolv_p1_req ;
         value = 16 ;
         }

         talentvalue {
         level = 9 ;
         name = wolv_p1_req ;
         value = 25 ;
         }

         talentvalue {
         level = 10 ;
         name = wolv_p1_req ;
         value = 28 ;
         }

         talentvalue {
         level = 14 ;
         name = wolv_p1_req ;
         value = 52 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_p1_req ;
         value = 72 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_p1_dmg ;
         value = 17 19 ;
         }

         talentvalue {
         level = 5 ;
         name = wolv_p1_dmg ;
         value = 58 64 ;
         }

         talentvalue {
         level = 6 ;
         name = wolv_p1_dmg ;
         value = 78 86 ;
         }

         talentvalue {
         level = 9 ;
         name = wolv_p1_dmg ;
         value = 109 120 ;
         }

         talentvalue {
         level = 10 ;
         name = wolv_p1_dmg ;
         value = 139 154 ;
         }

         talentvalue {
         level = 14 ;
         name = wolv_p1_dmg ;
         value = 221 244 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_p1_dmg ;
         value = 319 353 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_p1_bld ;
         value = 11 13 ;
         }

         talentvalue {
         level = 5 ;
         name = wolv_p1_bld ;
         value = 17 19 ;
         }

         talentvalue {
         level = 6 ;
         name = wolv_p1_bld ;
         value = 20 23 ;
         }

         talentvalue {
         level = 9 ;
         name = wolv_p1_bld ;
         value = 31 34 ;
         }

         talentvalue {
         level = 10 ;
         name = wolv_p1_bld ;
         value = 41 45 ;
         }

         talentvalue {
         level = 14 ;
         name = wolv_p1_bld ;
         value = 65 71 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_p1_bld ;
         value = 95 105 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_p1_pwr ;
         value = 8 ;
         }

         talentvalue {
         level = 5 ;
         name = wolv_p1_pwr ;
         value = 17 ;
         }

         talentvalue {
         level = 6 ;
         name = wolv_p1_pwr ;
         value = 19 ;
         }

         talentvalue {
         level = 9 ;
         name = wolv_p1_pwr ;
         value = 26 ;
         }

         talentvalue {
         level = 10 ;
         name = wolv_p1_pwr ;
         value = 28 ;
         }

         talentvalue {
         level = 14 ;
         name = wolv_p1_pwr ;
         value = 44 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_p1_pwr ;
         value = 55 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_frenzy_dmg ;
         value = 10 12 ;
         }

         talentvalue {
         level = 5 ;
         name = wolv_frenzy_dmg ;
         value = 17 19 ;
         }

         talentvalue {
         level = 6 ;
         name = wolv_frenzy_dmg ;
         value = 24 26 ;
         }

         talentvalue {
         level = 9 ;
         name = wolv_frenzy_dmg ;
         value = 34 38 ;
         }

         talentvalue {
         level = 10 ;
         name = wolv_frenzy_dmg ;
         value = 44 49 ;
         }

         talentvalue {
         level = 14 ;
         name = wolv_frenzy_dmg ;
         value = 75 83 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_frenzy_dmg ;
         value = 109 120 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_frenzy_inc ;
         value = 0.1 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_frenzy_inc ;
         value = 0.17 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_frenzy_life ;
         value = 3 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_frenzy_life ;
         value = 7 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_frenzy_pwr ;
         value = 5 ;
         }

         talentvalue {
         level = 5 ;
         name = wolv_frenzy_pwr ;
         value = 10 ;
         }

         talentvalue {
         level = 6 ;
         name = wolv_frenzy_pwr ;
         value = 11 ;
         }

         talentvalue {
         level = 9 ;
         name = wolv_frenzy_pwr ;
         value = 16 ;
         }

         talentvalue {
         level = 10 ;
         name = wolv_frenzy_pwr ;
         value = 17 ;
         }

         talentvalue {
         level = 14 ;
         name = wolv_frenzy_pwr ;
         value = 26 ;
         }

         talentvalue {
         level = 15 ;
         name = wolv_frenzy_pwr ;
         value = 33 ;
         }


      }

      level {
      description = %wolv_p1_dmg $DMG_PHYSICAL\n%wolv_p1_bld $DMG_BLEED\n%wolv_p1_pwr $EP ;
         tier {
         cost = 1 ;
         count = 5 ;
         }

         tier {
         cost = 2 ;
         count = 4 ;
         }

         tier {
         cost = 3 ;
         count = 1 ;
         }

         tier {
         cost = 3 ;
         count = 4 ;
         difficulty = hard ;
         }

         tier {
         cost = 4 ;
         count = 1 ;
         difficulty = hard ;
         }

         require {
         cat = level ;
         level = %wolv_p1_req ;
         }

      }

   }

Notice anything? See, the claw slash is named "wolv_p1" and is considered "power1." However, it does not say power1, it says "power4." Why? Because power4 is actually the rage version of power1 -- his Claw Frenzy. So, under the initial power's coding, power = the rage version's power #. The bold red coding you see are the talent values for the rage power, but it is placed also in the initial power. Why? Because they both unlock at "%wolv_p1_req."



Now, let's continue and look at his coding entry for his first rage power -- his Claw Frenzy, which follows after the Claw Slash entry above. Again, pay close attention to the words in bold red.

   talent {
   descname = Claw Frenzy ;
   description = Multiple slashing attacks with each hit increasing attack speed for a time. ;
   descshort = Melee ;
   icon = 3 ;
   icon_texture = textures/ui/wolverine_icons.png ;
   name = wolv_frenzy ;
   parent = wolv_p1 ;
   type = attack ;
      level {
      description = %wolv_frenzy_dmg $DMG_PHYSICAL\n+%wolv_frenzy_inc:p speed per hit for %wolv_frenzy_life seconds\n%wolv_frenzy_pwr $EP ;
         tier {
         cost = 1 ;
         count = 5 ;
         }

         tier {
         cost = 2 ;
         count = 4 ;
         }

         tier {
         cost = 3 ;
         count = 1 ;
         }

         tier {
         cost = 3 ;
         count = 4 ;
         difficulty = hard ;
         }

         tier {
         cost = 4 ;
         count = 1 ;
         difficulty = hard ;
         }

         require {
         cat = level ;
         level = %wolv_p1_req ;
         }


      }

   }

See that something called "parent" is there, taking the place of "power?" That's because this rage power is the offspring of an initial power. In this case, this rage power is named "wolv_frenzy" and is considered "power4." But power4 is not listed there, because it was already acknowledged eariler in Claw Slash (power1)'s coding. The "parent" is power1. You must place the correct parent, or the child power will not work correctly. Also, see how the requirement to unlock this rage move is the same as the requirement for the initial power? Both are unlocked at the same level. There are no talent values listed in this entry because they are in the initial power's (or "parent's") coding entry. With this method, the two powers are now inseparable. (Note the part that says "type=attack?" This is not important, as some child powers can be boosts or even Xtreme powers.)

All of Wolverine's powers in the talents file follow this same method. The rage power is the child of the parent (the initial power) that you see in the game. The rage powers are hidden, locked under a special affecter. You won't see them in the game unless the special affecter's requirement has been met. If you understood this, good -- you've got past the complicated part. The next part's easier, but just as critical.



CODING -- POWERSTYLE FILE
Now that you've understood the method used in Wolverine's talents file, it's time to now look at the coding entries for those same powers in Logan's powerstyle file. It's very simple in comparison. Let's look at the coding entry (called a "Fightmove") for his first power -- his Claw Slash. Note that I will only display this entry up to the requirements, and not the whole Fightmove. As usual, play close attention to the words in bold red.

   FightMove {
   aitype = melee ;
   animenum = ea_power1 ;
   combotextfinisher = Slash ;
   combotextstarter = Severing ;
   icon = 0 ;
   is_power = true ;
   lockangles = true ;
   name = power1 ;
   powerup_tag = wolv_power1 ;
   priority = 5 ;
      require {
      cat = skill ;
      item = wolv_p1 ;
      level = 1 ;
      }

Did you notice that there are no words in bold red? Exactly. Nothing special is done with the parent power -- remember that. Notice that the "name" here is "power1." This lets the game know that this power is the parent, or initial power. Do not change that, or it will not work. Now, let's look at the Fightmove for his first rage power -- his Claw Frenzy. Again, I will only display this entry up to the requirements, and not the entire Fightmove. Pay attention to the words in bold red.

   FightMove {
   aitype = melee ;
   animenum = ea_power4 ;
   combotextfinisher = Slice ;
   combotextstarter = Rending ;
   fallback = power1 ;
   handler = ch_wolv_frenzy ;
   icon = 3 ;
   is_power = true ;
   name = power4 ;
   powerup_tag = wolv_power4 ;
   priority = 5 ;
   priority_override = 5 ;
   startchaintime = 0.85 ;
   storepowerbuttons = true ;
   turnrate = 0.2 ;
      require {
      cat = skill ;
      item = wolv_p1 ;
      level = 1 ;
      }

      require {
      cat = affecter ;
      item = enraged ;
      level = 1 ;
      }


Ah, now you see bold red words. Something was added called "fallback," and it says "power1." The fallback tells the game which parent power that this child power belongs to. In this case, Claw Frenzy is named "power4," and its' parent is power1. Without the fallback line, it will not work. Also, notice that there is a second requirement named "enraged?" This is referring to the special affecter (named "enraged" in this case), telling the game that this power cannot be used until the special affecter has been met. When the special requirement has been met, the parent power will be replaced with the child power.

All powerstyle entries (Fightmoves) use this same method, as it confirms the connection between the two powers that you made in the talents file.



NOTE ON SPECIAL AFFECTERS
Using special affecters, all child powers do not have to come from a meter. It depends on what special affecter you've placed for a mod. For example, my mod of Black Canary has a set of powers (the parent powers), but I've placed a special affecter around both costumes of Batgirl. So, when the player selects either skin of Batgirl, the special requirement has been met. Thus, all child powers are unlocked for only Batgirl to use. (Again, for more info on special affecters, see my tutorial about them.)

So, now you know the secrets behind Wolverine's Rage System. I hope this tutorial has provided some clarity, and may you learn how to use it to perfect some of your mods as I have. Class dismissed.



May 04, 2017, 11:48PM #2 Last Edit: May 04, 2017, 11:50PM by Dorpond
Thanks for such amazing tutorial.
Is this a possible to fully transfer rage system (with dots on panel, exclusive powers and etc.)  into different character?
My releases: http://marvelmods.com/forum/index.php/topic,9772.0.html

UPD since 30.11.2021
I'm ok and will be back to modding as soon as i can
I can gurantee what i will back with a lots of new ideas and finish old projects.
Right now i'm not mod and only posting posts thank you if you readed this!

What about the ones on Hulk, since his rage is universal boost up via attacks
Call me Lars. I'm Power Cosmic no more.

"Trying to solve mysteries of modding here"

My Progress:
http://marvelmods.com/forum/index.php/topic,4671.0.html

Feel free to mod my releases, as long you credit me:
http://marvelmods.com/forum/index.php/topic,4488.0.html

Quote from: LarsAlexandersson on May 05, 2017, 03:21AM
What about the ones on Hulk, since his rage is universal boost up via attacks

Not sure what you mean. Are you talking about his Fury boost? From what I've seen, Hulk has no special entries in either his talent or powerstyle files -- not in his vanilla version, anyway. I have the Hulk where he grows in size and strength as his health gets lower -- that was done via a booster by (I think) Nowhere Man.

Quote from: Dorpond on May 04, 2017, 11:48PM
Thanks for such amazing tutorial.
Is this a possible to fully transfer rage system (with dots on panel, exclusive powers and etc.)  into different character?

Yes, it is possible. In Wolverine's powerstyle file, he added this...

   FightMove {
   animenum = ea_idle1 ;
   name = rage_node ;
      trigger {
      life = %wolv_rage_time ;
      name = powerup ;
      tag = 1 ;
      time = -1 ;
         special_fx {
         bolt = Bip01 Pelvis ;
         effect = char/wolv/rage_aura ;
         fxlevel = 1 ;
         how_used = primary ;
         never_cycle = true ;
         }

         affecter {
         attribute = enraged ;
         level = 1 ;
         }

      }

      chain {
      action = idle ;
      result = idle ;
      }

   }



While in his talents file, he added this...

   talent {
   hidden = true ;
   icon = 14 ;
   name = wolv_rage ;
      talentvalues {
         talentvalue {
         level = 1 ;
         name = wolv_rage_req ;
         value = 1 ;
         }

         talentvalue {
         level = 1 ;
         name = wolv_rage_time ;
         value = 30 ;
         }

      }

      level {
      count = 1 ;
         require {
         category = level ;
         level = %wolv_rage_req ;
         }

         powerup {
         class = berserker_rage ;
         life = -1 ;
         ragenode = rage_node ;
         ragetag = 1 ;
         ragetime = %wolv_rage_time ;
         tag_name = berserker_rage ;
            affecter {
            attribute = rage ;
            level = 0.025 ;
            }

            powerup {
            life = 5 ;
            renderfx = enraged ;
               affecter {
               attribute = enraged ;
               level = 1 ;
               }

            }

         }

      }

   }

These two parts create his special affecter. He also added the bold red parts to his herostat that creates the dots at his HUD...

   stats {
   ailevel = 1 ;
   autospend = bruiser ;
   body = 7 ;
   canbeallythrown = true ;
   characteranims = 03_wolverine ;
   charactername = Wolverine ;
   gen_charge_color = 0.8 0.2 0.2 1 ;
   level = 1 ;
   level_every_skill_reward = 99 ;
   menulocation = 7 ;
   mind = 4 ;
   name = Wolverine ;
   playable = true ;
   powerstyle = ps_wolverine ;
   scriptlevel = 3 ;
   skin = 0301 ;
(and so on.)

I'm sure if you mimic these entries and customize them to a different character's specifics, you can recreate his rage system. I haven't attempted that, so you may run into some unforeseen problems, though. And, I am unsure if you can change the color of the dots.



I look into Hulk's powerstyle & talents, i think i saw his Rage Boost codes there. If you attack all enemies as Hulk many times. His rage effect around his body will come out
Call me Lars. I'm Power Cosmic no more.

"Trying to solve mysteries of modding here"

My Progress:
http://marvelmods.com/forum/index.php/topic,4671.0.html

Feel free to mod my releases, as long you credit me:
http://marvelmods.com/forum/index.php/topic,4488.0.html

Quote from: LarsAlexandersson on May 05, 2017, 05:37PM
I look into Hulk's powerstyle & talents, i think i saw his Rage Boost codes there. If you attack all enemies as Hulk many times. His rage effect around his body will come out

Hmm... that sounds similar to Wolverine. Can you display the coding from both files? I can then see if a special affecter was used, or another method.


From Talent:

   talent {
   hidden = true ;
   icon = 1 ;
   name = hulk_rage ;
      talentvalues {
         talentvalue {
         level = 1 ;
         name = hulk_rage_req ;
         value = 1 ;
         }

         talentvalue {
         level = 1 ;
         name = hulk_rage_time ;
         value = 15.0 ;
         }

         talentvalue {
         level = 99 ;
         name = hulk_rage_time ;
         value = 120.0 ;
         }

      }

      level {
      count = 1 ;
         require {
         category = level ;
         level = %hulk_rage_req ;
         }

         powerup {
         class = berserker_rage ;
         life = -1 ;
         ragenode = rage_node ;
         ragetag = 1 ;
         ragetime = %hulk_rage_time ;
         tag_name = berserker_rage ;
            affecter {
            attribute = rage ;
            level = 0.025 ;
            }

            powerup {
            life = 5 ;
            renderfx = enraged ;
               affecter {
               attribute = enraged ;
               level = 1 ;
               }

            }

         }

      }

   }


From Powerstyle:

   FightMove {
   animenum = ea_idle1 ;
   name = rage_node ;
      trigger {
      life = %hulk_rage_time ;
      name = powerup ;
      tag = 1 ;
      time = -1 ;
         special_fx {
         bolt = Bip01 Pelvis ;
         effect = char/wolv/rage_aura ;
         fxlevel = 1 ;
         how_used = primary ;
         never_cycle = true ;
         }

         affecter {
         affect_type = scale ;
         attribute = atk_damage ;
         level = 3.0 ;
         scope_non_powers = true ;
         }

      }

      chain {
      action = idle ;
      result = idle ;
      }

   }
Call me Lars. I'm Power Cosmic no more.

"Trying to solve mysteries of modding here"

My Progress:
http://marvelmods.com/forum/index.php/topic,4671.0.html

Feel free to mod my releases, as long you credit me:
http://marvelmods.com/forum/index.php/topic,4488.0.html

Ok, thanks. I don't have that coding on my Hulk... It appears to be an exact replica of Wolverine's Rage System -- right down to Logan's aura (though I say Hulk's aura should be green instead). The only difference I see is that his attack damage goes much higher when activated. Nonetheless, the same rules mentioned in the tutorial would apply here as well.