Jump to content

temnix

Members (r)
  • Posts

    1,472
  • Joined

  • Last visited

Posts posted by temnix

  1. @Endurium Excellent. Just what I needed. Unfortunately, rumors dialogues can only start quests and leave journal entries, but don't accept actions... They do react to triggers and arrangements of states, though, just like normal conversations. In a default rumor file the states all have True() triggers, and that works for them as a random selection, but you can have your own structure, including NumTimesTalkedTo(), in case you want to have, say, a bulletin board with jobs at the thieves guild where they know you have returned. You must step away and start the conversation again for the globals to refresh, though. All of the true-checking states have equal weight, however. If you put something on top, the bottom lines remain available - and there is no way to set a global from the inside.

    What's interesting is that Myself in these conversations refers to the PC who is drinking the drink, not to the PC doing the talking or the NPC. The party member is really telling the rumors to himself (it is the same way with cures at temples, the characters actually cast the spells. If there are any level-dependent variables you will get better results if you send a cleric to buy the cures). If the dialogue includes any triggers that apply to the current drinker, all of them apply at random. For example, if you preface some lines with ~Race(Myself,HUMAN)~ and others with three triggers for evil alignments, both Imoen and Edwin will receive lines from the first category but only Edwin will get the evil rumors. Also with these dialogues triggers have to be written in a column:

    OR(3)
    Alignment(Myself,LAWFUL_EVIL)
    Alignment(Myself,NEUTRAL_EVIL)
    Alignment(Myself,CHAOTIC_EVIL)

  2. If I need to apply a bunch of spells at once, but not at 100-0 probability but at different and lower, I would like to be able to keep randomness there. The engine makes only one roll for effects of the same type and the same timing mode - I don't know about duration; I don't know if the engine will roll a second time if one effect is Instant/Limited 2 and another Instant/Limited 4. But that doesn't help, anyway, when all of the effects need to last equally long. One roll for everything is a problem. For example, if a creature has two random treasure placeholder items (RNDTRE01-05) in the inventory or custom item-creating spells apply several times at once, it will get exactly the same items. And if there are two or ten spells at probabilities, let's say, 50-0, then either all will apply or none.

    I've been using a couple of tricks to get around this. Delay/Permanent at duration 0 is still instant but mandates a separate roll. And I guess it should be possible to use other, rare timing modes like Permanent after duration, at some low value so that it triggers instantly. I've also written a wider range of chances for the included spells, e.g. I put one at 100-50, another at 50-0 and a third at 70-20. But I would like to know if there are simpler and more effective ways.

  3. Let me share my joy. I discovered that it is possible to retain tokens upon loading saved games, quitting and returning - if they referred to objects, that is, creatures. Normally, as everyone knows, a token is a pair of brackets that gets filled temporarily with any string, if the SetToken() action it used. Then content is poured out of it just the same way. They are only good for a quick showing of some text appropriate for the moment. If, let's say, a sword or a spell are given <TOKEN> as their names or a token figures there, the token has to be refilled on every game load, most likely by a special entry in BALDUR.BCS, because it always runs. A few tokens are filled automatically. For example, if you want a sword called "The Blade of <CHARNAME>" or "The Scythe of <DAYNIGHTDALL>", you don't need to do anything special, but for everything else you have to keep telling the game what to put in the brackets again. That is how SetToken() works.

    What I found is that if you use SetTokenObject() instead, your string will retain the name of the creature. For example, here is how you can create a custom map note next to someone with the text "This <STRANGER> is itching for a fight." Create two strings in the TRA, one saying that and the other "<STRANGER>." Make a spell that summons an invisible minion on target and give the minion the following script:

    IF

    OnCreation()

    THEN

    RESPONSE #1

    SetTokenObject("STRANGER",LastSummonerOf)
    ApplySpellRES("MAPNOTE",LastSummonerOf)
    DestroySelf()

    END

    It is necessary to use a second spell to create the map note, because the matching action requires definite coordinates, it does not accept [-1.-1] to put the note next to the minion. A spell with effect 253, however, will create the note right where the minion is, and then it disappears. What remains is the note saying "This Nobleman is itching for a fight" or "This Imoen is itching for a fight." And if you save and load, the text will still be there.

    This is just an example. There are many other applications. For example, someone may want to create a mod that gives characters custom titles on special achievements like slaying 100 monsters or flooding the Cloakwood mine with all the miners in it. It is up to you how to take account of those facts, but once you have the checks in, you can proceed to rename Charname as follows, to take the flooding example:

    EDIT: This still needs testing. The map notes work, though.

    1) Create a string for the <CHARNAME> token: "<CHARNAME>" (string 1)

    2) Create a string saying "<CHARNAME> <BUTCHER>" (string 2)

    3) Create a string saying "the Butcher of Cloakwood" (string 3)

    4) Create a minion, assign string 3 as his name and give him some script name, like "butcher-main."

    5) Create another minion, assign string 2 as his name and give him a different script name, let's say, "butcher-temp."

    6) Create a third minion, assign string 1 as his name and give him "butcher-final" for the script name.

    7) Now summon them all, "butcher-main" the last. This one should have a script starting with this action: SetTokenObject("BUTCHER","butcher-main"). This will fill the BUTCHER token with the words "the Butcher of Cloakwood" permanently - until you reassign the token to another object.

    😎 The "butcher-temp" minion will now have the name reading, for my main character, "Beldammon the Butcher of Cloakwood."

    9) Next we need to redefine <CHARNAME> so that it refers to that minion with SetTokenObject("CHARNAME","butcher-temp"). This will alter all references to the main character in books and conversations.

    10) It remains to adapt the name of Player1 to the current meaning of <CHARNAME>. The third action in the script will be ActionOverride(Player1,SetName(String1)) - your TRA's place for <CHARNAME>. Now your main character has been marked with the memory of that atrocity for life or until you summon a similar trio for another redefinition of <CHARNAME> and title. Make sure to destroy these minions after their job is done and never to summon them again, or you will get a double serving of your title.

    P.S. There is still more looking into this to be done, but what I should mention is that the same token can be used to latch on to different objects, and all are retained. If you set your map note's token to one creature, then to another, the notes will be different and will stay different.

  4. A question to those who have dealt closely with rumor "tables" (DLGs) for inns and temples in BG, BG2 and IWD, for all of the chapters. Preferably including SoD, too, if it has rumors. Do you have the names of all of the files written down somewhere? I would like to cover all with a patch.

  5. 13 hours ago, Endurium said:

    I don't know how you'd override default pickpocket behavior in the older games (been over a decade since I last modded them), but in the EE there is a 2DA file called PPBEHAVE which lets you control the default pick pocket response behavior. Turn Hostile = 1 means they'll turn hostile when you pick their pockets; set to zero to disable that. Same with the Report Failure and Break Invisibility flags. That would allow you to control things more specifically using script.

    That's good to know, but I would still need a trigger to detect the event of pickpocketing. This 2DA shows that the engine doesn't notice theft as an interaction between objects overhead. Maybe PickPocketFailed() works inside a creature's script, but clearly that's no good for anything.

  6. 9 hours ago, Gwendolyne said:

    There is indeed a door script field : 0x0080

    I know, but I thought it had to react to the TrapTriggered() field. It turns out it reacts to Opened(). I just made the door of the Candlekeep Inn kill Charname when he pulled at the handle without using his thieving first. Well, I still can't do anything with this without partnering with someone who can take on the Weidu code. The mod would look for locked doors in CITY areas and trap them with a script summoning burlies. I can write up the burlies, or maybe the usual alarm patrols would do. The scripts could react to an attempt to unlock if the character is seen by (sees and is not invisible) a neutral. Speaking of crime, is it possible to override pickpocket response? Invoke PickPocketFailed() from outside a creature's script? From BALDUR, maybe?

    I wonder if it would be possible to go through all trapped containers the same way, fetch their scripts and replace "Opened([ANYONE])" with "OR(2) Opened([ANYONE]) DisarmFailed([ANYONE])" to make it so that failure to disarm a trap sets it off? It would be better to have this as a random chance, but I don't know if that's possible without knowing what the script below says. A RESPONSE with some empty probability could be attached on top to them all by the same patch, but that would make the trap trigger only some of the time, too.

  7. 5 hours ago, Endurium said:

    Amended my post with an update, and posting this because edits don't update the forum's activity list.

    So the owner name does nothing at all. All right, thank you for clearing that up. The chest I tested with let me type in the token, but I'm sure it wouldn't do anything. Now what someone ought to do is fashion a skeleton key that will suit all chests' Lock field, if it's empty. Or possibly randomize that field for chests to accept one of several keys and then put them up for sale in stores. This is an idea I got from playing Faery Tale Adventure 2 recently, where there are about 8 different keys (Bronze key, Brass key, Obsidian key, Gold key, Rusty Iron Key and so on) that open different doors in dungeons around the world, not to mention special keys for plot doors, but only one store sells them. And you don't know which will match which door, if any. But how to use Weidu to give only some of the containers particular keys?

    Does anybody want to come up with code for this? Like this: if area has container 1, if it is enabled, if it is locked, if the Key field is empty, enter SMAKEY and a message in the Lockpick string field (displayed on failure) with a hint "This lock has a very small keyhole"; move to container 2, enter ELAKEY, hint "This is an elaborate lock" and so on for the rest of them in the area. Since nobody knows which container numbers refer to what in an area, this would be a pretty random distribution. Then we could hide those keys in treasure in remote dungeons or just put them up for sale here and there. Unfortunately, it only takes anyone in the party to have the keys in the inventory to open all of the locks, but hunting for keys could be fun by itself. And using a key bypasses traps. Ditto for doors, in principle, but doors are too easy to bash.

    By the way, can doors have traps? I mean, working traps? The flags can be said and the difficulty, but there doesn't seem to be a place for a trap script. Like an alarm script calling in the Flaming Fist.

  8. On 9/20/2019 at 12:27 PM, Endurium said:

    I have, by ensuring I had valid owner names, having said owner standing nearby, using flags. Otherwise I wouldn't have posted on the subject. Feel free to test it yourself.

    What flags? Anyway, what I'm interested in is whether that field can take a token. And work. Do you want to try it? Put there one of the existing ones, like <GABBER>, then have someone run a script that does SetGabber(Player1) and have Player1 open the container. I could try it myself, but you seem already set up.

  9. As we all know, there are some features of the EE engine that are not in any of the IDS or 2DA files, and we can't affect those. Maybe Beamdog can, and they made those decisions, or maybe they can't either and it's something inherent to the IE engine in all its forms. Beyond this, however, what prevents us from taking the EE engine as it is, being the form, and giving it the old files from the classic BG as the content? Now, I understand that it probably could not or would not work with some of the old IDS files, so theoretically let it keep those. Let it keep all of the files without which it can't function, like the graphics for areas - everything it needs along with what might be replaced but there is simply no alternative, like there isn't to the interface. Recolors don't count, and no one has or can bring back the old stone interface, therefore, let the engine keep this one. And let it keep the files that are unequivocally better than the old versions, such as the new script actions. Let us be generous there and not take away anything that has expanded the horizon of available functions.

    That will still leave a large number of files that could be one way or the other without breaking the engine. Changes that Beamdog introduced to classes, perhaps character progression, not to mention changes in actual creatures, spells, dialogues, ARE files and so on. Why could they not be undone by restoring old file versions? If players are unhappy with Dorn being there, bring back the version of the Nashkel mine script without that encounter and the Friendly Arm Inn ARE without him standing there. If players are unhappy with Montaron's proficiency changes, bring back Montaron's CRE. If it was nice to have powerful Sleep before Beamdog nerfed it, bring that back too. But "if" should be treated positively, as in, those elements amounted to a gameplay that was more original, fast and tight on the whole, so yes, bring them back even against contemporary ideas of "balance."

    It seems to me that the mechanics of the game under EE fall into four categories:

    1) Hard-coded "new engine as such" - leave it

    2) What the engine absolutely needs or there is no alternative - leave it

    3) What the engine does not need but an obvious improvement in the core functions - leave it

    4) Not needed nor an improvement but an iffy alteration - replace it.

    I don't think it would be all that difficult to sort all of the features into these categories either. This just appears complicated, and it will be if you decide on a case-by-case basis, but why? Most of the vital elements are going to be in the IDS and 2DA files or all-new file formats, like the PVRZ. Not many of those. The VVC did exist in the old engine, didn't it? Then spells can be brought back with their special effects setup. Of course, if you sit down and try to compare the old Dimension Door graphics with the new and decide which is better or ponder whether Safana should not keep the wakizashi, you'll be sitting there shaking your head at the stars forever, but if you side with the old unequivocally everywhere 3 is not the case, you can be consistent and quick as a happy hangman.

  10. Those are all good points, I think. And way beyond anything I could fix myself, even little by little. These technical details: Sunfire, Skull Trap and so on. I don't think I ever noticed or known about those exceptions, loopholes or call them what you like, but I don't know now if I just never cared back then or if I played and enjoyed them silently. I did enjoy the original powerful Sleep. Perhaps over the years the experience of playing the game has dulled because these little sources of fun have been chipped away, and I just never noticed. Or maybe, after all, what I always wanted was a role-playing game, where I could take my imaginary personality on a path, and these details just never mattered to me in the first place. To me BG was, at first, just something strange and unusual - remember the hype in the press that surrounded it in 1998! during development! a rebirth of the role-playing genre! - and afterwards a compomise, when I could not get as much real, live, tabletop role-playing experience as I wanted.

    It was a... well, a toke of opium, I suppose. I mean, as soon as I tried live role-playing, and especially after I read up on AD&D sourcebooks in those last years leading to the Millennium and the Third Edition, I realized that this was where imagination could unfold. Because all you needed was a pencil and paper, literally, and people to recite your worlds to! Any worlds and places you could imagine! Floating islands! Portals in the heart of volcanos! Lurking ghoul cemetaries! There was no limit, and no reason for any limit. Today I know that the Second Edition of AD&D was just an update of the First, and that the real, good, simple and gritty game had been the original D&D. I had no idea about the history behind then. But it didn't matter - I could create my worlds with any rules. I wonder what happened that after a while it became no longer possible? Maybe THIS world has moved in another direction, away from all fantasy.

    I wish there was a way to get players to put up with the EEs, though, even today. For the sake of mod ideas.

  11. I'm looking for a way to give characters an immunity to specific weapons. The Reflect spell level effect can stop weapons if it is set for level 0. It doesn't actually throw hits back, but it blocks them. Where is the "level" of a weapon set? Is it possible to change it? Another possibility is Reflect spell type. If what weapons use, NONE, is chosen, this also blocks hits. (There are "Protection from" opcodes that look like they are more to the purpose on both counts, but they don't work for this.) NONE is only a good choice for testing, but I think the list of "spell" types can be extended. Am I right about that? Then, squashing the shining disc visual effect, it would be possible to give special protections. For example, I'm thinking of making oil that will make monsters' claws slip off characters. The claw weapons are S1-10 and so on. They would just need to be edited for custom entries, and voila. Ditto for monk fists!

  12. You know how a combination of spell states can be used to channel a spell's effect? If I want my spell to work only on such-and-such creatures, I put them in spell state 1, 2 and 3 and filter the spell through to target only those who have all three. Well, I would like to make use of the whole set of spell states to avoid overlap and accidental mix-ups. Is there anything special about STORY_MODE that I should not use it, or SI_EVOCATION and the rest of them, or SNEAK_ATTACK_IMMUNITY? They don't actually turn on those abilities, just record the fact of them, yes?

  13. On 9/6/2019 at 1:02 AM, Ardanis said:

    Note that double caution needs to be exercised when employing Activate()/Deactivate()/IsActive() functionality. During SoD development it led with a significant margin in the number of caused issues, compared to any other scripting function.

    In particular, I would add this after those two blocks to ensure no further script action would accidentally trigger while the actor is inactive:

    
    IF
        Global("ACTIVE","LOCALS",0)
    THEN
        RESPONSE #100
            NoAction()
    END

    Thank you, I will. What I'm tussling with right now is that deactivated creatures still display visual effects attached to them. I don't know if effects can attach to them while they are deactivated - the whirling things from Confusion, for example, and so on, hopefully not. But if they had them before, those graphics will still hover. This is really only a problem for a specific area, where a lot of these are handed out, and I think I'm going to put a block in the area script so it dispels those for everyone as soon as night comes. I'm open to alternatives, though.

  14. It's strange, but for some reason the start of a global timer in a script can block other actions preceding it. The setting of global variables, at any rate. Here is the example script where I encountered this. It was written like this originally:

    IF
        Conditions...
    THEN
        RESPONSE #1
           SG("DICED",1)
           SetGlobalTimer("DICED","GLOBAL",TWO_ROUNDS)
           
    END

    Below in the same script was a block checking for that timer's expiration:

    IF
    
    GlobalTimerExpired("DICED","GLOBAL")
    Global("DICED","GLOBAL",1)
    
    THEN...
    
    Consequences...

    The DICED global had to be at 1 to prevent the consequences from happening again and again; after the first time it was set to 0. Well and good, only nothing was happening. Eventually I realized that DICED was not getting set to 1. But when I moved the SG() action down, like this -

    IF
       Conditions...
    THEN
        RESPONSE #1
            
           SetGlobalTimer("DICED","GLOBAL",TWO_ROUNDS)
           SG("DICED",1)
           
    END

    - the system began to take notice. Are there other landmines like this in scripts I should be aware of?

    Edit: Actually, it's worse that this. I went on with the script and what I found is that the engine confuses the names of global variables with identical names of global timers. In this example the DICED timer was triggering in one round no matter what length I assigned it: TWO_ROUNDS, FIVE_ROUNDS, it was all the same. The name of the timer was DICED, and the name of the related global, for convenience, was also DICED, and that caused the problem. I renamed the timer DICER, and then it began to trigger in due course. Not expected.

  15. 1 minute ago, Azoth said:

    I see that a lot of effort has gone into that mod, but I don't like the idea of customizing a playing experience piecemeal. It's like cutting out the upper right corner of a painting because you like the colors there the most. Beamdog's NPC, just like Bioware's NPC, are whole personalities with their own stories. Take them or leave them. I think they are pushed to the player and that their quests and dialogues are painfully belabored, maybe because Beamdog was so worried about making them fit in. Fewer words would have smoothed their passage. But sure, argent's mod is one possible step to making the EEs more palatable. But now I'd like to hear what really grinds people's gears, like the change to Montaron's proficiencies! Gaaaaah!

  16. What does that one do, Convenient NPCs? It comes without a readme. But I have in mind more modest changes for Beamdog's NPC - getting them out of the way, not swapping around their classes or portraits. I don't see how that could be justified without ruining immersion. As for the Gray Stone mod, judging by the screenshots at Beamdog's, it just recolors the current blue-stone background to be gray, it doesn't bring back the old stylish buttons or anything else. I think someone has reproduced the original BG's interface for the Trilogy or for BG2, one of those, a few years ago, but not for the Enhanced Editions. That said, there are some changes from the classic game that are not going to be reproducible in EE no matter how we try, other changes are hard-coded, but the majority probably can be rolled back, and they should account for the bulk of the widespread animosity towards the EEs. Assuming, in naive honesty, that people actually have strong reasons to hate them and don't just stick to the original because it was the original, period - or simply don't really care for the games anymore.

    If they do have actual reasons and those reasons aren't hard-coded, let's roll them back. But what are they? That's why I made this thread to find out what pisses people enough to snub the EEs. I have my own picks, if you want to know. Most of all I dislike powerful freebies from Beamdog, like a scimitar +2 just lying on the ground in Cloakwood, and hand-holding and "ease," like with the example of letting players pay extra to get that plate done in one day, because, you know, today's players have the attention deficit disorder and can't wait a little. For me as a modder, though, the stake is not getting people to play the EEs, I don't work for Beamdog, but getting them to experiment with all available toolset functions, discuss them, share results, make adventures, just come back to liking AD&D and fantasy again instead of rolling up Charname for the umpteenth time and plowing through the same yada-yada spooky Bhaalspawn "Die Irenicus DIE!!!" plot.

×
×
  • Create New...