The UberFix is a compilation of bug fixes for Demigod version 1.3.OFFICAL DEMIGOD PATCH NOTE:Demigod must be updated to version 1.3 or higher to take advantage of several of the fixes contained herein. Additionally, any bugfixes found in Demigod Patch 1.3 have been dropped from the UberFix code for purposes of maximum compatibility with version 1.3, so using an older version of Demigod with this release of the UberFix will re-introduce many bugs.
To insure that the latest Demigod patch is installed, enter the Multiplayer screen in the main menu, choose Internet, and log in with your Impulse username and password. The game will be automatically patched.
Download v1.06:
http://www.box.com/s/hdsoycixo3p8f5fs82aj
Installation Instructions for Demigod Mods in Archive Format:If you have downloaded the executable, it should place the files automatically.If you downloaded the zipped version, use the following instructions:1) Locate your Demigod mod directory. This will be \bindata\mods, within your Demigod install folder. The default location for this is C:\Program Files\Stardock Games\Demigod\bindata\mods.2) Extract the mod archive directly into this folder. If you are using a program like Winrar or 7zip to extract the archive via a drag action, make sure you choose the first option to extract files directly into the mods folder, rather than the second option to extract into a sub-folder with the same name as the archive file.3) The result should be a folder within \mods called e.g. 'UberFix 1.05', containing several files and sub-folders. If instead you see only one folder with the same name as the archive (e.g. 'Uberfix105') and an 'UberFix 1.05' folder within, then you chose the wrong option when extracting, and will need to move that sub-folder back one level into the mods folder, or delete the result and re-extract the archive into \mods without specifying a sub-folder.To enable the mod, run Demigod, select the Mod Manager, select the UberFix, and click enable. If the mod is properly enabled it will show up in the right pane of the Mod Manager screen.To delete a mod, simply delete the that mod's individual folder in \bindata\mods\. Do not delete \bindata\mods unless you wish to remove all mods!
New in v1.06:
-Created new UID-Fixed code error in Regulus' Vengeance skill, now properly does a metahit-Fixed code error introduced with previous Iron Walkers fix-Fixed Theurgist's Hat description, it is a weapon proc, not an armor proc
Version History
v1.05
Minion and Reinforcement Base Armor Not Applied Until Armor Is BuffedUnits with a blueprint base armor value (most idol summons and heavy reinforcement units) will now correctly have this armor value applied. Previously, this value only took effect once the unit was affected by some other armor buff, remaining if that armor buff was removed.
Regulus Maims Allies When Using Universal GadgetThe previous fix for Regulus' self-maiming already solved the unreported issue of self-maiming via potion use. The fix has been expanded to insure against any maim application on negative damage (healing) as well as on allied or self damage.
All Valor Flag Bonuses Lost When Enemy Valor Flag Is Captured And LostThis was accidentally introduced in the 1.04 release with the ArmyBonus stacking protection fix. This fix now always allows stacking unless the buffs the ArmyBonus contains have the REPLACE stacking flag.
Miscellaneous Small Fixes
Gloves of Despair now show their existing 8% attack bonus
v1.04
Ranged Demigod Attack StutterRanged Demigods (other than Regulus in Angelic Fury) would have their attacks repeatedly interrupted due to constant stop and start while chasing a slower target, effectively penalizing greater speed. They are now able to successfully attack periodically in this situation, though not from a standstill. This is intended, to preserve the advantage bestowed by Regulus' Angelic Fury lock-on bonus.Queen of Thorns Extreme Rate of FireRelated to the above fix, Queen of Thorns will no longer be able to attack far more rapidly than should be possible while chasing a target or when stuck on map geometry.Queen of Thorns Compost Uses Incorrect Buff Levels And Adds Infinite ArmyBonusesDespite using a similar buff counting method to Oak's Soul Power, Compost started at 'rank 0' internally and caused the level 6 buff to go unused regardless of skill rank and compost level. It now uses exactly the same calculation method as Soul Power.Additionally, it would add an ArmyBonus every time it gained or lost a level, potentially causing the game to process hundreds or even thousands of ArmyBonuses and their associated buff add/removes every time one of Queen of Thorns' minions was summoned or killed. All buffs and ArmyBonuses added by Compost are now correctly removed, which should significantly reduce the sim overhead of this ability. Unclean Beast Ooze SuicideOoze is now completely incapable of causing suicides. Unclean Beast will be left with one hitpoint in any situation where Ooze damage occurs in the same tick (but just after) any other damage event.Rook Shoulder Weapon Stuck And Illegal TargetsThese weapon addons should no longer become fixated on a single target that is out of range or is no longer visible, and should be unable to fire on non-structure targets that are not currently visible. Structures in the fog of war can still be attacked as intended.Rook AI Movement StutterThis was caused by the high rate of fire of Rook's arrow towers. Their ROF has been quartered and damage quadrupled, for the same overall DPS. Poison chance and duration have been increased slightly to give the same chance per second of poison activation, as well as the same chance per poison cycle of renewal under consistent fire.Torch Bearer Permafrost I DebuffThis aura level is now in-line with all other levels, at -5% ROF from -3%.Torch Bearer Frost Nova Slow DurationThe snare duration for this ability now takes into account the duration of its freeze, each level providing a full 5 seconds of slow post-unfreeze as the description indicates (instead of as little as 2s at level III).Oculus Ball Lightning Produce Nightwalkers/Spirits On DeathDue to the disposable nature of Ball Lightning (particularly with Explosive End), this caused an extremely exploitable level of synergy with Oak and Erebus allies, and can safely be inferred as unintended and a consequence of Oculus' poor testing.Oculus Blast Off! I RadiusThis ability level is now in-line with all other levels, at 6 radius from 3.Sedna Horn of the Yeti IV BuffSedna's Yetis will now correctly receive the level IV buff with this ability. Existing Yetis now also receive the appropriate level of buff upon ability upgrade, as was the case with Shamblers and Entourage.Absorption Refresh On Addition/RemovalShield buffs such as Bramble Shield and Groffling Warplate will no longer cause all related buffs to be fully recharged any time one is added or removed. Additionally, absorption damage float text is now only displayed for both involved parties (like all other damage float text) and displays the amount of damage done.
Illegal AI Area-Targeted Ability Lock-onThe effect location of area-targeted abilities e.g. Hammer Slam will no longer illegally follow a moving unit whose position the AI chose for a target location.Ability Tooltips Display Unmodified Cooldown Time While Cooling DownThe correct total cooldown time is now always shown in all ability bar tooltips. Skill sheet and inventory tooltip cooldown times remain unmodified, as intended. Map Domination Voice-Over On Loss Of Map Control (Second Attempt)The map domination voice-over now correctly activates on flag capture for the team gaining map control any time they capture a flag above the domination threshold. In addition, the map domination threshold is read from game settings instead of being fixed at 75%. This fix was absent from the released 1.03 code, despite being listed in changelog.
Trebuchet Damage Unaffected By Tower Strength Citadel UpgradeThe tower strength upgrades will now affect both Fort-upgrade Trebuchets and flag-controlled Trebuchets.ROLLOVER DATA ERROR Or No Rollover On Flag MouseoverFlags captured by the enemy team behind the Fog of War should now always display the correct rollover information. This issue was caused by an engine bug related to non-visible unit replacement and could not be directly fixed via Lua. Fortunately, a workaround involving giving the opposing team momentary 1-radius visibility on any captured flag to allow the engine to report the correct flag unit to the rollover system seems to have resolved it in practice.
Miscellaneous Small FixesCosmetic changes (thanks to Lord Orion for finding most of these):
Small functional/internal changes:
Feature AdditionsMod UI texture/icon support has been added:
Any .dds files in your mod folder within /textures/ui/common will have their path relative to the mod folder cached in a table that the UIFile function looks at when assigning most non-background, in-game UI textures. This can be used both for adding and overriding existing textures without having to use relative paths. This (along with the mod-folder doscript hook included) allows you to change the name of your mod folder between versions without having to update any of your code.
For example, the path: /mods/mymod/textures/ui/common/abilities/dgqueenofthorns/newqueenclose.ddsWould override the existing file: /bindata/textures/ui/common/abilities/dgqueenofthorns/newqueenclose.dds
Adding a new file: /mods/mymod/textures/ui/common/abilities/mymod/myicon_01.ddsWould let you assign this icon to a buff or ability the same as you would an existing icon in that relative path, by setting its blueprint's Icon field to: 'mymod/myicon_01'
This affects any UI texture calls that use UIUtils.UIFile, including buff and ability icons, shop tab icons, and many UI window elements.As UIFile only returns paths within /textures/ui/common, it does not affect any files outside of that path, and there are quite a few files within that path that do not use UIFile. Expanding this support to all of these files would require hooking every UI creation function that ignores UIFile and directly assigns a texture path, which would unfortunately involve 30+ file hooks and upwards of a hundred destructive function overrides (as most texture path variables are declared local within a function).
Several new BuffAffects have been added for use by mods:
Additional Sync variables for displaying unit information in the UI have also been created, in addition to those from 1.03 (note that some of the associated buffs are currently unused in stock Demigod):New BuffAffects:
Existing BuffAffects:
Weapon BuffAffects:
Note: The secondary weapon stats and associated UI hooks from 1.03 have been removed, and replaced by an entirely sim-side system where each Demigod tracks the stats for all of its main weapons and updates the primary weapon sync variables any time its weapon/mode is changed.
Several other internal changes and additions have been made to facilitate easier and more non-destructive modding of BuffAffects. See the comments in /hook/lua/sim/BuffAffects.lua for details.
v1.03
Knockback Kill/Damage Credit (Ptarth)Creeps killed by knockback damage (e.g. Post-Mortem, Ring of Divine Might, etc) now correctly give a share of credit for their death to the instigating demigod, as well as contribute toward that demigod's cumulative damage statistics.
Lord Erebus Poisoned Blood (Ptarth & Mithy)Updated so that the correct audio cue and visual effects are now played when Erebus or his allies are healed by his poisoned potions.
Instant-Cast Item Activation (Ptarth & Mithy)The fix for Sludge Slinger and Parasite Egg not activating unless the activating demigod was facing its target (present in 1.02) was not taking effect due to an error in implementation. This fix is now fully functional, and is also now applied to Deathbringer's silence ability.Ironwalkers and Desperate Boots Persistent Buff (Mithy)The conditional buffs for these items are now properly rescinded when the item is removed from inventory by any means.Ironwalkers Always-On for Rook (Mithy)The item's speed condition now compares against a percent (90%) of the demigod's base speed, for a similar activation threshold (<= 5.4, from 5.5) for most demigods.Late Map Control Voice-Over (Mithy)The map control voice-over now correctly activates any time the dominating team captures a flag with over 75% map control, rather than when a flag is lost above 75%.Oak Raise Dead Ward Skill Level Crossover (Mithy)All raise dead chances, spirit levels, and spirit caps now conform to the correct skill level of the demigod for whom the spirit is raised, as was already the case with Lord Erebus' Conversion Aura.Gold Loss/Gain On Unsuccessful Item Transaction (Mithy)Item transaction events now insure against gold loss or gain when the item itself cannot be bought or sold, e.g. when dying.Enemy Gold Amounts Visisble In UI Mods (Mithy)Enemy gold values are no longer accessible to the UI. Existing UI mods that previously displayed enemy gold amounts will now only show zero.Modal Demigod Weapon Stats (Mithy)The UI will now correctly show the damage, rate of fire, and DPS calculations for the demigod's currently selected weapon. Without other mods in effect, this only affects Queen of Thorns' packed mode, but the fix will allow the display of asymmetric changes to Torchbearer's weapons as well.Oculus Ball Lightning Auto-Attack/Advance (Mithy)Ball Lightning now correctly attack-move to the location specified by the reticle, instead of ignoring the reticle and only attacking nearby targets.Oculus Ball Lightning Health Bar (Mithy)Ball Lightning now have a normal, fully-visible health bar above their mesh, like every other unit and minion.Oculus Ball Lightning Formation Movement (Mithy)Ball Lightning no longer cause Oculus and other minions selected and commanded with them to move slowly and attempt to join a formation. Ball Lightning will now behave exactly like other minions when given movement commands.Oculus 'Sticky' Chain Lightning and Ball Lightning Effects (Mithy)These lightning attacks should no longer break and create persistent lightning effects attached between the attacker and the former location of the target.AI Citadel Upgrade Purchasing (Mithy)AI are now able to purchase citadel upgrades that do not have a buff with the same name, e.g. Experience. Standard Demigod AI will still not purchase any upgrades unless a mod that enables this (such as the Skirmish AI Mod) is also used.Experience Citadel Upgrade Persistence (Mithy)Experience IV now correctly removes the Experience III bonus when purchased.Feature Additions:Several additional unit stats are now added to the Sync, allowing UI mods to display them for allied Demigods.More details can be found in the comments in BuffAffects.lua. The added stats are as follows:
Previous fixes removed due to inclusion in Demigod Patch 1.3:
Previous fixes left in due to the patch 1.3 solution being insufficient/ineffective:
v1.02
Oculus Sacrifice Fix by PtarthSacrifice now will heal allied units.Unclean Beast Ooze Suicide Fix by PtarthOoze now correctly ends when the Unclean Beast is low on Health.Lord Erebus Poisoned Blood Fix by PtarthPoisoned Blood Potions now act like the potions they disguise themselves as to the team whose Lord Erebus dropped them. This prevents Lord Erebus from farming his death and stops his team from being penalized for his skill choice.Oculus Electrocution Fix by PtarthHealth and Mana regeneration are now correctly stopped when a unit is under the effect of Electrocution.Torch Bearer Projectile slowdown Fix by PtarthTorch Bearer's fireballs and Ice blasts now correctly home in on targets. This includes his Fireball ability.Unclean Beast Post Mortem Plague Conflict Fix by ExxcentricPlague I and II no longer remove the Post Mortem death effect.Rook Move Attack Fix by PtarthRook now is able to move attack properly.
v1.01
Orb of Veiled Storms Fix by Ptarth (bug reported by awuffleablehedgie)The Orb of Veiled Storms now deals ArmorImmune damage like every other demigod ability and weapon ability (except for the Doomspite Grips and Girdle of Giants, which have a cleave attack).Lord Erebus Mist Form by PtarthFixed Mist Form ability so that it correctly ends when Lord Erebus has less than 125 mana.ZikFix (Zikurat Tower Fix) by mrappardThe Dark side towers on Zikurat while playing Conquest now spawn correctly.
v1.0
Minion +hp Fix by PtarthMinions summoned by Demigods Generals [Sedna, Lord Erebus, Oak, Queen of Thorns, Oculus] with +minion hp items now have the correct health.Oculus Brain Storm Fix by PtarthBrain Storm now has a visual effect at all levels, instead of only when Oculus has Mental Agility Brain Storm now removes debuffs on targeted unit as specified by the rollover tooltip text.Queen of Thorns Attack Animation Glitch by PtarthReduced the lifetime of the QoT's root attack animation to make the animation look better. This is only a cosmetic change.Oculus Lightning Ball Summons by PtarthLightning Balls will no longer summon in map void space.Oculus Lightning Blast by PtarthLightning Blast now occurs at the origin of the target instead of the origin of the unit that triggers the effect.Missing Oculus Shield Effect by PtarthOculus now has a visible Shield effect.
Heart of Life and Wings of the Seraphim Healing Fix by Ptarth (awuffleablehedgie provided starter code)The Heart of Life and Wings of Seraphim no longer stop their regeneration effects when the user is healed.
Outstanding Bugs/Issues
Solvable Issues:Modal Demigods spawning in default mode rather than last used modeThis is trivial to implement if there is popular support for it. At this point, I'd consider two or three votes 'popular', so make it known if you'd like this to be changed (or not).
Plague causes massive sim slowdownsThis is fixable, but will require a full re-write of how Plague works and infects units. Some balance changes may need to be made to reduce the check rate and radius of infection, as well as to reduce the overall run time of each Plague infection. This should result in similar overall effectiveness, with slightly less infection but faster damage delivery.Unsolvable Issues:Minion pathing issues / stuck minionsThis is caused by poor handling of the pathfinding map's edges, usually around corners or the citadel. Without the ability to alter these pathing maps (they use a raw image format of some kind), there is nothing that can be done about this.Unreliable multiplayer connectivityThis is contained completely within the engine/Impulse.
Achievements fail to record progress properly As above.
Credits
Ptarth - the original creator of the Uberfix, responsible for most of the fixes prior to 1.03
Mithy/miriyaka - took the reins for 1.03, currently maintaining the project
awuffleablehedgie - bug reports and suggestions
pacov - lots of testing, feedback, and motivation
sounds good - I'll just watch for an updated release then. Thanks.
Re: TB Fire & Ice
I know it is primitive, but why not just create another level of Fireball and Ice Blast with the updated damage. When someone picks the upgrade instead of getting a boost to the spells, they just get the new ranked versions of each.
Re: The Forces of X dominate the map
I kinda liked the idea of reminder the loses that they are in deep trouble when the winners take back another flag.
Trebuchet
As Pacov said, it trebuchets have always shot at things in the fog.
Mod_info.lua Version number
Use a string instead of a float. It doesn't do the display correctly.
Summoned Tower of Light Rollover Text glitch
I'm not sure exactly how to replicate it, however, sometimes when you rollover a ToL summoned by the Rook, it displays the regular ToL description message in addition to "Tower of Light" and the health bar. However, the is overlaid by the health bar of the summoned ToL which is messy looking. Most of the time it doesn't happy. I think it occurs when you previously mouse over another real ToL or something else, and then mouse over a summoned one.
Rook Shoulder Weapon Testing
Look below at the code snippets I was using. I was able to break the targeting using all three methods in play testing. I use the F9 Logger for details and it didn't show a message when there was a lockup. I'm not sure if there is another logger or not. I set the trebuchet to fire every 0.5 seconds and with a range of 50. For the most likely "correct" version of the fix, I don't have a great record of the event. I'm also not completely sure the fix was working. I believe the targeting fixed itself either after sufficient time passed or the demigod it had locked on died. I don't wasn't watching when it did it. I didn't see a log entry for the demigod dying, but I didn't record when the lockup occurred. There was also a citadel upgrade event, a warscore rank 5 event, and some other demigod deaths during the most likely time of the lockup resolution.
Flag ROLLOVER ERROR
It doesn't happen all the time. The last game I played, about 25 minutes in I rolled over a flag in enemy territory under fog of war and got the Rollover error. Moving the cursor back off it and around to other features and then back to the Flag removed the message. I'm not exactly sure how to reproduce it, but figured this might suggest that it is something about the rollover tooltip and window settings stay in memory and being overridden rather than other things. I also have a vague memory of rolling over an enemy flag in fog and it not displaying any message, but I can't confirm this.
Blueprint ID for Trebuchet
I eventually gave up, but apparently it was hrooktrebuchet. My last guess was: HRookTrebuchet_unit. Ah the joys of undocumented engine mechanics.
Trebuchet Blueprint mod in mod_units.bp
I have a question about the lua mod. The following works, but I'm not sure why. Both targeting is fixed and the weapons stats are adjusted.
In contrast, the following doesn't work. The targeting should be fixed, but the weapon stats don't work.
This also doesn't work. The targeting glitches, but stat changes work.
I'm guessing it has something to do with scope and levels, but I don't grok it.
yeah - it doesn't sound overly complicated to me, but what do i know.
This is actually the most complicated fix available, as you would have to do a lot of manual coding for adding and removing 'hidden' abilities, updating ability-bar buttons, and such. Fire and Ice is one passive ability, and there is no way to make it automatically assign two new active abilities to the ability button bar (nevermind to the abilities screen, which would be impossible). This would also break compatibility with any mods that modify either of these three abilities.
Re-writing the ability system to accept both global and ability-specific damage modifiers within a unit's Sync would be far easier than this, and would fix all similar abilities. Like I said, this is on the table, but not something I'm in a hurry to do because of the limited application (i.e. 2-3 abilities that would currently make use of it, and a lack of modders to further exploit it).
The absolute simplest fix would be hooking a small exception into CreateAbilityTooltip that specifically checks for these two ability names, and then checks for the presence of Fire and Ice, but CAT isn't the most hookable function (tons of loops, local vars, etc) and I'd have to re-construct the damage text of the resultant tooltip handle with some redundant code. Either way, this would only affect the Ability Bar tooltip, not the skill sheet tooltip (which specifically and intentionally has no modifications displayed).
It's easy enough to revert that part if there's demand. Anyone else have an opinion on this?
Yeah, I wasn't suggesting that this was new, just that I hadn't noticed it before. It shoots at structures because they're intentionally targetable through FoW, but it's clearly disobeying the rules with mobile targets.
I had noticed this, but it didn't even occur to me that a string would work there. All it's doing is being displayed, so it should work fine. The game doesn't really use the version number comparatively, and even if it did, lua is pretty good about automatic type conversion.
I don't even see this in unsolved issues on the google code site or in my own notes, but I was at one point aware of it. I didn't specifically look for these kinds of problem when reviewing the flag rollover issue, but I know enough about that code that I don't think there's an easy fix for this. I'll take another look, but as far as I know it doesnt 'save' anything between rollover events. The rollover code in general is very odd and problematic, and causes all sorts of false-start display issues (such as displaying Chirmaya's extended rollover format for a few frames on objects that it should not be displayed for, with his code correctly conditionally filtering out such objects).
This is likely related to the ROLLOVER DATA ERROR issue.
No, there is no message displayed on a stuck target except those that I added. Look at lua/shoulderweaponfix.lua in the 1.04 RC1 if you want to see how I'm doing that. It's a touch clumsy, but it's been getting the job done.
As for the fix, and the implementation, I can tell you that weapon stats have to be within the weapon's individual subtable within Weapon = {}, and that AlwaysRecheckTarget should have to be there as well, so I can't imagine why putting it directly into Weapon would do anything, as that would necessarily have to affect all weapons if it did work.
Are you sure your sample size with these changes was large enough? Because often times the unit will behave just fine for dozens of games in a row. I'm really having a hard time believing that AlwaysRecheckTarget outside of a specific weapon table would do anything at all. In fact, I did add a merge with AlwaysRecheckTarget in the base Weapon table to the 1.04 RC1 based on your last post, but I'm still observing the targeting through FoW with that set. I can't recall whether I intentionally left it out of the actual weapon subtable, but I'm going to put it in there next and see if that helps.
I now know with 100% certainty that this is caused by the engine function that gets mouseover data returning the wrong entityid for objects not currently visible. This results in both ROLLOVER DATA ERROR when the wrong-id entity has a different type of Rollover bp section, and no rollover at all when the wrong-id entity doesn't exist or has no Rollover section in its bp. There is no possible lua fix for this engine function, nor is there a way to get the 'real' flag user unit within the UI layer.
I can also confirm that this problem is definitely present mid-game as well as at the beginning, and I know of absolutely no fix for it other than having a flag captured by an enemy team actually display a 1-radius .1 second viz for the opposing team upon capture. I'll toy around with this, and see if it's unobtrusive enough.
Not engine. It's visible right in Blueprints.lua, in SetShortId. It strips the leading path and everything after and including the _, and sets the rest to lowercase. Therefore, HRookTrebuchet_unit.bp becomes 'hrooktrebuchet'.
New issue, albeit extremely minor:
When dead, the red disabled/cooldown overlays on the ability button bar momentarily flash and disrupt tooltip display whenever you hover over a button. This is present in stock Demigod, and isn't caused by the cooldown time fix.
I'll need to research a bit more on what conditions cause the overlay to display, and why it's only happening on mouseover.
Piffle, you've seen some of my "fixes" I can do much more complicated than that.
More seriously, I'll take your word on it, I haven't dusted off my bad Demigod/Lua programming skillset in a while. I thought it would have been a simple mod, create level 6 for fireball and frost blast, add them when you get fire and ice, and remove the previous versions. I know you can add/remove multiple skills when getting a skill, but I can't recall the button assignemtn mechanics. The ability screen wouldn't have been changed, just the roll over of the ability button bar. Anyway, I'll take your word on it.
As for the fix, and the implementation, I can tell you that weapon stats have to be within the weapon's individual subtable within Weapon = {}, and that AlwaysRecheckTarget should have to be there as well, so I can't imagine why putting it directly into Weapon would do anything, as that would necessarily have to affect all weapons if it did work.Are you sure your sample size with these changes was large enough? Because often times the unit will behave just fine for dozens of games in a row. I'm really having a hard time believing that AlwaysRecheckTarget outside of a specific weapon table would do anything at all. In fact, I did add a merge with AlwaysRecheckTarget in the base Weapon table to the 1.04 RC1 based on your last post, but I'm still observing the targeting through FoW with that set. I can't recall whether I intentionally left it out of the actual weapon subtable, but I'm going to put it in there next and see if that helps.
I had based all of my code on your mod_units.bp in 1.04 RC 1. The relevant snippet is:
I only did a single test, and wasn't able to reproduce the lockup behavior. I then used this snippet to add in the additional weapon changes to make the error easier to find (which lead me to the three versions in the previous post). Only one of them seems to work correctly, but I still don't get what was going on. The part where I had to double nest the weapon attribute changes in brackets still doesn't make sense to me. If I didn't do that, then the trebuchet would still use the base stats. As for observing the error, one sample is sufficient if I can find evidence that it broke, which I did. Unless I screwed up the testing methodology, which is possible.
Ah, that would suggest I understood the lua well enough to know that. Which, at the time, I didn't, and even now, not as much.
I never got a firm grasp on the overall structure of the game. I have some of it, but a complete hierarchical representation, nope. That being the case, I don't have a good way to do tracebacks and tracedowns without individually consulting each function and searching for what calls it, or is called by it. As you are well aware, that's a kludgy way to do things.
Ignore the non-plurality of the name: Weapon is a table containing subtables, each one being a separate weapon. Units can have multiple weapons - look at Rook's blueprint. Every unit with a Weapon table, including those with only one weapon, have each individual weapon in an unkeyed subtable.
If you copy-paste e.g. TB's Weapon table with all of the actual weapon blueprint data removed, it looks like this:
Each weapon in its own subtable. If you look at how I'm modifying Rook's poison arrow weapons in the UberFix, I'm including their numerical index as well, which for TB would look like:
This syntax and the preceding syntax are the same thing, but the numerically-specified syntax lets you skip subtables and modify e.g. subtable 2 directly. The only way to do that with the first syntax in a merge is to pad the preceding weapon subtable indexes with empty tables.
Therefore, my merge that had AlwaysRecheckTarget = true outside of a weapon subtable was an error, and wasn't doing anything (nor should it).
If it still broke with AlwaysRecheckTarget = true within a weapon subtable, then it's likely that value does nothing related to this problem, and a manual fix similar to what I have in /lua/shoulderweaponfix.lua is in fact necessary. I just haven't had the issue crop up in my testing so far, although the similar issue of units behind FoW being targeted is obviously showing up often.
I just don't know enough about the new weapon target system in Demigod to understand how to better control or limit it. I believe SC2 uses the same system, but with refinements, including much greater target check fidelity. Add that to the fact that I know little or nothing about the game's unit attack manager, which is coming into play with these attached shoulder units, and the only way I know to fix a problem like this is brute force checking in the script.
I'd love for there to be a way to use the attack manager to limit what these shoulder units can target, but there is no documented way to do that, and I suspect that the attack manager has no allowances for dependently-mobile units, and is treating these attached units as though they're actually able to pursue a target (as obviously stationary structures do not suffer from these issues). The fix could be something as simple as adding a category here, or a flag there, but without more documentation, I'm working blind.
I've been playing around with the engine for a little over a year and a half now, and really that's the only way I've learned how everything works. I did some tracing from the top down, but the lua is so massive (~20mb of raw text, closer to ~60mb in FA) that top-down isn't actually much more helpful or realistic than bottom-up, unless you're also following a specific path. I doubt any one of the engine's original lua authors really had that much of the game's specific structure memorized; there's just too much of it.
There's a ton about the lua structure that I still don't know, particularly with the UI (which is a horrible interdependent mess), but after up- and down- tracing for hundreds of problems, you eventually get a handle on where to look for what, and it makes confronting a new problem and finding exactly what you need a lot easier, even when you don't necessarily know just what you need offhand.
If you get a chance, pop out another RC for 1.04. I'd love to use a final version for our next practice tourney (its in a little over 3 weeks).
As always, happy to test. Thanks
I did a little testing tonight, but I still need some more time to look over a few things. Like I said, I'm pretty confident in everything but the rook shoulder weapon fix, and the stuff I haven't been able to fix at all (like the rollover bugs).
Definitely not going to tackle the Fire and Ice thing right now, because I don't particularly like any of the quick solutions (most of them would break mod compatibility or require overwriting UI and/or ability functions) and it's just not a serious problem.
Not sure what's going on with the overlay-pop-on-hover-while-dead with the ability button bar. It's only mildly annoying, and I can't really find the cause, so unless someone else can shed some light on it, it'll probably just take a lot of re-examining the code and logging like the cooldown fix did.
Agreed. It's not really a bug, per se, anyway, but the change would make clear the damage amts (which is appropriate, imo). Anyway, clearly more of an "if I feel like it" project instead of something all that critical.
Anyway, toss up a release when you like and I'll test it out. Thanks!
wouldnt the easiest fix for fire and ice be to update the tooltip of top lvl fireball to have a disclaimer on the bottom:
Does 1100 damage. Upon obtaining fire and ice this ability will do 1350 damage.
(not sure of numbers but you get what i mean)
That could work, but would break localization of the tooltip (it would always be in english). Probably not a huge issue, so if enough people want it changed, I'll do that.
Although, I have a feeling that anyone who would care enough to post here in support of this would already know the effect of the upgrade well enough to not care whether or not it displays in the tooltip.
Had another think about this:
pretty sure fire and ice is a passive (--> quiet)
why not just add a dummy buff that gives the player an icon with the disclaimer in in (ie adds the fire an ice buff icon to the buff bar and gives info there).
simple fix, better than changing the original tooltip and gives the player a visual representation of what is going on.
There's no real drawback to that, I guess. Do normal-sized ability icons work as buff icons?
Also, I think I've fixed the ROLLOVER DATA ERROR thing. Flags now give an imperceptible 0.1s 1 radius viz to the enemy team upon being captured. You can't even see it, but it seems to be enough to make GetRolloverInfo() return the entityid for the correct unit. Of course, only time will tell if this is an absolute fix, but the reasoning is sound (fog of war is essentially taken out of the flag-transition equation).
Added a check to the shoulder weapon fix that prevents them from firing at a non-structure target behind FoW, resets the weapon's target, and resets its firing clock (so it can immediately attempt to fire again). It does a console print and log message just like the stuck target.
I played two quick games with a few Rooks, and did not get any console prints for either issue, which is not terribly surprising. Console prints now list the player name, weapon type, and any reason for stuck/illegal targeting, and target blueprintid (if possible) so it should be more clear in a multi-rook game which player is experiencing the issue and thus easier to associate to an event either while playing or in a replay.
Also reverted half of the flag domination message change, so it plays any time a flag is captured by the dominating team, even past the threshold.
Also, with all this Rook playing, I've remembered just how completely obnoxious the seeking-AI-hammerslam bug is. I'm pretty sure I know what's causing it too: unit:GetPosition() returns a table of the unit's x,y,z coords. This table is updated in realtime. Most of GPG's functions are careful to make a copy of this table at the time of execution, but I'm betting that somewhere in the AI ability code, there's a direct insert of this table that's allowing the ability to essentially lock on to the position of its target no matter where the target moves.
Well, that was easy - found it in /lua/sim/AI/AIAbilityUtilities.lua, UseTargetedAbility. Sure enough, it passes it the position straight up instead of using a copy. Consider this squashed.
I'm going to go ahead and drop another release candidate, because I've added a pretty significant number of new stuff in the last two days. It's been running fine for a few games with no log errors, so it should be good enough to get feedback on.
http://code.google.com/p/uberfix/downloads/detail?name=UberFix 1.04 RC2.zip
New fixes from the last version:
- Cooldown fix works while dead- Shoulder weapon viz fix (both blueprint and script)- Area-target ability AI lock-on fix- Flag rollover fix (third attempt)- Flag domination message always triggers >=75%
Don't feel like you have to specifically test most of these, as I'm 99.99% sure that they work, but do please play a few normal games (multiplayer if possible) with logging enabled and at least one Rook, and pastebin the logs if any console prints appear, so I can sort through them.
Also make note of enemy-captured flags whenever possible, to make sure they're getting a (non-error) rollover. I can't get this particular issue in the log reliably, since 9 times out of 10 it produces no event and no rollover.
Stuff I should still work on:
- Ability cooldown overlay pop/flicker when dead (not related to cooldown fix)- Some sort of token thing for Fire and Ice, since it's such a hot-button issue (loool pun)- Continued perusal of rollover code to better understand the 'stickiness' and general unreliability of rollover info. I understand how it works for the most part, but I am not sure why it has any data persistence whatsoever.- Figure out something with CAiTarget or CAttackManager methods to solve the shoulder weapon issue more gracefully (probably never going to happen barring the release of the game's source code or some serious internal docs)
Any further input on these or any other issues that I may have forgotten (I haven't touched the issue tracking site for a week or so, whoops) is welcome.
"There's no real drawback to that, I guess. Do normal-sized ability icons work as buff icons?"
yes just use the same icon as the ability as the icon for the buff and it will work fine
Good stuff!
Righto - never hurts to have a 2nd pair of eyes though.
should i disable uberfix 1.3 when im using 1.4 RC ?
yes - but keep in mind that uberfix 1.4RC2 is just a test candidate. Unless you are planning to test the fixes, you do not want to use this version.
Also, see the demigod mod thread and answer my questions if you get a chance.
what questions would those be?
link maybe?
till i search and find by my self
1.04 versions should have 1.03 in the conflict list anyway, so it shouldn't be possible to have both enabled at once.
Issue: Trebuchet shooting into the fog of war
Intended? I don't know.
Bug? I don't know.
Does it happen that often? Not really.
Is it a balance change? Maybe?
Is it necessary to reduce lock on issues with the Rook? I'm not sure. I still haven't gotten around to understanding Miriyaka's code.
Issue: UB spit's DOT is dodgeable
Probably an oversight. Trivial, sure. But I'm pretty sure it wasn't intended.
No, there is no blueprint/script setting that causes it to happen, and it only happens with these two units due to their attached-but-mobile status. Shooting at non-viz structures is definitely intended, and still allowed.
Yes, as above
In some games, constantly, in others, never
Only in the sense that being shot at by a demigod who cannot see you from 50+ units away is a balance issue (so yes, but a only a minor and non-exploitable fairness issue). It can still shoot at non-viz structures, which is intended, so that aspect of balance is unchanged.
Yes and no - it is a form of lock-on, and is caused by the same CAiTarget/CAttackManager issues that cause lock-on, but because it keeps shooting at this non-visible target, my lock-on fix in its base form didn't pick up on it (since the fix only triggers on failure to fire within 2-3x ROF).
I agree, but people are currently championing this as a 'valid reason to take evasion', and UB isn't exactly underpowered. I would like to change this, but I'm not sure what the reception would be.
after spending quite a bit of time with abilities, this would NOT be an oversight as all other abilities are set to not be evadable and so would have to be specifically programed to be different.
BuffAffects.lua, line 82 from the Health affect:
Evasion is on by default. This, I would say, is the oversight, as -health buffs are universally used for ability damage. All other abilities specify CanBeEvaded = false, and the Spit buffs have no specification one way or another.
If I fixed this, I wouldn't touch the Spit buffs themselves, and would just set CanBeEvaded = false, in the Health buffaffect (which I'm already having to override anyway).
If there's any doubt about the intent behind this, and whether or not health buffs do 'ability' type damage, their default DamageType is 'Spell', and the default ArmorImmune setting is true, while CanDamageReturn is false.
There are many great features available to you once you register, including:
Sign in or Create Account