Kregano Posted April 1, 2016 Share Posted April 1, 2016 I'm trying to build a sword based multihit ability for Rangers that unlocks via the GTS. I've already extended the RangerAbilitySet.uc and AcademyUnlocks.uc files, but the GTS button for the ability doesn't show up. Did I miss something, like using a specific set of commands in the localization file to get it to show up? Also, would it be possible to set up an array or something like that to control how many hits a soldier gets per rank? For example, a Squaddie would get 2, while a Colonel would get 8 (yeah, I know that's OP, but that's part of the point of this mod). Link to comment Share on other sites More sharing options...
davidlallen Posted April 1, 2016 Share Posted April 1, 2016 (edited) I don't know which file controls the GTS ability list, but it isn't the localization file. In the pinned resource list in the next-door "mod talk" forum, you can see some good places to look for information. In particular, the rifleman mod is one of the first ones to come out, and it includes a GTS skill. I recommend subscribing to this mod, looking at all the files, and figuring out how it works. When you say "hits a soldier gets", do you mean hit points? Or action points? For hit points, this is an easy ini file change. I guess you have already found this file if you have added an ability. For action points, IMHO it would totally unbalance the game if a soldier had more than say, three action points. I highly doubt there is an easy way to mod that, but I could be mistaken. Edited April 1, 2016 by davidlallen Link to comment Share on other sites More sharing options...
Kregano Posted April 1, 2016 Author Share Posted April 1, 2016 I don't know which file controls the GTS ability list, but it isn't the localization file. In the pinned resource list in the next-door "mod talk" forum, you can see some good places to look for information. In particular, the rifleman mod is one of the first ones to come out, and it includes a GTS skill. I recommend subscribing to this mod, looking at all the files, and figuring out how it works.Not a super big fan of having to download more mods to reverse engineer them, but *shrug* When you say "hits a soldier gets", do you mean hit points? Or action points? For hit points, this is an easy ini file change. I guess you have already found this file if you have added an ability. For action points, IMHO it would totally unbalance the game if a soldier had more than say, three action points. I highly doubt there is an easy way to mod that, but I could be mistaken.Well, I'm basing the multistrike part of the ability on FanFire, which uses this bit of code to get the player to hit the enemy three times: BurstFireMultiTarget = new class'X2AbilityMultiTarget_BurstFire'; BurstFireMultiTarget.NumExtraShots = 2; Template.AbilityMultiTargetStyle = BurstFireMultiTarget; Theoretically, I could make a function calling for the soldier's rank, set a number of extra shots for each class, and then have the ability reference that, right? Link to comment Share on other sites More sharing options...
davidlallen Posted April 2, 2016 Share Posted April 2, 2016 Not a super big fan of having to download more mods to reverse engineer them, but *shrug*It is the best way to learn. It is possible, but unlikely, that somebody will come by and post the entire piece of code that you need, all written out for you. It is not that simple to vary the effect based on level. The template, which you are looking in, is created once before the game even starts. You need a way to change that value at the start of a tactical game. I am not an expert at that yet, but you may need to set BuildNewGameStateFn and in that function, find the weapon state and change the value. That may sound like greek to you, and I am not sure it is right; but you can take away that there is a lot to learn about this level of modding. Link to comment Share on other sites More sharing options...
Recommended Posts