jayne2132 Posted February 27, 2015 Share Posted February 27, 2015 I think this is a longshot, but I've thought that about other things that turned out to be quite trivial. Is there a way to send script1 with an unknown name to script2? I have a variable number of quests with their own unique scripts set up to extend a common parent script. The child scripts 'push' their attached quest objects to activators. When an activator is activated, I'd like it to call a function in the same quest's script. But at this point the activator doesn't know the name of the script. (The second-best choice, I believe, would be to set up modevents with arguments identifying the quest that should listen to them. Pushing the script objects would be more precise and less work for me, so I'd prefer to do that, if at all possible :smile:.) Link to comment Share on other sites More sharing options...
Mattiewagg Posted February 27, 2015 Author Share Posted February 27, 2015 I think this is a longshot, but I've thought that about other things that turned out to be quite trivial. Is there a way to send script1 with an unknown name to script2? I have a variable number of quests with their own unique scripts set up to extend a common parent script. The child scripts 'push' their attached quest objects to activators. When an activator is activated, I'd like it to call a function in the same quest's script. But at this point the activator doesn't know the name of the script. (The second-best choice, I believe, would be to set up modevents with arguments identifying the quest that should listen to them. Pushing the script objects would be more precise and less work for me, so I'd prefer to do that, if at all possible :smile:.)You must at least have the name of the script. There's no way to access it otherwise. Either to fill the property or reference it when casting. Link to comment Share on other sites More sharing options...
jayne2132 Posted February 27, 2015 Share Posted February 27, 2015 You must at least have the name of the script. There's no way to access it otherwise. Either to fill the property or reference it when casting. That's what I suspected, but was hoping otherwise. Thanks for replying! Link to comment Share on other sites More sharing options...
cdcooley Posted February 27, 2015 Share Posted February 27, 2015 I have a variable number of quests with their own unique scripts set up to extend a common parent script.If I interpreted one of SmkViper's comments about how things work correctly, then if the common parent script has the function you want to call then you just need to cast all of the quests to that parent type and call that function. If the more specific script that extended the parent script has a version of that function it will be used instead of the common function version. You can test it with something simple like this. ScriptName ParentScript extends Quest Function DoSomething() Debug.Notification("CDCooley was wrong.") Debug.Trace("CDCooley was wrong.") EndFunction ScriptName Child1Script extends ParentScript Function DoSomething() Debug.Notification("Child 1 is doing something.") Debug.Trace("Child 1 is doing something.") EndFunction ScriptName Child2Script extends ParentScript Function DoSomething() Debug.Notification("Child 2 is doing something.") Debug.Trace("Child 2 is doing something.") EndFunction ScriptName CallerScript extends ObjectReference ParentScript Property Quest1 Auto ParentScript Property Quest2 Auto Event OnActivate(ObjectReference akActionRef) Quest1.DoSomething() Quest2.DoSomething() EndEvent Link to comment Share on other sites More sharing options...
kmfdm515 Posted February 27, 2015 Share Posted February 27, 2015 Does anyone know of a good way to keep the weather always sunny? (I am not using CoT) I tried the always sunny version of this mod: http://www.nexusmods.com/skyrim/mods/8739/ but it doesn't seem to work. I tried this weather spell mod: http://www.nexusmods.com/skyrim/mods/61080/ but thew weather goes back to default after fast traveling. Is there any way to accomplish this? Link to comment Share on other sites More sharing options...
BigBizkit Posted February 27, 2015 Share Posted February 27, 2015 "I tried the always sunny version of this mod: http://www.nexusmods.com/skyrim/mods/8739/ but it doesn't seem to work." That's odd because I used that one before I switched to "Weather Control Center", which isn't on the Nexus anymore for reasons I don't know. Link to comment Share on other sites More sharing options...
kmfdm515 Posted February 27, 2015 Share Posted February 27, 2015 EDWS wasn't working for me...not sure why. I did find this: Only way I know of to change how the weather system works is to actually edit the weather in Creationkit. So if you want only one weather all the time you can set all the regions in the world to select from only one weather. I think this is your best option if you really want to customize what weathers are available and so on. ...how do you set the weather by Region in the CK? Link to comment Share on other sites More sharing options...
Mattiewagg Posted February 27, 2015 Author Share Posted February 27, 2015 Weather changes depending on region and time in theft So you can't really keep the weather one way without polling and resetting a lot (if you're using scripts). Changing it region by region will be a pain though. You could use my Hotkey mod and just tap the Hotkey whenever it changes to anything other than sunny, I suppose. Link to comment Share on other sites More sharing options...
jayne2132 Posted February 27, 2015 Share Posted February 27, 2015 If I interpreted one of SmkViper's comments about how things work correctly, then if the common parent script has the function you want to call then you just need to cast all of the quests to that parent type and call that function. If the more specific script that extended the parent script has a version of that function it will be used instead of the common function version. You can test it with something simple like this. Just tested it, it worked perfectly with my setup! (child functions overriding parent and all). Thanks for the great info Link to comment Share on other sites More sharing options...
kmfdm515 Posted February 27, 2015 Share Posted February 27, 2015 Now I remember the issue with EDWS...it changed my Whiterun town name to German. I checked the mod page but only saw mention of the opposite problem. (Changing name to English in German version) Not sure how to fix that issue. Link to comment Share on other sites More sharing options...
Recommended Posts