Jump to content

Kvalyr

Premium Member
  • Posts

    52
  • Joined

  • Last visited

Nexus Mods Profile

About Kvalyr

Profile Fields

  • Country
    Ireland

Kvalyr's Achievements

Contributor

Contributor (5/14)

  • First Post
  • Collaborator Rare
  • Conversation Starter
  • Week One Done
  • One Month Later

Recent Badges

0

Reputation

  1. Edit: ----It turns out that opting into the 'full_content' beta on Steam for the WOTC SDK solves this problem in a simpler way. Still seems like a waste of space compared to the symlink approach.---- Posting this here because this was annoying the hell out of me this weekend. The steam installation of the WoTC Dev Tools is a little strange for a number of reasons. Firstly, Steam thinks it takes up ~60GB of space but the actual download is only about 1GB of files (new version of ModBuddy, WotC-specific assets and UDK stuff). This would make sense from a perspective of the WotC SDK re-using data from the normal SDK, but it doesn't. This means when you load the XCOM 2 Editor from the WotC ModBuddy, it only shows you WotC assets in the asset browser. This makes it a pain to modify non-WotC game content or to update mods for WotC that involve modifying vanilla content. To fix this, you need to copy all data from "XCOM 2 SDK\XcomGame\Content" to "XCOM 2 War of the Chosen SDK\XComGame\Content" (without overwriting) so that the WOTC editor can actually access non-WOTC assets.Alternatively, instead of copying all that data and wasting space, set up symbolic links to the vanilla assets in the WOTC SDK's XComGame dir instead.
  2. Already done: http://forums.nexusmods.com/index.php?/topic/3806305-psa-where-to-find-the-definitions-of-firaxis-unrealscript-macros/&do=findComment&comment=34608675 Those backticked-names are just UnrealScript macros. Shorthands for longwinded, verbose things you don't want to have to write often, which covers a lot of things in UnrealScript..
  3. Something roughly like this: local XComGameState_Unit Unit; local TSoldier Soldier; // Disposable var // TODO HERE: Fetch Unit. stpre in Unit var. Soldier.kAppearance = Unit.kAppearance; Soldier.kAppearance.nmTeeth = 'DefaultTeeth'; Unit.SetTAppearance(Soldier.kAppearance);
  4. Interesting idea. Teeth get specified in XComGameState_Unit.kAppearance.nmTeeth: BodyPartTemplate = PartManager.FindUberTemplate("Teeth", kAppearance.nmTeeth); ArchetypesToLoad.AddItem(BodyPartTemplate.ArchetypeName); kAppearance is a TAppearance var on the unit class. My experience so far with UE3 seems to suggest that you can't override meshes/textures/archetypes directly by just adding something of the same name to the game assets. I wish you could. Instead, I would guess you'll have to change the nmTeeth property on a soldier (or the template the soldier is created from) to point to your new teeth ArcheType.
  5. Kvalyr

    FAILED!

    This is a little melodramatic.. ModBuddy compilation failures have never been due to bugs in my experience - More likely it's a script error or ModBuddy is trying to access a file that's locked as in-use by another application (such as the game or editor). ModBuddy has UI glitches, but I doubt this is due to one of those. Try doing Build->Clean Solution to clear out cached intermediate files; and as the others have said, make sure to change the output to detailed/verbose. Tools->Options ->Projects and Solutions -> Build and Run -> Set "MSBuild project build output verbosity" and "MSBuild project build log file verbosity" both to 'detailed' or higher.
  6. This is pretty much my wishlist right now. Delighted to see this kind of support from you guys - Thanks so much! Class Replacement System Logging: One thing I would love is if we could get some verbose logging from the class replacement system. Right now it's a total black box to modders and we don't really know whether our overrides are working or not except through intensive trial and error (and starting the game up and sitting through loading screens etc. multiple times). This is especially problematic when considering conflicts between multiple mods vying for the same classes to override and so on. Pre-/Post-Hooking (or Wrapping) of Functions instead of full class replacements Would it be possible to expand the functionality of the class replacement system to add a means of pre- and post-hooking functions on instantiated objects (or static methods) as an alternative to full-blown class replacements? This would also serve us well in places where Events aren't a good fit. Example: hooking the return of XcomGameState_Unit:IsPsiOperative() -- Currently that method is hardcoded to return true if the unit's class template name == 'PsiOperative', and because it's buried in a gamestate class, mods can't really change that - So mods can't properly add additional psi classes. There are better approaches to fixing this that would be preferable (such as checking if the unit's class template name is in an array of psi classes, ini-configurable) - but for the sake of example, it would also be awesome if we could modify the return value of that method by ANDing it with the return of a post-hook function. ModBuddy QoL issues: + As a minor Quality of Life thing - Could we also get the game to remember the size and screen position of the debugging console between sessions? Moving the log output over to my 2nd monitor and resizing it to be legible every time I start the game in debug mode gets really irksome when something's not working right! It's a minor thing, but it would be really pleasant. + ModBuddy is very unstable when it comes to project file management. The SDK just errors out and throws exceptions 9 times out of 10 when trying to rename or delete files, or even adding existing files. This leads to ModBuddy getting into a weird state where the SDK UI is out of sync with the actual contents of the solution, and it even starts to display increasing numbers of duplicate files (pointing to the same file) if the solution isn't just reloaded fully. At this point I've developed a habit of manually editing the XML of the project file when I want to delete or rename a file!
  7. Yeah you'll need to zip the folder up first: http://www.howtogeek.com/178146/htg-explains-everything-you-need-to-know-about-zipped-files/
  8. I think what Azworai is asking is which folder of the mod on his/her local machine should be uploaded. When you build your mod in the SDK it outputs a fresh copy of it to XcomGame\mods\[mod name] folder, so you can use that one. Alternatively, subscribe to your own mod and use the folder steam creates in the workshop folder when it downloads your mod.
  9. I wish. I've been trying to bypass unreliable ModOverrides by downcasting existing objects (such as Units or UIScreens) to my own subclasses of their class; but sadly that doesn't appear to be possible in UnrealScript. Objects can be cast to parent classes of their class, but not to subclasses. Trying to cast to a subclass silently fails and returns None. I had hoped that I'd be able to do things like replacing every XComGameState_Unit with a custom subclass with overriden methods instead, for instace; but alas no. Not without doing funky things like silently firing/hiring soldiers (which actually just crashed the game, too). Fun. As to your earlier questions about difficulty-variants of templates at the main menu, Amineri already confirmed what I've said about it (i.e.: It doesn't work): http://forums.nexusmods.com/index.php?/topic/3798185-added-a-new-gamestate-object-to-all-soldiers/?p=34716670 http://forums.nexusmods.com/index.php?/topic/3798185-added-a-new-gamestate-object-to-all-soldiers/?p=34717290 I think your best bet is to just accept that it can't be done at the main menu and just handle it with a loop and temporary difficulty-change at the AvengerHUD OnInit. If you do it right, there's no reason to think that it will affect a players' achievements or difficulty state etc.
  10. All 'work projects' in the XCom HQ uses the same underlying system of points-to-completion. Item templates have a value for points-to-complete. Even soldier healing is implemented as a work project with points-per-block-of-health. I'm not certain exactly how many points per hour are generated; but I'm sure it can be found by looking in the scripts for the work project stuff.
  11. For sure. I wasn't worried so much about cheat mods but rather mods that were using this technique to adjust difficulty templates without saving and restoring the lowest difficulty setting. People would be understandably upset to discover their achievement didn't unlock because of a mod that doesn't really drastically impact gameplay. Definitely - And that's a distinct possibility. Worse still is the potential for someone to do it out of malice!
  12. Not irritating at all, I wouldn't be answering if I didn't want to. :) My previous-to-current job was as a University Lecturer in CS so I got used to answering questions on programming problems. ;)
  13. /** * @return the template in the GameDataCache that matches the provided name. * Child classes should implement a public wrapper that returns the class appropriate to the manager. */ protected native function X2DataTemplate FindDataTemplate(name DataName) const; If you look closely you'll see that FindDataTemplate() is defined with the keyword 'native', which means that line is just exposing access in UnrealScript to a function implemented in C++ in the game's executable. They typically do that for stuff that needs to execute fast. According to Epic, UnrealScript is approximately 20x slower than native C++ code in typical use - So you can see why Firaxis would want to do that for iterator functions. Regarding your 2nd paragraph, I already covered that stuff back on page 3 of this thread, here: http://forums.nexusmods.com/index.php?/topic/3805750-mod-help-conditional-blademaster/?p=34649260 :)
  14. But... But X2DataTemplate doesn't say it inherits X2DataSet :smile: Thank you kindly, I'll review X2DataSet as soon as I can. What mislead me is the X2DataTemplate class definitions, though: class X2DataTemplate extends Object Again, this is very likely me just not understanding UnrealScript, but when I see something which extends Object and doesn't list any other extensions, I scratch my head. Regardless, thanks for the advise. X2DataSet should hold the answers I need, hopefully. Apologies for being dense :smile: My bad, you're totally right. X2DataTemplates are used by X2DataSet - They don't extend it. X2DataSet is the class that picks up the templates in response to an event fired somewhere in the game's native code.
  15. Take a look at X2DataSet.uc, the class from which X2DataTemplate inherits. You need to follow the white rabbit deeper. :) Relevant excerpts from X2DataSet.uc: /// <summary> /// Native accessor for CreateTemplates. Used by the engine object and template manager /// to automatically pick up new templates. /// </summary> static event array<X2DataTemplate> CreateTemplatesEvent() { // Snip if( CurrentBaseTemplate.bShouldCreateDifficultyVariants ) { CreateDifficultyVariantsForTemplate(CurrentBaseTemplate, NewTemplates); } else { NewTemplates.AddItem(CurrentBaseTemplate); } // Snip } /// <summary> /// Helper function to construct Difficulty variants for each difficulty. /// </summary> static function CreateDifficultyVariantsForTemplate(X2DataTemplate BaseTemplate, out array<X2DataTemplate> NewTemplates) { local int DifficultyIndex; local X2DataTemplate NewTemplate; local string NewTemplateName; for( DifficultyIndex = `MIN_DIFFICULTY_INDEX; DifficultyIndex <= `MAX_DIFFICULTY_INDEX; ++DifficultyIndex ) { NewTemplateName = BaseTemplate.DataName $ "_Diff_" $ DifficultyIndex; NewTemplate = new(None, NewTemplateName) BaseTemplate.Class (BaseTemplate); NewTemplate.SetDifficulty(DifficultyIndex); NewTemplates.AddItem(NewTemplate); } }
×
×
  • Create New...