LegoManIAm94 Posted September 22, 2013 Share Posted September 22, 2013 I have a mod and I want to convert it to Skyrim, I just dont understand the scripting. If someone who knows scripting in Skryim and could help me make a mod that can change the weather to what you please. Here is a link to the Oblivion version. The mod is 95% scripting in Oblivion and I will do as much as I can. Link to comment Share on other sites More sharing options...
demidekidasu Posted September 23, 2013 Share Posted September 23, 2013 I'd suggest you have a look at this:http://www.creationkit.com/Papyrus_Introduction When you are farmiliar with how Papyrus works, go here (scroll down the the bottom, there is also a second page):http://www.creationkit.com/Category:Papyrus Here are all the entries for Weather Script, which will obviously be of help to you:http://www.creationkit.com/Weather_Script Good luck, hope this helps :) Link to comment Share on other sites More sharing options...
mikaelarp Posted September 27, 2013 Share Posted September 27, 2013 I have a mod and I want to convert it to Skyrim, I just dont understand the scripting. If someone who knows scripting in Skryim and could help me make a mod that can change the weather to what you please. Here is a link to the Oblivion version. The mod is 95% scripting in Oblivion and I will do as much as I can.just follow this guy and youll do fine Link to comment Share on other sites More sharing options...
LegoManIAm94 Posted September 30, 2013 Author Share Posted September 30, 2013 I have done fine so far but I expanded my scripts and they just wont compile beyond this point. I cannot fix it. I copied the texts into notepad text files to easily read and put them in the zip below. 01.txt - Line 7 I want it to see if WEATHERVAR is NOT EQUAL to WEATHERVARNEW global variable. I made the variables in the creation kit. If it was Oblivion I would go "if ( WEATHERVAR != WEATHERVARNEW)" 02.txt - Line 17 It is to open the WEATHERMENUChanging message menu which I made in the creation kit under messages. Link to comment Share on other sites More sharing options...
demidekidasu Posted October 1, 2013 Share Posted October 1, 2013 What is the compile error you get? Can you copy-paste it for us please? You have not defined SkyrimClear(01.txt, line 10), I can see that right away. In 02.txt "WEATHERMENUChanging" is undefined(line 17). With Papyrus you must define everything at the start of the script like you did with the Global Variables. Try putting this in your properties of 01.txt (though I don't know how to define weather types, I assume it is this): Weather Property SkyrimClear Auto Put this in 02.txt: Message Property WEATHERMENUChanging Auto Link to comment Share on other sites More sharing options...
IsharaMeradin Posted October 1, 2013 Share Posted October 1, 2013 01.txt line #7You have if WEATHERVAR.Getvalue() =! WEATHERVARNEW.Getvalue() Needs to be if WEATHERVAR.Getvalue() != WEATHERVARNEW.Getvalue() Just a simple flip of the ! and = Link to comment Share on other sites More sharing options...
LegoManIAm94 Posted October 3, 2013 Author Share Posted October 3, 2013 I have added the changes both of you told me to add but I get the following errors 01.txt c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(9,16): cannot compare a globalvariable to a int (cast missing or types unrelated)c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(10,6): variable Player is undefinedc:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(10,13): none is not a known user-defined typec:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(10,32): variable MarkarthWorld is undefinedc:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(17,16): cannot compare a globalvariable to a int (cast missing or types unrelated)c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(18,34): cannot compare a weather to a int (cast missing or types unrelated)c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(19,7): variable Player is undefinedc:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(19,14): none is not a known user-defined typec:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLQSCRIPT.psc(19,33): variable MarkarthWorld is undefined 02.txt c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLSCRIPT.psc(18,5): missing FUNCTION at 'ibutton'c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLSCRIPT.psc(18,13): mismatched input '=' expecting LPARENc:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\WEATHERCONTROLSCRIPT.psc(0,0): error while attempting to read script WEATHERCONTROLSCRIPT: Object reference not set to an instance of an object. Link to comment Share on other sites More sharing options...
IsharaMeradin Posted October 3, 2013 Share Posted October 3, 2013 Post the actual scripts here in the thread. Put them inside the spoiler tag (third button - green & white box - top row, click it, open the drop down and find Spoiler, press ok.) Makes it much easier for me to see what is going on and reply about it when it is all on the same page. Also with the changes you made the line numbering is off so we haven't a clue about which lines the errors are actually talking about. Link to comment Share on other sites More sharing options...
LegoManIAm94 Posted October 3, 2013 Author Share Posted October 3, 2013 Scriptname WEATHERCONTROLQSCRIPT extends QuestGlobalVariable Property WEATHERVAR autoGlobalVariable Property WEATHERVARNEW autoWeather Property SkyrimClear AutoEvent OnReset() if WEATHERVAR.Getvalue() != WEATHERVARNEW.Getvalue() if WEATHERVAR == 1 if Player.GetWorldSpace() == MarkarthWorld SkyrimClear.SetActive() else SkyrimClear.SetActive() endif endif else if WEATHERVAR == 1 if Weather.GetCurrentWeather() == 0 if Player.GetWorldSpace() == MarkarthWorld SkyrimClear.ForceActive() else SkyrimClear.SetActive() endif endif endif endifendevent Scriptname WEATHERCONTROLSCRIPT extends ObjectReferenceGlobalVariable Property WEATHERVAR autoMessage Property WEATHERMENU AutoMessage Property WEATHERMENUChanging AutoEvent OnEquipped(Actor akActor) If (akActor == Game.GetPlayer()) if Weather.GetCurrentWeatherTransition() < 1.0 GotoState(WEATHERCHANGING) elseif Weather.GetCurrentWeatherTransition() == 1.0 GotoState(WEATHEROPTIONS) Endif EndifEndEventState WEATHERCHANGING int ibutton = WEATHERMENUChanging.Show() If iButton == 0 GotoState(WEATHEROPTIONS) EndifEndStateState WEATHEROPTIONS int ibutton = WEATHERMENU.Show() If iButton == 0 WEATHERVAR.SetValue(1) ElseIf iButton == 1 WEATHERVAR.SetValue(2) ElseIf iButton == 2 WEATHERVAR.SetValue(3) ElseIf iButton == 3 WEATHERVAR.SetValue(4) ElseIf iButton == 4 WEATHERVAR.SetValue(5) ElseIf iButton == 5 WEATHERVAR.SetValue(6) ElseIf iButton == 6 WEATHERVAR.SetValue(0) EndifEndState Link to comment Share on other sites More sharing options...
IsharaMeradin Posted October 3, 2013 Share Posted October 3, 2013 Try these...It was easier to correct than try to explain. Ask specific questions about a change if you don't understand what it is doing. Scriptname WEATHERCONTROLQSCRIPT extends Quest GlobalVariable Property WEATHERVAR auto GlobalVariable Property WEATHERVARNEW auto Weather Property SkyrimClear Auto Actor Property PlayerRef Auto WorldSpace Property MarkarthWorld Auto Event OnReset() if WEATHERVAR.Getvalue() != WEATHERVARNEW.Getvalue() if WEATHERVAR.GetValueInt() == 1 if PlayerRef.GetWorldSpace() == MarkarthWorld SkyrimClear.SetActive() else SkyrimClear.SetActive() endif endif else if WEATHERVAR.GetValueInt() == 1 if Weather.GetCurrentWeather() == 0 if PlayerRef.GetWorldSpace() == MarkarthWorld SkyrimClear.ForceActive() else SkyrimClear.SetActive() endif endif endif endif endevent Scriptname WEATHERCONTROLSCRIPT extends ObjectReference GlobalVariable Property WEATHERVAR auto Message Property WEATHERMENU Auto Message Property WEATHERMENUChanging Auto Event OnEquipped(Actor akActor) If (akActor == Game.GetPlayer()) if Weather.GetCurrentWeatherTransition() < 1.0 WEATHERCHANGING() elseif Weather.GetCurrentWeatherTransition() == 1.0 WEATHEROPTIONS() Endif Endif EndEvent Function WEATHERCHANGING() int ibutton = WEATHERMENUChanging.Show() If iButton == 0 GotoState(WEATHEROPTIONS) Endif EndFunction Function WEATHEROPTIONS() int ibutton = WEATHERMENU.Show() If iButton == 0 WEATHERVAR.SetValue(1) ElseIf iButton == 1 WEATHERVAR.SetValue(2) ElseIf iButton == 2 WEATHERVAR.SetValue(3) ElseIf iButton == 3 WEATHERVAR.SetValue(4) ElseIf iButton == 4 WEATHERVAR.SetValue(5) ElseIf iButton == 5 WEATHERVAR.SetValue(6) ElseIf iButton == 6 WEATHERVAR.SetValue(0) Endif EndFunctionI'm fairly certain about the top one but I'll leave room for error on the second one. Link to comment Share on other sites More sharing options...
Recommended Posts