oc3 Posted July 19, 2014 Share Posted July 19, 2014 On a mod that I am working on, I have a series of trigger zones which in the past have worked perfectly. However, they recently quit working dependably. I created degug messages in the script and they pop up VERY late if at all, unless I enter the console or a menu, in which case it is instant. I've made too many changes since the last time I tested to be sure what the cause could be, but the last was creating a pathgrid. I deleted the pathgrid and the problem remains. The trigger zone also works fine in the testing hall. Here is a typical script: scn CTMStatueGuardTriggerSCRIPT; Disables guard statues and enables the statue guard characters. Also, enables the trigger zone that spawns the last 4 skeletons/casketsSHORT TESTbegin onTrigger Player if test == 0 messagebox "triggered" SET TEST TO 1 endif CTMGuardStatueLt.Disable CTMGuardStatueRt.Disable CTMStatueGuard1.Enable CTMStatueGuard2.Enable CTMLeavingTombTrigger.Enable CTMBoulderTrig2.Enable end NOW, keeping this in mind....I have an esp that works just fine when loaded in game, but......If I load it into the CS and make NO CHANGES and then save, the trigger zones no longer work. Any ideas? Almost done with this mod of 2 years plus, just need some help before I throw my computer in the lake. :wallbash:Thanks Link to comment Share on other sites More sharing options...
The_Vyper Posted July 19, 2014 Share Posted July 19, 2014 That is a bit odd. Try testing with a clean save and see if that works. Link to comment Share on other sites More sharing options...
oc3 Posted July 20, 2014 Author Share Posted July 20, 2014 I have been. I'm actually using game saves that were made for testing purposes that I downloaded from the nexus. Can't remember the author though.Still, I'll try a different one and see if that makes a difference. Thanks! Link to comment Share on other sites More sharing options...
QQuix Posted July 20, 2014 Share Posted July 20, 2014 I suggest you temporarily add a gamemode block to see what is triggering th TZ. Something like this will print to the console whatever is triggering the TZ: ref reff Begin gamemode Let reff := GetActionRef printc "GetActionRef = %i %n" reff reff end Link to comment Share on other sites More sharing options...
The_Vyper Posted July 20, 2014 Share Posted July 20, 2014 I have been. I'm actually using game saves that were made for testing purposes that I downloaded from the nexus. Can't remember the author though.Still, I'll try a different one and see if that makes a difference. Thanks!If that doesn't help, try modifying the script like this: Short Test begin onTrigger if IsActionRef Player == 1 && Test == 0 CTMGuardStatueLt.Disable CTMGuardStatueRt.Disable CTMStatueGuard1.Enable CTMStatueGuard2.Enable CTMLeavingTombTrigger.Enable CTMBoulderTrig2.Enable messagebox "triggered" Set Test to 1 endif end You can remove the messagebox line if that setup works, but leave the 'Test' variable; this will ensure that the script only runs the first time the Player goes through the trigger zone. Link to comment Share on other sites More sharing options...
oc3 Posted July 20, 2014 Author Share Posted July 20, 2014 Thanks to both of you for the ideas, but neither idea worked. Neither did using a different clean save. The console message QQuix recommended stated "ref 000000000 <noname>" REPEATEDLY. EDIT...After I hit the next 2 zones, the console correctly gives my characters name. Very strange. This problem has happened twice before. The first time it seemed to be fixed by resizing the trigger zones to a scale of 1.0. They were larger. The second time, I just rebuilt from scratch and also found that I had somehow resized the 'master' trigger zone to smaller than 1. Resized it to 1.0 and it started working again. Now, they are all definately scaled to 1.0 and does not work. I don't get it, because the size should not matter. I think something is stuck in a loop or otherwise tieing up the game engine/cpu until a menu or console is entered. Any ideas where to look? EDIT.... I'm going to resize and position my trig zones so they do not touch anything at all. I think the engine is getting 'clogged up' with all the constant triggering from statics. Link to comment Share on other sites More sharing options...
QQuix Posted July 20, 2014 Share Posted July 20, 2014 (edited) Scale should not affect the TZ. They are supposed to be scaled, i guess.If the console says "ref 00000000..", there is nothing triggering it. Since you have more than one TZ, use this to identify which is printing which message.(make sure the code is added to all) ref reff ref refSelf Begin gamemode Let refSelf := GetSelf Let reff := GetActionRef printc "TZ %i - GetActionRef = %i %n" refSelf reff reff end Edited July 20, 2014 by QQuix Link to comment Share on other sites More sharing options...
oc3 Posted July 20, 2014 Author Share Posted July 20, 2014 Well...... It worked perfectly 3 times in a row. Then I wondered what would happen if I closed the CS, opened it and reloaded my esp, and then saved it (without even opening a cell). Guess what? Broken again! The first trigger zone works fine, but the second which it enables with 'CTMLeavingTombTrigger.Enable' does not. I only get the debug message after I enter the console or menu. Even then, it's script does not function even though I get the debug message. The caskets that it is supposed to activate during a gamemode ...Don't. Is using one triggerzone to enable another a bad practice? EDIT: This is incredibly weird, I've used dozens of trigger zones in this mod with no problem at all. Pretty sure I've even linked them. What the hell is going on. This almost seems like a CS issue. I sent ShadeMe a message, but so far no response. I'll let everyone know If he has any clues. Link to comment Share on other sites More sharing options...
oc3 Posted July 20, 2014 Author Share Posted July 20, 2014 Scale should not affect the TZ. They are supposed to be scaled, i guess. If the console says "ref 00000000..", there is nothing triggering it. Since you have more than one TZ, use this to identify which is printing which message.(make sure the code is added to all) ref reff ref refSelf Begin gamemode Let refSelf := GetSelf Let reff := GetActionRef printc "TZ %i - GetActionRef = %i %n" refSelf reff reff endThanks, Q,Looks like you've been working hard on this. Thanks. You probably haven't seen my last post yet, but when you do, I think you'll agree something else is going on. Thanks for your time, please keep helping if you can. Link to comment Share on other sites More sharing options...
QQuix Posted July 21, 2014 Share Posted July 21, 2014 (edited) Using one triggerzone to enable another is not a problem at all. It must be something with your setup. Make sure you are taking into account these two characteristics of the TZ (which I think you do)1. the onTrigger block will run every frame when there is someone/something triggering the TZ2. TZs always report the last one in as the Action ref, so even if it is being triggered by someone else, the player would be the Action ref when he entered the zone. Is there any menumode block in your script? (when you enter the console or menu, the only scripts that run are menumode blocks) Edited July 21, 2014 by QQuix Link to comment Share on other sites More sharing options...
Recommended Posts