Miloch Posted October 25, 2006 Share Posted October 25, 2006 Well this is an odd one. I'm trying this mod out for the first time... I'd say I installed about 80-90% of the subcomponents. But after starting a new game with SCS installed, I hit a glitch where there's a very slight delay about every 3 seconds, just enough to be really annoying. It happens when I'm walking and when I'm standing still - I can tell it's present in the latter case by moving the cursor around - it'll pause momentarily every 3 seconds or so. It *doesn't* seem to happen while the game is paused, for what that's worth. The ReadMe states there can be a delay before enemies attack in some cases, but this happens in Candlekeep before any enemies are even present. And it's too regular of a delay even if there were. So I backed out SCS, started a new game, and the problem is gone. Before I go through the extensive list of subcomponents one by one trying to troubleshoot what might be causing this... any ideas? Link to comment
DavidW Posted October 25, 2006 Share Posted October 25, 2006 Well this is an odd one. I'm trying this mod out for the first time... I'd say I installed about 80-90% of the subcomponents. But after starting a new game with SCS installed, I hit a glitch where there's a very slight delay about every 3 seconds, just enough to be really annoying. It happens when I'm walking and when I'm standing still - I can tell it's present in the latter case by moving the cursor around - it'll pause momentarily every 3 seconds or so. It *doesn't* seem to happen while the game is paused, for what that's worth. The ReadMe states there can be a delay before enemies attack in some cases, but this happens in Candlekeep before any enemies are even present. And it's too regular of a delay even if there were. So I backed out SCS, started a new game, and the problem is gone. Before I go through the extensive list of subcomponents one by one trying to troubleshoot what might be causing this... any ideas? I've no idea, unfortunately, but one or two other people have reported the same thing. Three suggestions: 1) does it happen in the Candlekeep Inn or just outside? 2) does it happen when player AI is turned off? 3) does it happen when the new "Improved Deployment for Parties of Assassins" is uninstalled? Link to comment
Gorilym Posted October 25, 2006 Share Posted October 25, 2006 Typically it's some kind of complicated AI calculation causing this. Try turning off party AI. In my experience, most of the eSeries scripts cause the same thing to happen when enabled. Do you have that installed as well? edit: DavidW beat me to the punch - or rather, to the post. Link to comment
Miloch Posted October 25, 2006 Author Share Posted October 25, 2006 1) does it happen in the Candlekeep Inn or just outside?Both inside the Candlekeep buildings and outside. 2) does it happen when player AI is turned off?Yep. If anything it gets worse - like a 1-2 second delay. 3) does it happen when the new "Improved Deployment for Parties of Assassins" is uninstalled?Yeah. I uninstalled SCS including that component and reinstalled with everything I had *except* that component, started a new game, same problem. In my experience, most of the eSeries scripts cause the same thing to happen when enabled. Do you have that installed as well?Affirmative, though the ysSeries scripts seem to have overwritten the eSeries. Anyhow, you think just the *installation* (not the actual use) of the scripts would cause a delay like this? Maybe we have to test script compatibility a little more rigorously, both with other scripts and other mods (and maybe Tutu itself). On a related note as far as compatibility, the SCS readme states it should be installed before BG2 Tweaks and Divine Remix. Our current order has it after - at least in the case of BG2 Tweaks this is because of an unresolved glitch with Tweaks of Montaron and Khalid. But as for DR... is there some logic as to installing SCS before it - does it write to some of the same components? Link to comment
Miloch Posted October 25, 2006 Author Share Posted October 25, 2006 It was a tedious process but I think I nailed down where the glitch is. I backed out everything in SCS then reinstalled everything 1 component at a time, started a new game, tested, repeated after every component. Everything was fine until I got to [smarter mages]. Not only does installation of this component cause the 3-second delay, but it increases load times for new or saved games dramatically, from about 5 seconds to 18 or so in my case. And just to double check, I backed out [smarter mages] and installed [smarter clerics]. No problem there either. Maybe someone made the mages so much damn smarter they can rupture the space-time continuum just by their mere existence... Link to comment
Marty Posted October 26, 2006 Share Posted October 26, 2006 Wow, that sucks. I can say that every time I enter an area, there is ONE three second delay as stuff gets warmed up, but after that everything is smooth as silk. Link to comment
DavidW Posted October 26, 2006 Share Posted October 26, 2006 I'm unable to reproduce it locally, with or without Smarter Mages. How fast is your computer? It's possible this is a consequence of the size of the script on some systems - if so, I can look at optimising it better. Link to comment
Miloch Posted October 26, 2006 Author Share Posted October 26, 2006 Around 700Mhz, P3, Windows 2k. Yeah it's an outdated piece of junk but it's great as a gaming machine! Seriously, it's just that one component... I installed practically everything else in SCS and no lags or stutters. I guess I can live without smarter mages for the time being... you don't run into them until later in the game anyhow. Is it like a massive script compared to the other components? Or is there possibly some sort of loop or memory leak? Not suggesting your code isn't top-notch... I'm sure it is and if it wasn't, I wouldn't know. Incidentally, are we talking about \Tutu\scs\mage\magecore.baf? Because that is one huge file as compared with the other components. If no one else has reported this specifically, either I have a crappier machine than everyone else, or maybe it's conflicting with another magic-related mod or script possibly? If I can do anything else to test let me know. I'm trying to install Vista on a 3 Ghz machine at the moment, so I could test it there in theory. Though that might take a few days what with the resident Microsoft #%&*-up fairy fluttering around any sort of Windows install. Link to comment
DavidW Posted October 26, 2006 Share Posted October 26, 2006 Okay, so it looks like it might well just be a speed problem with the wizard scripts. I wrote SCS on a pretty fast machine, that made me a bit lazy about script optimisation. If you don't mind, could I get you to try the following? Open up "magecore.baf" in scs/mage and find the block IF Global("inafight","LOCALS",0) See(NearestEnemyOf(Myself)) THEN RESPONSE #100 SetGlobal("inafight","LOCALS",1) Continue() END (It's the second block from the top). After it, try adding IF Global("inafight","LOCALS",0) !See(NearestEnemyOf(Myself)) THEN RESPONSE #100 NoAction() END and then reinstall SCS. That should make the mages skip most of their scripts except when actually in battle (where I won't be able to do anything much about the delay, but where hopefully it'll be less noticeable!) (By the way, to anyone else who writes AI code: I don't not indent the code blocks because of a sadistic pleasure in making the code unreadable! I don't write complex scripts directly as BAF: I write them in a metalanguage called SSL that's a bit easier to do complex stuff in, and then machine-compile them to BAF before distribution.) Link to comment
Miloch Posted October 26, 2006 Author Share Posted October 26, 2006 That worked. At least there was no delay until I went inside the inn and attacked Firebead. That I could probably live with, since as you say, it should only happen while fighting mages. There is however, still a substantially increased load time for new or saved games (about 3-4 times as long as without the Smarter Mages). I do a lot of reloading (for testing purposes! Honestly, I'm not cheating...) so it makes it kind of tedious. It'd be great if you could do anything about shortening that too. Much obliged, -Miloch Link to comment
DavidW Posted October 27, 2006 Share Posted October 27, 2006 That worked. At least there was no delay until I went inside the inn and attacked Firebead. That I could probably live with, since as you say, it should only happen while fighting mages. There is however, still a substantially increased load time for new or saved games (about 3-4 times as long as without the Smarter Mages). I do a lot of reloading (for testing purposes! Honestly, I'm not cheating...) so it makes it kind of tedious. It'd be great if you could do anything about shortening that too. Much obliged, -Miloch I can only guess that's because Smarter Mages sets a lot of variables that have to be saved... but I'm not at all sure about this - I didn't think it set radically more variables than other components of SCS, and I'm not sure why it should affect new games. I'm not sure I can do anything about it, to be honest - I'm not sure I really understand why it happens well enough. PS until I went inside the inn and attacked Firebead. Shame on you. Link to comment
Gorilym Posted October 27, 2006 Share Posted October 27, 2006 PSuntil I went inside the inn and attacked Firebead. Shame on you. I was thinking the same thing. Poor defenseless old mage... Well, perhaps not defenseless. Link to comment
ronin69hof Posted October 27, 2006 Share Posted October 27, 2006 @DavidW I cant reproduce the lag with SCSv1BGT either. ronin Link to comment
pro5 Posted November 4, 2006 Share Posted November 4, 2006 It can save a few more AI cycles, if you add a new state to STATE.IDS: APPEND ~state.ids~ ~0x8014202D STATE_OUT_OF_ACTION~ UNLESS ~STATE_OUT_OF_ACTION~ IESDP defines this state as: 0x8014202D STATE_OUT_OF_ACTION Feeblemind & Charmed & Helpless & Stunned & Sleeping & Blind & Confused & Panic Then, you can replace each occurence of these lot: !StateCheck([...] ,STATE_PANIC) !StateCheck([...],STATE_CHARMED) !StateCheck([...],STATE_SLEEPING) !StateCheck([...],STATE_STUNNED) !StateCheck([...],STATE_HELPLESS) !StateCheck([...],STATE_CONFUSED) with a single line: !StateCheck([...],STATE_OUT_OF_ACTION) Not a big deal, but when speaking about improving performance every little bit helps. Link to comment
Guest Freelance Cynic Posted December 14, 2006 Share Posted December 14, 2006 I'd like to report exactly the same problem as Miloch, but I have quite a different computer: an Apple iBook G4 1.2Ghz with 768Mb RAM. The problem is also for me [smarter mages]. Everything else works fine, but when this option is enabled (unfortunately one of the most important for this mod), I get "hiccups" every few (2-4) seconds (it seems to me the more mages on the map, the worse it gets, but I can't really confirm that for sure). I tried the fix you suggested in magecore.baf, which did indeed fix the problem outside of battles, but still left me with the problem of my game freezing half a second every 2-3 seconds in all my battles... Interrestingly, like Miloch, [smarter clerics] works just fine. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.