Search the Community
Showing results for tags 'trigger'.
Found 4 results
It just happened in a test play for my mod. After my character had been level drained by a Vampiric Mist, the XPGT() trigger in one of my scripts triggered several times, indicating that my character is now supposed to have over 2.5M XP. The character was a fighter at lvl. 13 (1.25M XP) dual-classed to a thief at currently 100k XP. I'm not sure if the trigger malfunctioned because the character was dual-classed or if it always happens. EDIT: It seems to happen only for dual-classed characters. The higher the XP of the first class, the more off the mark are the XP*() triggers when level drained. This is just a wild guess, but it appears as if the trigger simply multiplies the XP amount of the first class by 2 and compares the result with the specified argument.
hey everyone, I am polishing my mod and wanted to fire some comments if my npc crosses a line. I looked at dynamic trigger/regions on area files and tried Qwinn's macro from here But for some reason it does not work even though I copy-pasted his example. I tried many things with DLTCEP and NearInfinity but everytime failed, could not even set a global i hope i am missing a simple typo or easy mistake because I wasted my whole day on it. can any of you give a link of a working example for custom region or point out what I am doing wrong below? thanks if you think my tp2 is crap, here is the proof COPY_EXISTING ~AR2402.ARE~ ~override~ LAUNCH_PATCH_MACRO ~Q_ARE_InitVars~ LAUNCH_PATCH_MACRO ~Q_AREAdd_InitVars~ SET "Q_New_Trigg" = 1 // demogorgon SET "Q_New_Vertx" = 4 // 4 vertexes LAUNCH_PATCH_MACRO ~Q_AREAdd_Process~ WRITE_ASCII "Q_NewOffset_Trigg" ~EULENA1~ #32 //: Name WRITE_SHORT "Q_NewOffset_Trigg" + 0x20 0 //: trigger/region type WRITE_SHORT "Q_NewOffset_Trigg" + 0x22 2874 //: bounding box.left WRITE_SHORT "Q_NewOffset_Trigg" + 0x24 1246 //: bounding box.top WRITE_SHORT "Q_NewOffset_Trigg" + 0x26 3297 //: bounding box.right WRITE_SHORT "Q_NewOffset_Trigg" + 0x28 1406 //: bounding box.bottom WRITE_SHORT "Q_NewOffset_Trigg" + 0x2A 4 //: vertice count WRITE_LONG "Q_NewOffset_Trigg" + 0x2C "Q_Num_Vertx" - 4 //: first vertice index WRITE_LONG "Q_NewOffset_Trigg" + 0x34 0 //: cursor WRITE_SHORT "Q_NewOffset_Trigg" + 0x68 0 //: trap detection WRITE_SHORT "Q_NewOffset_Trigg" + 0x6A 0 //: trap removal WRITE_SHORT "Q_NewOffset_Trigg" + 0x6C 0 //: trapped WRITE_SHORT "Q_NewOffset_Trigg" + 0x70 3025 //: trap loc X WRITE_SHORT "Q_NewOffset_Trigg" + 0x72 1198 //: trap loc Y WRITE_ASCII "Q_NewOffset_Trigg" + 0x7c ~EULEAR1~ #32 //: script name WRITE_ASCII "Q_NewOffset_Trigg" + 0x38 ~~ #8 //: destination area WRITE_ASCII "Q_NewOffset_Trigg" + 0x40 ~~ #32 //: entrance name //: add 4 Vertexes WRITE_SHORT "Q_NewOffset_Vertx" 2874 WRITE_SHORT "Q_NewOffset_Vertx" + 2 1340 WRITE_SHORT "Q_NewOffset_Vertx" + 4 2902 WRITE_SHORT "Q_NewOffset_Vertx" + 6 1406 WRITE_SHORT "Q_NewOffset_Vertx" + 8 3297 WRITE_SHORT "Q_NewOffset_Vertx" + 10 1315 WRITE_SHORT "Q_NewOffset_Vertx" + 12 3253 WRITE_SHORT "Q_NewOffset_Vertx" + 14 1246 BUT_ONLY_IF_IT_CHANGES COMPILE ~Lena/Scripts/EULEAR1.baf~ and EULEAR1.baf IF Entered() THEN RESPONSE #100 SetGlobal("EU#LenaDemogorgon1","GLOBAL",1) END
Hi, I'm currently working on a BG2 mod which introduces a creature which accompanies the party throughout the game. It behaves like a familiar, but I'm using the EA status CONTROLLED to control its actions. The side effect of my decision is, however, the creature isn't affected by the party's rest. For example, I am unable to restore its spell selection or innate abilities. So I have added a simple script block, using the PartyRested() trigger. The code block looks like that: IF Global("A7AfaaqSummoned", "GLOBAL", 1) Global("A7AfaaqGaseous", "GLOBAL", 0) InActiveArea("A7Afaaq") PartyRested() THEN RESPONSE #100 ActionOverride("A7Afaaq", Rest()) Continue() END The problem is that PartyRested() is very picky about where to trigger. It doesn't work in the creature's own scripts. At the moment I'm handling the block in the baldur.bcs, but I'd like to move it to a somewhat safer place. I've tried to put it into the dplayer3.bcs, which is the default script for Player1 (or any imported characters), but that script isn't executed at all, if Party AI isn't activated. Do you know of other places where the above code block may work or how to make the trigger work in the creature's own scripts?
Is it possible to make Detected or ReceivedOrder triggers to work? I want to disarm traps only after the traps have been detected. Problem is Detected doesn't work, and I prefer to not use timers. The trigger Disarmed works though. I also want to give someone an order, for example, if inventory is full, drop some items and give an order for someone to pick them up. The problem is that either GiveOrder or ReceivedOrder doesn't work. Or has anyone had any success with these two triggers?