Jump to content

A Little Help In Editing Gunner Class


srujanteja

Recommended Posts

So Yea

I Was Modding This Long War Mod Cause I Was Too lazy To Make My Own From The Scratch .. Yea Well Dw I Am Just Gonna Use It For Personal use Not Gonna Steal The Mod .. Modify And Rename And Well Upload And Take Credits if ur Worried
And Here AM Stuck With A Big Problem
All Is Well Till Now ..
I Have Edited The Abilities My Classes Want .. Well Basically Everything Went Fine Except For One Thing
My Heavy (Gunner Class To Be Specific) Class Troopers Were Unable To Equip The LMG's I Did Changed The Value To Heavy And Still They Were Unable
My Rockeeter Can Equip It With Np's But The Gunner Class Was Unable To Equip
He Was Able To Rquip It When I Changed The parameters To Either Support Or Just Rifle Or Normal
My Guess
The Gunner Class Is Classified Under Support Class
I Dont Want Him In Support Class . And I Dont Want My Support Class To Run With Heavy Plasma And Heavy Cannons ... cause Its Just Ridiculous
So Just Asking If Anyone Can Tell me A Way To Change That And Reassign Gunner To Heavy Class So he Can Equip The LMG's
Link to comment
Share on other sites

When we created the subclasses and split the Heavy into Gunner/Rocketeer, there was the small problem that in vanilla both the LMG-class and Rocket-class weapons were marked with the eWP_Heavy property.

 

In vanilla the eWP_Support weapon property wasn't used, as there are no Support-specific weapons. There is a separate eWP_Rifle weapon property for rifles. So, we set up the Gunner class to be able to equip weapons with the eWP_Support flag and Rocketeers to be able to equip weapons with the eWP_Heavy flag. The LMG-class weapons were then changed to have the eWP_Support property in the DGC.ini.

 

There were also a lot of other changes in the class-assignment and loadout code that had to be done in order to separate out the two subclasses from each other. Depending on what you are trying to accomplish this could be tricky or not.

 

Which class weapons can be equipped to a particular soldier is set in XGStrategySoldier.SetClass via the assignments:

        case 3:
            m_kSoldier.kClass.eWeaponType = 7;

The switch/case is based on perk. This is the ID of the perk selected at squaddie, which is what is passed to the SetClass function. In this example the perk is 3 = ePerk_SquadSight, indicating that the Sniper subclass was selected. The weapon type is then 7 = eWP_Sniper. Similarly the Suppression perk (selecting Gunner subclass) sets the soldier's eWeaponType to the eWP_Support weapons types.

 

I think the primary issue you are likely having (if I understand what you are trying to accomplish) is based upon changing the squaddie perks. If you change the squaddie perks then you have to change the perk cases in the SetClass function correspondingly.

 

The default eWeaponType for a soldier (if no perk matches what was passed) is eWP_Rifle. So if you changed the Gunner squaddie perk to something other than Suppression that's the issue.

 

The particular code is :

        case 21:
            m_kSoldier.kClass.eWeaponType = 4;

The case 21: is referring to the Suppression perk. Changing the squaddie perk requires changing the value in the case statement in order to still have the correct weapons be equippable.

Link to comment
Share on other sites

Umm ... Ouch .... Now That Seems A Bit Complicated For Me @_@

 

But Hey That Explains A Lot And Now I Know What I Must Do .. Ty So Much For The Info

 

I Gave My Heavy ROCKET LAUNCHER And Rapid Fire

 

So Now I Need To Change Case To Match Rapid Fire Like

 

case what ever is rapid fire number:
m_kSoldier.kClass.eWeaponType = what ever is Heavy weapons Number;

 

And change Grenadier To Fire Support Weapons :D Instead Of Assault Weapons

 

Now If U Can See ... Am Still A Noob At Modding ... I Just Use Resource Hacker And Notepad ++ And Was Able To Edit Perks Using Some Online Program And Install Them Using XCom ToolsBox

 

