Jump to content

Mike1072

Gibberling Poobah
  • Posts

    3,186
  • Joined

Posts posted by Mike1072

  1. No, WeiDU doesn't have a general way to do that.

     

    The closest regexp approximation of "match anything except abc" that is supported in WeiDU is:

    ([^a].*|a[^b].*|ab[^c].*)

    For readability, I left out the backslashes that are required in front of the round brackets and pipes.  This regexp matches a string that either:

    1. Doesn't start with the letter a
    2. Does start with the letter a but continues with a character other than b, or
    3. Does start with the sequence ab but continues with a character other than c

    It's a very awkward way to deal with this and it gets worse when you are avoiding a sequence longer than abc. It only disallows the forbidden sequence in one particular place in the string and it doesn't combine well with other regexp constructs, which means there are situations where it won't do the trick.

     

    If it's not possible to do what you want in one regular expression, consider your other options.  Depending on which part of WeiDU you're dealing with, you might have the ability to query the data (STRING_CONTAINS_REGEXP) or manipulate it (REPLACE_TEXTUALLY) beforehand.  Sometimes two or three regexps are better than one.

  2. It wasn't me, but Demi was fond of incorporating descriptions and ideas from 3.5.

    I'll replace the reference to darkvision with infravision.

  3. Hey, just a heads up, a recent update of the forum software brought a lot of unexpected changes and I haven't had time to go through all the settings yet & update the theme to play nice.

    One thing I found was that clicking on a topic annoyingly started bringing me to the first post rather than the first unread post like it used to.  It turns out this is a user setting which you can change by clicking your avatar and going to account settings:

    QGwBipd.png

  4. 1 hour ago, Bartimaeus said:

    ...Side note: what is the intended difference of a "tph" vs. a "tpa"?

    1 hour ago, subtledoctor said:

    Nothing, as far as I know.  I think it's  totally arbitrary - you can use .tpx, .tpr, heck I'm pretty sure you can put a bunch of code in "macros.txt" and INCLUDE it, and it will work just as well as .tpa or .tph.  In several mods I have Weidu code in a file with an .ini extension, and it runs just fine when INCLUDEd.

    There is no practical difference.

    There seemed to perhaps be a convention to use the .tpa extension when the file contains actions and the .tpp extension when the file contains patches.  That way, you'd know whether to use INCLUDE or PATCH_INCLUDE for the file.  But I'm not sure how the .tph extension fits in.

  5. IR does some pretty complicated description patching.  It covers different languages and handles inconsistencies in formats from mod-added items.  It's not rewriting anything to a specific standard (which would be next-to-impossible to automate); it's replacing particular parts of lines or adding new lines.  My recommendation to avoid it where possible is based around the experience of doing it.

    However, if you enjoy dealing with stuff like ~\(Not[ %tab%]+\|Un\)[Uu]sable[ %tab%]+[Bb]y[ %tab%]*:~, then dive right in.

  6. 1 hour ago, Bartimaeus said:
    
    COPY_EXISTING ~brac23.itm~             ~override~
      SAY IDENTIFIED_DESC @1308

    If you're just updating spell names, you could do that pretty easily by patching the descriptions using the update_item_descriptions macro from IR and this simple macro:

    DPM ~replace_spell_name~ BEGIN
      REPLACE_TEXTUALLY CASE_SENSITIVE ~%old_spell_name%~ ~%new_spell_name%~
    END

    And then you could call it like:

    COPY_EXISTING ~brac23.itm~ ~override~
      SPRINT old_spell_name @99175 // ~Righteous Magic~
      SPRINT new_spell_name @175 // ~Righteous Fury~
      TEXT_SPRINT text_update ~replace_spell_name~
      LPM ~update_item_descriptions~

    This would mean less maintenance if the description ever changes in the future and better compatibility in the case where SR is being installed after something else that alters the item's description (like one of IR's other components).

    1 hour ago, Bartimaeus said:

    One thing I don't know how to fix yet is re-stringing item extended headers outside of the framework of IR, though - so for example, Anomen's shield will say "Protection from Normal Missiles" when you mouse over the ability instead of the actual cast spell, which is "Protection from Missiles".

    You would have to update the values in tooltip.2da - there are macros/functions to make this very simple, including one in IR.

  7. 1 hour ago, Bartimaeus said:

    And on that note, I have completed the transition of installing IR first and then SR second in the last github repository. I will be doing a full release with a proper version number increment for both IRR and SRR once I have finalized compatibility between these two and 1pp as well, with fuller instructions to follow.

    Nice.

    1 hour ago, Bartimaeus said:

    4. The rest of SR after any other spell-adding components that aren't SCS and CDTweaks (i.e. all the other components should always be before SCS and CDTweaks).

    And also after any mods that add joinable NPCs (because of SR's Update Spellbooks component).

  8. Traditionally, there was no required install order between IR and SR's main components.  However, we recommended a very early install position for IR's main component, while SR's main component didn't have the same requirement.  I generally installed both main components early, with IR before SR.  Even though we didn't initially recommend a preference for which to install first, we learned later that it would be handy to define a preferred order, because then we could implement compatibility code in just one place.

  9. 40 minutes ago, DavidW said:

    That would be nice, actually. I have some time for this objection: if someone comes to G3 and looks for Spell Revisions  (or just looks around under the various mod lists and comes across Spell Revisions), the main website will point them to SR v3.1.03 and will give no indication that there is a later version. Even if they check the forums (and they might well not) they'll come across the fact that there's a 'v4 beta 18', but they could pretty reasonably conclude that they should stay with the stable v3 rather than the clearly-under-development v4 beta. (When I started updating SCS a couple of years ago, I assumed that I should be working with SRv3 as the last stable release given that was what the main site pointed to and given the way v4 is named - it took me a bit of time to work out otherwise, and I'm scarcely new to or uninformed about modding.)

    Fine, I've updated the mod page and download page.  The mod is still exactly the same, it's still a beta, this is not a "definitive" version, yada yada yada.

  10. I remember being concerned about confusion regarding "+2 to THAC0" or "-1 THAC0" when I was editing descriptions a long time ago... probably for Spell Revisions.  I think our solution was to add "bonus" or "penalty" if it wasn't there already so players would know if it was good or bad.

    I think the BG games lean so heavily on the THAC0 labelling that it's probably better to stick with that.  I find "attack roll bonus" to be a fairly understandable alternative.  I'm not a fan of "to-hit bonus" since it's awkward (even if it's the logical contraction of THAC0) and I think "attack bonus" might invite confusion with damage bonuses.

    5 hours ago, subtledoctor said:

    For some reason, the people who deride THAC0 as “weird” seem to have no problem with saving throws, which are exactly the same - target numbers that a d20 roll must meet or beat. I suppose we routinely talk about “+2 bonus to saves vs. spells,” which is the same kind of incorrect-but-effective shorthand as saying “THAC0 bonus.”

    Why do we "roll" attacks, but "throw" saves?  Variety is the spice of life?

  11. 8 hours ago, Kilivitz said:

    Hi Guest Ront!

    Not yet, unfortunately. Life and an ever-growing disappointment at the EEs got in the way.

    I have to say, though, that every time someone asks about it, I get an itch to restart the project.

    The BG1 GUI is my favourite.  Just saying.

  12. I can paste some of the notes I made when I took a look at it previously.  This is basically what the code does:

    On 2/12/2015 at 3:48 PM, Mike1072 said:

    The important parts to look at are the changes to the various resources:

    • For all .itm/.spl abilities and .eff files that contain effect 58 ("Dispel Magic")
      • Change the behaviour of magical weapon dispelling to use the new algorithm with corrected dispel chance (unless the effect is set to "always dispel")
      • Delete all instances of effect 112 ("Remove Item") from the ability
    • For all resources (.itm/.spl/.eff) that contain effect 111 ("Create Magical Weapon")
      • Record the name of the .itm file referenced in the resource parameter
    • For all recorded items that can be created by effect 111 ("Create Magical Weapon")
      • Give them immunity to dispelling
    • For a customized whitelist of magical weapons created by spells (e.g. Energy Blades, Black Blade of Disaster, Phantom Blade, Melf's Minute Meteors, Sol's Searing Orb, etc.)
      • Remove the immunity to dispelling

    This means all the items created by effect 111 that are not on the whitelist will be immune to dispelling, and all the ones that are on the whitelist will be subject to dispelling using the corrected dispel algorithm. Compared to the vanilla behaviour, where all magically-created weapons were dispelled automatically and all other dispel chances were bugged, it's a big improvement.

    And this is regarding whether it's still needed in the enhanced editions:

    On 12/21/2019 at 4:47 PM, Mike1072 said:

    Mirror Image Fix: This component fixes mirror images so they no longer protect from AoE spells such as Fireball.

    Dispel Magic Fix: This component prevents innate weapons (like claws provided by Polymorph and Shapeshift spells) from being dispelled by Dispel Magic.

    I believe both of these bugs were fixed in the EE games, but if you're installing SR's main component, you'll need to install these components to affect the resources added by SR.

    I'll probably move the fixes into the main component in the future.

    So, yes, we should take a look at fixing the compatibility issue with the TotLM mod / IWDEE.

  13. 11 hours ago, Endarire said:

    @Mike1072
    Since you're in charge of Spell Revisions, what say you regarding the Death Knight spell?

    I defer to Demi's ideas and community feedback when maintaining the mod.  I'm not particularly involved with design or balancing changes, though I can contribute my opinion.

    I think the Death Knight's memorized spells are quite powerful.  It looks like Demi wanted the creature to be on the stronger side (to suit lore) and wanted to use other ways to balance the spell.  Maybe the balance didn't quite get there.

×
×
  • Create New...