cmorgan Posted October 9, 2006 Share Posted October 9, 2006 The code is pretty instant: Extended on the top of _YNAHEIR.BCS via X#DYQUST.baf, one of the blocks in Dy's override script should read IF Dead("Aravaata") See(Player1) Global("X#DynaJournal","GLOBAL",10) Global("X#DynaFinal","LOCALS",0) THEN RESPONSE #100 SetGlobal("X#DynaFinal","LOCALS",1) SetGlobal("X#DynaJournal","GLOBAL",11) Dialogue(Myself) END I read somewhere that the "see" is problemmatic, but that is true for all of BG1 NPC - rght now, invisible parties will not have much interaction. I'm on the case for the amulet, if you have time to fish the scroll item ereference from DLTCEP or NI, it would be awesome. We just slap ADD_CRE_ITEM onto the tp2 work assigning _winski2.cre stuff, and it all rocks! I have been matching this on the BGT side, even if it is not really being installed; that way if a workaround ever comes up we have all of our work ready to go. Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 Oh... If you compare that Dyna block to Aravaata's "kill Winski" block, you'll see that the latter has already incremented X#DynaJournal to 11 before the former can even run - surely this isn't right? Maybe try changing Global("X#DynaJournal","GLOBAL",10) in IF to Global("X#DynaJournal","GLOBAL",11)? (and SetGlobal("X#DynaJournal","GLOBAL",11 in THEN to SetGlobal("X#DynaJournal","GLOBAL",12?) Cacofiend scroll is 'SCRL8I' Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 Let me adjust it in my copy - I bet this is a problem of rewriting different versions! The block should then read 11 to 12 to close everything, and the D file adjusted accordingly. I will post in a few minutes... Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 OK, I am not sure about the ADD_CRE_ITEM for the scrolls, so commentary is appreciated. This is now set up as> Encounter is triggered by talking to the deathbed Winski in the Maze. If Dynaheir is not in the party, the regular sequence plays. If she is in the party (regardless of romance status) the following triggers before/instead of the original sequence. tp2 setup (Tutu version only for space) ACTION_IF FILE_EXISTS_IN_GAME ~FW0100.are~ THEN BEGIN /* creatures */ COPY_EXISTING ~_WINSKI2.CRE~ ~override~ WRITE_ASCII 0x2cc ~_WINSKI~ #8 WRITE_ASCII 0x280 ~winski2~ #32 ADD_CRE_ITEM ~SCRL8I~ #0 #0 #0 ~IDENTIFIED~ ~INV5~ // soon to be added : ADD_CRE_ITEM ~X#WINAML~ #0 #0 #0 ~IDENTIFIED~ ~INV6~ The dialogue with Winski on his deathbed is added to BG1NPC\Phase2\DLG\X#DYNQST.D: CHAIN IF WEIGHT #-4 ~Global("X#DynaJournal","GLOBAL",8) InParty("dynaheir") Global("X#DYQUWEndSummon","GLOBAL",0)~ THEN ~_WINSKI~ X#WinskiFinal @166 == ~_BDYNAH~ @167 == ~_WINSKI~ @168 == ~_BDYNAH~ @169 == ~_BDYNAH~ @170 == ~_WINSKI~ @171 = @209 = @210 == ~_BDYNAH~ @172 == ~_WINSKI~ @173 == ~_WINSKI~ @174 == ~_BDYNAH~ @175 == ~_WINSKI~ @176 == ~_WINSKI~ @177 DO ~SetGlobal("X#DynaJournal","GLOBAL",9) CreateCreatureObjectDoor("X#TANARI",Player1,0,0,0)~ EXIT To set up the summoned dialogue, and then trigger the Winski-slaying, in BG1NPC\Phase2\BAF\X#DYTANR.BAF IF NumTimesTalkedTo(0) Global("X#TanarriTalks","LOCALS",0) THEN RESPONSE #100 SetGlobal("X#TanarriTalks","LOCALS",1) StartDialogueNoSet(Myself) END IF Global("X#DynaJournal","GLOBAL",10) Global("X#TanarriKillsWinski","LOCALS",0) THEN RESPONSE #100 SetGlobal("X#TanarriKillsWinski","LOCALS",1) SetGlobal("X#DynaJournal","GLOBAL",11) ReallyForceSpell("winski2",WIZARD_FINGER_OF_DEATH_IGNORE_RESISTANCE) Kill("winski2") Enemy() END IF See(NearestEnemyOf(Myself)) !StateCheck(LastSeenBy(Myself),STATE_STUNNED) !StateCheck(LastSeenBy(Myself),STATE_HELPLESS) !Range(LastSeenBy(Myself),10) GlobalLT("symbol","LOCALS",4) THEN RESPONSE #100 IncrementGlobal("symbol","LOCALS",1) ReallyForceSpell(NearestEnemyOf(Myself),WIZARD_NPC_SYMBOL_STUN) Continue() END IF See(NearestEnemyOf(Myself)) !StateCheck(LastSeenBy(Myself),STATE_HELPLESS) GlobalLT("TANARIPARALYZE","LOCALS",5) THEN RESPONSE #100 ForceSpell(NearestEnemyOf(Myself),TANARI_PARALYZE) IncrementGlobal("TANARIPARALYZE","LOCALS",1) Continue() END IF See(NearestEnemyOf(Myself)) StateCheck(LastSeenBy,STATE_HELPLESS) THEN RESPONSE #100 AttackOneRound(NearestEnemyOf(Myself)) AttackOneRound(NearestEnemyOf(Myself)) Continue() END IF See(NearestEnemyOf(Myself)) !StateCheck(LastSeenBy(Myself),STATE_CONFUSED) Global("Prep","LOCALS",1) THEN RESPONSE #100 SetGlobal("Prep","LOCALS",2) SpellNoDec(NearestEnemyOf(Myself),WIZARD_CONFUSION) Continue() END IF See(NearestEnemyOf(Myself)) !StateCheck(LastSeenBy(Myself),STATE_CONFUSED) !StateCheck(LastSeenBy(Myself),STATE_HELPLESS) Global("Prep","LOCALS",2) THEN RESPONSE #100 SetGlobal("Prep","LOCALS",3) SpellNoDec(NearestEnemyOf(Myself),WIZARD_EMOTION_HOPELESSNESS) Continue() END IF See(NearestEnemyOf(Myself)) !StateCheck(LastSeenBy(Myself),STATE_HELPLESS) GlobalLT("TANARIPARALYZE","LOCALS",7) THEN RESPONSE #100 IncrementGlobal("TANARIPARALYZE","LOCALS",1) ForceSpell(NearestEnemyOf(Myself),TANARI_PARALYZE) Continue() END IF !See([GOODCUTOFF]) Allegiance(Myself,ENEMY) THEN RESPONSE #100 MoveToObject(Player1) END IF See(NearestEnemyOf(Myself)) GlobalGT("Prep","LOCALS",2) GlobalGT("TANARIPARALYZE","LOCALS",2) OR(2) Range(LastSeenBy(Myself),10) HPPercentLT(Myself,50) THEN RESPONSE #100 AttackReevaluate(NearestEnemyOf(Myself),15) Continue() END On summoning, the following added to BG1NPC\Phase2\DLG\X#DYNQST.D: CHAIN IF WEIGHT #-2 ~NumTimesTalkedTo(0) Global("X#DynaJournal","GLOBAL",9)~ THEN ~X#TANARI~ X#TanarriKillsWinski @178 == ~_WINSKI~ @179 == ~X#TANARI~ @180 = @181 DO ~SetGlobal("X#DynaJournal","GLOBAL",10)~ EXIT To trigger end recap party discussion, extension of Dynaheir's BCS Added to BG1NPC\Phase2\BAF\X#DYQUST.baf IF Dead("Aravaata") Global("X#DynaJournal","GLOBAL",11) Global("X#DynaFinal","LOCALS",0) THEN RESPONSE #100 SetGlobal("X#DynaFinal","LOCALS",1) SetGlobal("X#DynaJournal","GLOBAL",12) Dialogue(Myself) END The actual final discussion is added to BG1NPC\Phase2\DLG\X#DYNQST.D: CHAIN IF WEIGHT #-2 ~Global("X#DynaJournal","GLOBAL",12) InParty("dynaheir") Dead("Aravaata")~ THEN ~_DYNAHJ~ X#DynaWinskiCompleted @182 DO ~SetGlobal("X#DynaJournal","GLOBAL",15)~ == ~_BMINSC~ IF ~InParty("minsc")~ THEN @183 == ~_BDYNAH~ @184 == ~_XAN~ IF ~InParty("xan")~ THEN @185 == ~_BMONTA~ IF ~InParty("montaron")~ THEN @186 == ~_BCORAN~ IF ~InParty("coran")~ THEN @187 == ~_BSAFAN~ IF ~InParty("safana")~ THEN @188 == ~_BAJANT~ IF ~InParty("ajantis")~ THEN @189 == ~_BEDWIN~ IF ~InParty("edwin")~ THEN @190 == ~_BJAHEI~ IF ~InParty("jaheira")~ THEN @191 == ~_BKHALI~ IF ~InParty("khalid")~ THEN @192 == ~_BALORA~ IF ~InParty("alora")~ THEN @193 == ~_BYESLI~ IF ~InParty("yeslick")~ THEN @194 == ~_BIMOEN~ IF ~InParty("imoen")~ THEN @195 == ~_BKIVAN~ IF ~InParty("kivan")~ THEN @196 == ~_BDYNAH~ @197 == ~_BMINSC~ IF ~InParty("Minsc")~ THEN @198 END IF ~Class(Player1,CLERIC_ALL) Class(Player1,PALADIN_ALL)~ THEN REPLY @199 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~Class(Player1,FIGHTER_ALL)~ THEN REPLY @200 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~OR(2) Class(Player1,MAGE_ALL) Class(Player1,SORCERER)~ THEN REPLY @201 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~Class(Player1,BARD_ALL)~ THEN REPLY @202 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~Class(Player1,THIEF_ALL)~ THEN REPLY @203 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~~ THEN REPLY @204 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~~ THEN REPLY @205 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal IF ~~ THEN REPLY @206 EXTERN ~_DYNAHJ~ X#DynaWinCompletedFinal APPEND ~_DYNAHJ~ IF ~~ THEN BEGIN X#DynaWinCompletedFinal SAY @207 IF ~~ THEN JOURNAL @208 EXIT END END Still ned to build and add amulet, and most f all figure out how to increase the Tanar'ri's resistance to his own stunning effect. Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 I don't think there's any reason to give Winski2 better saving throws - they were probably set to the worst possible to illustrate his enfeebled state, and the sequence worked fine with them at all 20s (and in truth save vs. spells at 3 is absurdly low for anyone other than a high level paladin or halfling etc.). As for giving Aravaata resistance to his own stun / paralyze - simply lowering his saving throws considerably might work, or you could give him appropriate immunity to opcode effects copied from some suitable creature. Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 OK, removing that patching from code and post... for some reason i\I got my head turned around and thought it was the equivalent of giving immunity instead of lowering. Remembered my old d20 red clear plastic "jewel" of my youth, and thought for some reason that meant "only on a roll of 20"! I am still stuck on C_E AMUL02 and adding the correct effects. I see the basic logic, I just am having trouble grappling with offset patching and such. As for Aravaata, I think I can patch those saving throws (not sure i can mess with opcodes effectively yet, as I said): COPY_EXISTING ~DEMNABSU.CRE~ ~override/X#TANARI.CRE~ SAY NAME1 @291 SAY NAME2 @291 WRITE_SHORT 0x24 ~126~ WRITE_SHORT 0x26 ~126~ WRITE_LONG 0x14 ~7000~ WRITE_BYTE 0x52 ~9~ WRITE_BYTE 0x234 ~15~ WRITE_ASCII 0x248 ~X#DYTANR~ #8 // override script WRITE_EVALUATED_ASCII 0x2CC ~%DEST_RES%~ #8 // dialog WRITE_BYTE 0x270 ~128~ //Allegiance = Neutral WRITE_ASCII 0x280 ~aravaata~ #32 // death variable 10 12 11 12 13 resist magic 50% hey - we may not want to mess with this. It looks like all variations of this creature (which in BG2 gives 16000 xp!!!) have the same stats, but with only 65 hp and no more resistances. Should we press on? Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 1012 11 12 13 resist magic 50% hey - we may not want to mess with this. It looks like all variations of this creature (which in BG2 gives 16000 xp!!!) have the same stats, but with only 65 hp and no more resistances. Should we press on? That such creatures are assigned 16000 XP is yet another case of weird design decisions, that's far too much for the effort required (Not too mention that the base stats of these creatures must be based on a juvenile nabassu, while all the incarnations have the spell ability of a mature nabassu )... I've fought the Aravaata battle a couple dozen times now, and having better saving throws isn't going to save him. With 50 % magic resistance using spells against him are a bad idea in any case. Though if you're really concerned about it, try lowering only the saves that are used by these spells. (vs. paralyzation and vs. spells? I forget) Of course, the ideal way would still be to give immunity to the specific opcodes. Possibly you could add to Aravaata an undroppable version of an item that grants immunity to stun etc.? Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 Well, let's see if I made any progress. This item attached should look like a normal necklace right now, but should grant the wearer the innate ability (while equipped) to cover the entire party with Protection from Evil. If I did this right, then I might be able to figure out how to do the opcode thing; EDIT: nonfunctioning item removed does this work on your install? Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 Unfortunately X#WINAMU.itm shows up as a mundane necklace with no abilities whatsoever. Also had a look at it in NI, no effects. Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 blast. Let me try again. EDIT: removed trial #2. Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 The effect is present with this one, but it only gives "one-person" protection from evil. Also, I think GiveInnate is mainly meant for things like Bhaalspawn powers or class abilities. A better template for the Protection from Evil 10" this item needs could be the cure poison ability of AMUL22 - it's basically the same deal, only with a different spell referenced. Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 double blast. The Periapt of Proof against Poison seems to use exactly what I used - it targets just the one user. I tried setting the target to "party", but if that didn't work, I don't know what will. I will try to go find a way to make an item cast a specific spell, instead of dealing directly with opcodes. Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 The PoPaP targets just one person, but then the spell it's linked to is a one-person spell. I don't think the Target "Party" matters if the spell the effect references only targets one person - the litmus test here will be to see what happens if the spell reference is changed to the 10" radius version of pro. from evil, I'll go test that. Link to comment
cmorgan Posted October 9, 2006 Share Posted October 9, 2006 how are you changing the spell reference? In DLTCEP, I can only go by opcode directly, and I can't seem to find the list that equates this to spells... Hey, try this one. It is set up in NI, and says it will protect the party from creatures of chaotic evil alignment (if I read it all correctly). Link to comment
Gorilym Posted October 9, 2006 Author Share Posted October 9, 2006 It's quite straightforward doing so in NI, though it may be a PITA replicating it with COPY_EXISTING and WeiDU. Here's a X#WINAMU that does the job in testing: (it is ugly though, I cloned AMUL22 and just changed the abilities and effects) Ack. I can't attach files here, let me upload it somewhere and then add a link here. edit: Great. Uploader refuses to cooperate. How about you PM me an email address I can send it to? even more edit: only now did I see your edit of your previous post, I'll try that one too. However the effect you describe doesn't mimic protection from evil fully - I think it will give the save and THAC0 bonuses, but it won't protect against demons etc.; you need an extra effect for that, which is why it's better to just use the CastSpell action. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.