Ill Be More Than Happy If U Can Provide Me The Path Where I Can Find The File That Needs To Be Edited And Tools/Software Which Can Open/Edit It

 

 

Oh Oh .. I Also Forget ... I Would Love To Have 2 Abductions At A Time ... Makes The Game A Bit More Interesting And Challenging ..

 

U Can Tell Me How To Do That If It Dosent Have Any Side Effects On The Rest Of The Game

 

Well Just Those 2 And Am Good 2 Go :D

Edited by srujanteja
Link to comment
Share on other sites

The easist way to track down enum values is via Bertilsson's reverse enum lookup tool : http://hem.bredband.net/bertrich/XCOM/ReverseLookup.htm

 

I use this all of the time. Just put 'rapid' in the name search box and look through the few results.

 

I think I'm not sure what your goal is with the changes to the Engineer (grenadier) and Gunner.

 

If you change the Gunner (defined with the ePerk_RapidFire) to be able to equip eWP_Heavy weapons, then it will only be able to equip rifles and rocket launchers. Unless you are changing the LMG-class weapons back to eWP_Heavy as well, in which case Rocketeers will be equipping LMGs + Rocket Launchers, while Gunners will only be getting LMGs.

 

Changing Engineer to eWP_Support will enable them to equip LMG-class weapons (if the DGC.ini isn't changed) or only basic rifles (if the DGC.ini is changed). Currently Engineers get the same weapon choices as Assaults : Rifles and Shotguns. In an earlier version of the mod they were given access to eWP_Rifle, which limits them to rifles (including Plasma Rifles).

 

 

Currently in Long War:

Every soldier (not SHIV) gets access to three 'core' large-item weapons : Assault Rifle, Laser Rifle, and Plasma Carbine. Note that Plasma Rifle isn't on this list ^_^

eWP_Assault = all rifles + shotguns

eWP_Rifle = all rifles, including plasma rifle

eWP_Sniper = Sniper-class rifles

eWP_Heavy = Rocket Launchers

eWP_Support = LMG-class weapons

 

SHIVs have their own special marker of eWP_Integrated, which applies to both weapons and small items. However, this causes locker list filting instead of just marking as unavailable.

 

----------------

 

As to the abduction changes I don't have any idea. Johnnylump made all of those changes, so hopefully he'll drop in and drop some hints.

Link to comment
Share on other sites

Ah .. Pardon Me .. I Was Not Clear ..


Lemme Be Clear Now


Basically I Made My Heavy Class Live Up To Their Name ...


The Perks I Gave Them Include Mayhem, Bring Them On, Resilient, Extra Conditioning, Will To Survive, Heat Ammo, Rapid Fire


Which Basically Turns Him Into A Tank ... But I Did Reduced The Total Accuracy For Heavy Class


While Snipers And Assault And Medics Get +50, +20, +20 Aim Respectively On Lvl Up ( I Mean When They Are Fully Leveled Up) Gunner Only Get 10 Aim Which Ofc Makes The Game Balance Cause Its Like HIT LESS DO MORE


To Suffice This ... I Granted Even The Most Basic Of Enemies +20 Defense ...


I Also Changed The Solder's Min , Max Aim If Chosen NOT CREATED EQUALLY 65 ~ 75


So Now Snipers Total Aim Including Laser Sights And SCOPE And Fully Leveled Will Be = 140


The Solder Max Aim possible (perks excluded) Are As Below

====================================================

Rookie Solder Aim = 75 + 5 + 10 = 90 aim


Fully Leveled Heavy Aim = 75 + 5 + 10 + 10 = 100 aim


Fully Leveled Support aim = 75 + 5 + 10 + 20 = 110 aim


Fully Leveled Assualt aim = 75 + 5 + 10 + 20 = 110 aim


Fully Leveled Sniper = 75 + 50 + 5 + 10 = 140 aim


Aim Is Added As Base + Lvl Up Aim + Laser Sights + Scope In Order



To Balance Things I Also Changed The Defense Of Enemies


The Max Def On Enemies Now Is 50 (For EtherealUber And Ethereal) And Min Being 20 For Everything That Had 0 Defense Before


I Have Also Increased The Aim Of Enemies By 5 To Balance Things


Now A Sectoid In Full Cover Will Get 60 Defense While In Half Cover Will Get A 40 Defense


And EtherealUber Will Get A Woophing 50 + 40 Defense In Full Cover And 70 Defense In Half Cover ... (Just Makes The Game Harder)


I Have Also Gave Defense For Solders On Level Up As Follows


Support Defences

==================

Base - 0/10 (0 for impossible)


smoke - 20/40 (40 for dense smoke)


cover 20/40


stats - 10


armor - 20


perks - + 20 for low cover (only counts if part cover is taken) + 20 for tactical sense


Total max = 0 + 40 + 40 + 10 + 20 + 20 = 130 (added in order base + smoke + cover + stats + armor + perks)


Total usually possible = 0 + 0 + 40 + 10 + 20 + 0 = 70

===============

Heavy Defences

==================

Base - 0/10 (0 for impossible)


smoke - 20/40 (40 for dense smoke)


cover 20/40


stats - 10


armor - 10


perks - 0


Total Max Possible = 0 + 40 + 40 + 5 + 10 + 0 = 75


Total usually Possible = 0 + 0 + 20 + 5 + 10 = 35

===============

Assualt Defences

==================

Base - 0/10 (0 for impossible)


smoke - 20/40 (40 for dense smoke)


cover 20/40


stats - 5


armor - 10


perks - + 20 tactical sense


Total Max Possible = 0 + 40 + 40 + 5 + 10 + 20 = 115


Total usually Possible = 0 + 0 + 20 + 5 + 10 = 35

===============

Sniper Defences

==================

Base - 0/10 (0 for impossible)


smoke - 20/40 (40 for dense smoke)


cover 20/40


stats - 10


armor - 10


perks - + 20 low profile


Total Max Possible = 0 + 40 + 40 + 10 + 10 + 0 = 100


Total usually Possible = 0 + 0 + 20 + 10 + 10 = 40


And I Flagged LMG's As Heavy


There Are Basically A Number Of Changes I Did ... Like


I Reduced The Rest Time For Solders From 5 Days To 1 Day And Also Reduced Injured Duration To 10 Days


Basically Cause I Love The Game To Be Played With Char's Named After My Friends And People I Consider As Hero's And Well I Dont Have Much Friends Lol Or Hero's And Also I Love The Movie Expendables .. So Wanted My Team To Be Like Them


I Also Edited Gun Ranged ... Like Laser Guns Have +5 More Range Than Normal And Plasma Have -5 Less Range Than Normal The Max Being 30 For Laser Rifles Min Is 5 For Alloy Cannon And Short Guns (Well Alloy Cannon Is So OPED)


Oh Yes I Forget To Mentioned ... I Doubled The HP Of Aliens (Just Aliens) So That The Game Takes A Little Longer Rather Than Cake Walk And I Play Game On Impossible


I Also Tried Renaming All The Engineers To Geeks And All Scientists To Nerds Lol But Too Bad It Didnt Work D:


And Change The Description Of Impossible - MAKES GROWN MEN CRY


Now Coming To The Question .. I Downloaded Some UPK Modding Tools And Decompressed XComGame And XComStrategy And Found That XGSTRATEGYSOLDER In XComStrategy




And Verified Them With The Link U Gave Me ...


Am Almost Done And At The End ...


The Thing I Want To Make Is


I Want My Medics And Engineers Flagged As Support And They Will Be Able To Carry Light Weaponry Like Light Plasma Rifle , Laser Rifle , Assualt Rifle .. Cause Their Focus Is More On Supporting The Squad Than Killing The Enemies


While The Assualt Class Can Use A Wide Variety Of Guns Except Snipers And LMG's


The Only One Who Will Be Able To Carry LMG's Will Be Heavy Class (Gunners And Rocketeers)


That's The Change I Have Planned


What I Did Is Decompress The XComStrategy.Ukp And Use UE Explorer To Find The Code I Need


And Well I Want To Do This


Change




case 21:

m_kSoldier.kClass.eWeaponType = 4;


To


case 36:

m_kSoldier.kClass.eWeaponType = 8;


Making Gunner Able To Equip Heavy Class Weapons


And


case 24:

m_kSoldier.kClass.eWeaponType = 6;


To



case 24:

m_kSoldier.kClass.eWeaponType = 4;


Making Engineer Equip Support Class Weapons (Light Plasma, Laser Assault Rifles Yada Yada)


In Short .... All I Need To Know Is .. How Can I Make Those Changes ... Cause UE Explorer Wont Allow Me To Edit =V




Sorry For LONG BORING POST ... Also Sorry For Nor Being Able To Reply Quickly =V


And Am Sorry If I Offended Anything ... I Know Ur The Chief Programmer And Deputy Designer For My Most Fav Long War Mod .. Then Again I Just Did These Changed To Just Match My Personal Needs ... Nothing Else .. Ty For Ur Time In Reading And Answering ^^

Edited by srujanteja
Link to comment
Share on other sites

Coming To The Abductions I Just Found The Right One

 

XComGameStrategy.upk
Reduce base abductions per attempt from 3 to 1:
XGStrategyAI.GetNumAbductionSites
2C 03 04 3A 4B
to
2C 01 04 3A 4B

 

Found That In http://forums.nexusmods.com/index.php?/topic/880418-long-war-upk-changes/

Link to comment
Share on other sites

 

Making Engineer Equip Support Class Weapons (Light Plasma, Laser Assault Rifles Yada Yada)

 

Rifles etc are not the Support Class weapons. In the vanilla game there are NO weapons with the eWP_Support category.

 

I think what you'll want to do is give Engineers the eWP_Rifle (so will be the same as Medic).

 

To give both Gunners and Rocketeers access to both LMGs, you'll have to switch Gunners to eWP_Heavy and then change the DefaultGameCore.ini file to change the LMG-class weapons to have eWP_Heavy (like vanilla -- in Long War they were switched to eWP_Support).

 

After switching the LMG-class weapons there will be NO defined weapons with the Support property. Any class you give access to eWP_Support will be limited to only the basic rifles -- they will not be able to equip the Plasma Rifle.

Link to comment
Share on other sites

YES !! :D ... That Is Exactly What I Want To Know How To Do

 

As UE Explorer Wont Allow Me And I Cant Find Any HEX Codes

 

Any Tools And Guide On How To Make Changes Will Be Of Great Help

Edited by srujanteja
Link to comment
Share on other sites

Now you need to start using the XCOM Wiki.

Begin with 'Category:0 Start Here' Read all the articles in that category.

For tools you want 'Modding Tools'.

Then look into the category 'XCOM Modding' for details about particular files. In particular, be sure to read 'Modding XCOM'. It will get you started in the 'how to' of making changes.

 

And just a point of minor forum etiquette. Generally we only capitalize the first word of a sentence and proper names. Putting a word into all capitals is considered the equivalent of "shouting". Capitalizing the first letter of all words as you are doing is simply a bit jarring, not offensive. :confused:

 

-Dubious-

Edited by dubiousintent
Link to comment
Share on other sites

Ty For The Info .... Ill Start It Right There :D

 

Btw Sorry Lol :D ... Its Not Like Shouting .... Its Just My Way Of Typing ... Capitalizing The First Word Of Every Word Makes The Text Umm Kinda Appealing ... Well For Me ...

 

THIS IS NOW SHOUTING Lol

 

Anyway .... Ty For The Links :D

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...