Oh shit WTF Posted February 1, 2020 Posted February 1, 2020 can I make an active effect that only works during night time? and can I also make an active effect that only works when you're near a tree?
Seijin8 Posted February 1, 2020 Posted February 1, 2020 12 minutes ago, Oh shit WTF said: can I make an active effect that only works during night time? Use Condition GetCurrentTime, > 18 (or whatever hour you think night should start), OR condition GetCurrentTime < 6 (or whatever time you think it should end) 13 minutes ago, Oh shit WTF said: and can I also make an active effect that only works when you're near a tree? You probably would need a scripted mechanism that could detect trees. I'm fairly certain trees themselves aren't a selectable object type for condition searches. The scripted FindClosestReferenceOfAnyTypeInListFromRef() should be able to do this if you can create a formlist with trees in it.
Darkpig Posted February 1, 2020 Posted February 1, 2020 I don't think there is an absolute time for day and night. However there is a condition like that in the base Skyrim. Subject.GetGlobalValue(GameHour [GLOB:00000038]) <= 19.000000 AND Subject.GetGlobalValue(GameHour [GLOB:00000038]) >= 5.000000 AND Base Skyrim uses these values to determine when it is daytime for vampires. It works in military time so if you reverse the arrow signs you could make spells only work between 7pm and 5am.
Oh shit WTF Posted February 1, 2020 Author Posted February 1, 2020 16 minutes ago, Seijin8 said: Use Condition GetCurrentTime, > 18 (or whatever hour you think night should start), OR condition GetCurrentTime < 6 (or whatever time you think it should end) You probably would need a scripted mechanism that could detect trees. I'm fairly certain trees themselves aren't a selectable object type for condition searches. The scripted FindClosestReferenceOfAnyTypeInListFromRef() should be able to do this if you can create a formlist with trees in it. Thanks a lot!
Seijin8 Posted February 1, 2020 Posted February 1, 2020 29 minutes ago, Darkpig said: if you reverse the arrow signs you could make spells only work between 7pm and 5am Negative. This would never trigger since both would need to be true, and they couldn't be. Need to flip the condition to OR for this to work. Mainly leaving this comment in case someone comes looking for the answer for their own use.
Darkpig Posted February 1, 2020 Posted February 1, 2020 10 minutes ago, Seijin8 said: Negative. This would never trigger since both would need to be true, and they couldn't be. Need to flip the condition to OR for this to work. Mainly leaving this comment in case someone comes looking for the answer for their own use. *Looks through Vanilla Skyrim records using x-edit* Still not seeing an "or" unless you are talking about the greater or equals to. Spoiler
Seijin8 Posted February 1, 2020 Posted February 1, 2020 7 minutes ago, Darkpig said: *Looks through Vanilla Skyrim records using x-edit* Still not seeing an "or" unless you are talking about the greater or equals to. Hide contents Look harder
Darkpig Posted February 1, 2020 Posted February 1, 2020 5 minutes ago, Seijin8 said: Look harder Is that my screenshot or yours? Still this makes no sense. If it were Equal to / or then it would only work at 7 or 5. You can forget about 8 to midnight and midnight to 4.
Seijin8 Posted February 1, 2020 Posted February 1, 2020 2 minutes ago, Darkpig said: Is that my screenshot or yours? Still this makes no sense. If it were Equal to / or then it would only work at 7 or 5. You can forget about 8 to midnight and midnight to 4. The example you gave, except done correctly with logic that works and with one less lookup call per condition check... In the program of your choice.
Darkpig Posted February 1, 2020 Posted February 1, 2020 6 minutes ago, Seijin8 said: The example you gave, except done correctly with logic that works and with one less lookup call per condition check... In the program of your choice. Let me see if I got this straight. You used Function: GetCurrentTime and I used Function: GetGlobalValue I must say that is more streamlined than my method. I'll have to check it out.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.