XCOM 2
811 个评价
[WOTC] Additional Soldier Console Commands
2
2
2
2
   
奖励
收藏
已收藏
取消收藏
文件大小
发表于
更新日期
178.583 KB
2018 年 4 月 25 日 下午 11:10
9 月 28 日 下午 4:55
14 项改动说明 ( 查看 )
您需要 DLC 才能使用该物品。

订阅以下载
[WOTC] Additional Soldier Console Commands

在 shiremct 的 1 个合集中
Proficiency Class Pack Suggested Mods Collection
94 件物品
描述
[WOTC] Additional Soldier Console Commands

Currently adds several new console commands that can be used from the armory and one command used in tactical missions. Though the commands may be used to do cheaty things, the primary purpose of these commands are to help modders test and players integrate/update mod changes in their on-going campaigns:


LevelUpSelectedSoldier
LevelUpSelectedSoldier Ranks[INT] Example - Level up the selected unit by 2 ranks: LevelUpSelectedSoldier 2
Levels up just the currently selected soldier in the armory screen. The optional Ranks parameter lets you specify how many ranks to increase (defaults to 1 if unspecified).


RebuildSelectedSoldiersClass / ResetSelectedSoldiersClass
RebuildSelectedSoldiersClass OPTIONAL_ChangeClassTo[FName] OPTIONAL_SetRankTo[INT] Example - Change the currently selected unit to a rank 1 (squaddie) Ranger: RebuildSelectedSoldiersClass Ranger 1
Refreshes the ability tree and rerolls the XCOM abilities for the currently selected soldier in the armory screen. Used to update a class ability tree on an existing soldier that has been changed due to new mods or mod updates. Can use the optional parameters to change the soldier's class and set their rank (up or down).

RebuildSelectedSoldiersClass attempts to preserve a soldier's stats from randomized stats, covert ops bonuses, etc. Use ResetSelectedSoldiersClass command to reset all stats to base and reroll randomized stats from Point-Based NCE, Hidden Potential, etc.

Use this instead of the vanillia MakeSoldierAClass command to change classes. The vanillia command does not properly support things like Beta Strike, NCE, XCOM/AWC Abilities, etc. Also supports classes that use the Highlander's ClassesExcludedFromAWCRoll functionality.


RebuildAllSoldiersClass
RebuildAllSoldiersClass
Refresh the soldier's ability tree and XCOM abilities for All soldiers in the barracks. Does not change class or rank.


SetSelectedSoldiersStat
SetSelectedSoldiersStat eStat_Type[BYTE] Stat_Amount[FLOAT] OPTIONAL_ModifyExistingStatBase[BOOL] Example - Change the currently selected soldier's Hacking to 50: SetSelectedSoldiersStat eStat_Hacking 50 Example - Modify the currently selected soldier's Will by +20: SetSelectedSoldiersStat eStat_Will 20 true
Sets the currently selected soldier's eStat to the specified value or, if the optional bool OPTIONAL_ModifyExistingStatBase is set to true, modifies the existing base stat by the specified value.


SetSelectedSoldiersComInt
SetSelectedSoldiersComInt eComInt_CombatIntelligence[BYTE] Example - Change the currently selected soldier's Combat Intelligence to Gifted [2]: SetSelectedSoldiersComInt 2
Sets the currently selected soldier's Combat Intelligence level - use a value between 0 (standard) and 4 (savant). This will try to adjust the soldier's AP accordingly and WILL adjust it into the negative if you drop Combat Intelligence and have already spent the AP (meaning the next ability you purchase with AP on that unit will take extra XCOM AP to cover the difference). Be careful of the resistance cards that boost AP gain - it will calculate expected AP values based on the current value.

Modified from code initially provided by PZ.


ReloadWeapon
ReloadWeapon
In a tactical mission, reloads the currently selected unit's primary weapon.


Thanks and Credits
  • PZ for providing the initial code for the command to set Combat Intelligence.
  • Zelfana and Tedster for assistance updating functions.

