Dimitrisgb Posted May 24, 2023 Author Share Posted May 24, 2023 This doesn't work either: scn ELSJinsAppearTestshort DoOnce1 Begin OnActivate if (GetCurrentTime >= 21) && (GetCurrentTime <= 5) ELSHunbalSpirit.ref {ELSRhondalBurningStarTemple}.enableELSAlUzzaSpirit.ref {ELSRhondalBurningStarTemple}.enableELSManatSpirit.ref {ELSRhondalBurningStarTemple}.enable else ELSHunbalSpirit.ref {ELSRhondalBurningStarTemple}.disableELSAlUzzaSpirit.ref {ELSRhondalBurningStarTemple}.disableELSManatSpirit.ref {ELSRhondalBurningStarTemple}.disable endifSet DoOnce1 to 1End Link to comment Share on other sites More sharing options...
RomanR Posted May 24, 2023 Share Posted May 24, 2023 (edited) Wrong again. You didn't understand what I was writing. So what are IDs of NPC references when you did put them in their cells? And again OnActivate block doesn't have any meaning, as mentioned by OblivionAddicted, use standard GameMode instead. Edited May 24, 2023 by RomanR Link to comment Share on other sites More sharing options...
Dimitrisgb Posted May 24, 2023 Author Share Posted May 24, 2023 Wrong again. You didn't understand what I was writing. So what are IDs of NPC references when you did put them in their cells? And again OnActivate block doesn't have any meaning, as mentioned by OblivionAddicted, use standard GameMode instead. For example, Al-Uzza's base ID is ELSAlUzza. Her ref ID is ELSAlUzzaSpirit. So I tried this code: scn ELSJinsAppearTestshort DoOnce1 Begin GameMode if (GetCurrentTime >= 21) && (GetCurrentTime <= 5) enable ELSHunbalSpirit {ELSRhondalBurningStarTemple}.enable ELSAlUzzaSpirit {ELSRhondalBurningStarTemple}enable ELSManatSpirit {ELSRhondalBurningStarTemple}. else disable ELSHunbalSpirit {ELSRhondalBurningStarTemple}disable ELSAlUzzaSpirit {ELSRhondalBurningStarTemple}.disable ELSManatSpirit {ELSRhondalBurningStarTemple}. endifSet DoOnce1 to 1End Which has no errors, no missing variables, no unknown script commands, but still doesn't work. Link to comment Share on other sites More sharing options...
RomanR Posted May 24, 2023 Share Posted May 24, 2023 Here: scn ELSJinsAppearTest short DoOnce1 Begin GameMode if (GetCurrentTime >= 21) && (GetCurrentTime <= 5) if DoOnce1 == 0 ELSHunbalSpirit.enable ELSAlUzzaSpirit.enable ELSManatSpirit.enable set DoOnce1 to 1 endif else if DoOnce1 != 0 ELSHunbalSpirit.disable ELSAlUzzaSpirit.disable ELSManatSpirit.disable set DoOnce1 to 0 endif endif End I think that reading GameHour global var should do too. Link to comment Share on other sites More sharing options...
Dimitrisgb Posted May 24, 2023 Author Share Posted May 24, 2023 Not working. No errors and all that. Just the NPC's don't appear. Link to comment Share on other sites More sharing options...
RomanR Posted May 24, 2023 Share Posted May 24, 2023 (edited) It looks like something with hour condition, try this: scn ELSJinsAppearTest short DoOnce1 Begin GameMode if (GetCurrentTime >= 21) ;from evening to midnight if DoOnce1 == 0 ELSHunbalSpirit.enable ELSAlUzzaSpirit.enable ELSManatSpirit.enable set DoOnce1 to 1 endif else if (GetCurrentTime >= 0) && (GetCurrentTime < 5) && (DoOnce1 == 0) ;from midnight to dusk ELSHunbalSpirit.enable ELSAlUzzaSpirit.enable ELSManatSpirit.enable set DoOnce1 to 1 endif endif if (DoOnce1 != 0) && (GetCurrentTime >= 5) && (GetCurrentTime < 21) ;day ELSHunbalSpirit.disable ELSAlUzzaSpirit.disable ELSManatSpirit.disable set DoOnce1 to 0 endif End Edited May 24, 2023 by RomanR Link to comment Share on other sites More sharing options...
Dimitrisgb Posted May 24, 2023 Author Share Posted May 24, 2023 That's not working either. There are no errors, though. I think I am going to try my first script with some changes. Link to comment Share on other sites More sharing options...
Dimitrisgb Posted May 24, 2023 Author Share Posted May 24, 2023 (edited) Or, could it be because the NPCs are initially enabled? Edited May 24, 2023 by Dimitrisgb Link to comment Share on other sites More sharing options...
RomanR Posted May 25, 2023 Share Posted May 25, 2023 (edited) If they're already enabled, they must be visible as you enter their cell, right? However, you must begin to test my script entering at 21 hour and you must be in cell where object to which this is attached resides. However it's better to attach this script to some place-independent object, like quest for example. Or if this is for test only, attach it to a player itself. Edited May 25, 2023 by RomanR Link to comment Share on other sites More sharing options...
Oblivionaddicted Posted May 25, 2023 Share Posted May 25, 2023 (edited) Assuming you already gave your NPC's a unique cell reference and you want to use a quest script your script should look like this without the DoOnce variable: ScriptName DrimitriSGBActivateNightlyNPCScriptbegin GameModeif GameHour >= 18 || GameHour < 6 ELSHunbalSpiritRef.enable else ELSHunbalSpiritRef.disableendifend assuming your NPC with the editor ID ELSHunbalSpirit has the unique cell reference ELSHunbalSpiritRef that is, of course. I used a similar script with an initially disabled NPC and gave the "quest" a 50 points priority by the way. Edited May 25, 2023 by Oblivionaddicted Link to comment Share on other sites More sharing options...
Recommended Posts