Version History
(See Change Notes for full history)
    1.5.0
    • New command ResetSelectedSoldiersClass that resets all stats as RebuildSelectedSoldiersClass did before.
    • RebuildSelectedSoldiersClass will now try to preserve a unit's stat changes from stat randomization, covert ops bonuses, etc.
    1.4.0
      1.4.3
      • Fix compatibility with No Rank Up Throttling.
      • Fix compatibility with LWotC.
      1.4.0
      • Refactor of most commands to improve functionality and compatibility.
      • Rebuilding soldiers now properly allows any 'UnitRankUp' Event Listeners that want to trigger on specific ranks a chance to fire.
      1.3.3
      • Fixed issues with XP allocation for Rebuild and LevelUp soldier commands.
      1.3.2:
      • Fixed issue with AcceptedCharacterTemplates when using RebuildSelectedSoldiersClass command for classes with CharacterTemplate limitations.
      1.3.1:
      • Fix for incorrect XP allocation when using RebuildSelectedSoldiersClass command and changing a unit's level.
      1.3.0:
      • Added SetSelectedSoldiersStat command to set or modify an eStat for the selected soldier.
      • Updated RebuildSelectedSoldiersClass command to remove any PCS chip they may have equipped and return it to the HQ inventory.
      1.2.1:
      • Small bugfix for the LevelUpSelectedSoldier command.
      1.2.0:
      • Added a RebuildAllSoldiersClass command that will refresh the ability trees and XCOM abilities for All soldiers in the barracks.
      1.1.1:
      • Added a ReloadWeapon command that will reload the selected unit's primary weapon in tactical.
      1.1.0:
      • Added the SetSelectedSoldiersComInt command (thanks to PZ).
      • Added Console feedback messages indicating errors and successful command completions.
      • Updated the RebuildSelectedSoldiersClass command to reapply stat modifiers (like Beta Strike HP, NCE stats, etc.) to the unit. Note that randomized stats (NCE, Hidden Potential, etc.) will be rerolled.
      • Updated the RebuildSelectedSoldiersClass command to enforce a class' required character templates (ex: you cant make a skirmisher character into a templar class).
      1.0.0:
      • Initial Release!.
    If you think there is a need for additional commands, leave a suggestion.
热门讨论 查看全部(5)
4
9 月 4 日 上午 1:42
How to get a list of available classes for RebuildSelectedSoldiersClass?
Empi3
3
4 月 14 日 下午 10:10
Command to add/remove specific traits/abilities?
Lief
4
2024 年 1 月 23 日 上午 12:47
Would it be possible to add commands to break and create bonds?
Nadarith
270 条留言
shiremct  [作者] 9 月 28 日 下午 5:10 
Important update - RebuildSelectedSoldiersClass now attempts to retain any stat changes a unit has from randomized stat sources, covert ops bonuses, etc. This was a long-requested feature, so now if you need to rebuild a soldier mid-campaign, they will no longer lose their existing identity and earned bonuses!

A new command was added, ResetSelectedSoldiersClass, that resets everything as before when this is needed/desired.
Canthyse 9 月 3 日 上午 10:43 
As others were pointing out, RebuildSelectedSoldiersClass its giving XP and free Stats to the selected soldier (not all barracks). Every time you use it, the soldier keeps accumulating stats. It doesnt matter if injured/tired. It doesnt go back to the original stats.
Really gamebreaking if you modify your soldiers a lot or the class mod author updates.
A temporal fix would be using the SetSelectedSoldierStat command and manually change to the original values after the Rebuild. But still the XP gain, i dont know how to fix that.
KrzepkiSzpinak 8 月 30 日 上午 12:40 
RebuildSelectedSoldiersClass is now granting xp to whole barracks for some reason..
ODST Kaneki 5 月 16 日 上午 3:35 
I just discovered a bug: Using RebuildSelectedSoldiersClass on a soldier who has temporarily modified stats (injured/tired, for example) the stat will BECOME PERMANENT. So it is best to wait until the soldier is fully healed and refreshed before using this command.
EzT 4 月 8 日 下午 2:19 
Also, you remove progress by destroying the red facilities. Some missions also reduce avatar project as a reward. Covert actions is also a good way if you have WOTC
EzT 4 月 8 日 下午 2:18 
This mod does not, but there is one by default. Do "RemoveFortressDoom <int>"
Rea 4 月 8 日 下午 2:14 
Hey, does this mod have a command to reset the Avatar Project? I'm just starting out and I have no clue how the sabotage missions work. I don’t get any, and I keep scanning spots over and over but nothing triggers. Would be nice to have a safety option, just in case.
Agane 3 月 9 日 下午 3:46 
Godbless this mod. Saved me many soldiers from my modding mistakes 🙈
Jestimac 1 月 11 日 上午 6:51 
I would like to generate 4 new recruits. Is there a console command allowing to do this ?
Jestimac 1 月 10 日 下午 9:09 
@ChrisZero
Hello. After getting stuck myself, I finally found what was wrong.
The command lines that works are
SetSelectedSoldiersComInt eComInt_gifted
SetSelectedSoldiersComInt eComInt_genius
SetSelectedSoldiersComInt eComint_savant
I don't know the names to set "very poor" and "poor", but I assume noboby would want to modify the soldiers in order to make them dumb ;)
These commands seem to work. I would suggest setting all soldiers as "savant" would be cheating.
I have not seen what happens when combat intelligence is increased through the game after resetting it, but I don't see why it should cause problems.