Scripting help: starting a quest in a End script fragment

Post » Sun Nov 18, 2012 12:29 am

I'm trying to figure out the new scripting and not doing well. What I want to do is modify the DialogueFollower quest. I want to add a custom response to the topic where my companion decides to follow the player. The topic would be keyed GetIsId = MyCompanionsName so it shouldn't mess up any other mods. Only she would follow this path.

For that topic I want to add code to the End script fragment, so once she responds to the player and decides to follow me the script fragment needs to start the new quest and advance the quest stage to 10. I just need an example of the code to do this to start my way. Any help is appreciated.
User avatar
Dewayne Quattlebaum
 
Posts: 3529
Joined: Thu Aug 30, 2007 12:29 pm

Post » Sat Nov 17, 2012 11:42 pm

First make QuestToStart a property of the script. (Put a semicolon in the fragment and compile it, so you can set the properties in the box on the right.) Then you can just put this in your fragment.

QuestToStart.SetStage(10)

You can also put QuestToStart.Start() if you want, but setting the stage will start it anyway.
User avatar
JeSsy ArEllano
 
Posts: 3369
Joined: Fri Oct 20, 2006 10:51 am

Post » Sat Nov 17, 2012 10:12 pm

TY! I'll give this a shot tomorrow and report back.
User avatar
Anna Beattie
 
Posts: 3512
Joined: Sat Nov 11, 2006 4:59 am

Post » Sat Nov 17, 2012 4:02 pm

This is not working for me. If I put just a semicolon in the end script fragment box and compile it a script name will appear to the right. If I right click on the script name and select edit properties a dialog box comes up that is all greyed out. I can't do anything with it. The same applies if I put aaViconiaQuest.StartQuest(10) or that with a semicolon at the end.

Any help here is appreciated. I know seem like an idiot but I can't seem to get past this.
User avatar
Rachael Williams
 
Posts: 3373
Joined: Tue Aug 01, 2006 6:43 pm

Post » Sat Nov 17, 2012 7:33 pm

If I right click on the script name and select edit properties a dialog box comes up that is all greyed out.

Is the Add property button at the bottom disabled?
User avatar
Neko Jenny
 
Posts: 3409
Joined: Thu Jun 22, 2006 4:29 am

Post » Sat Nov 17, 2012 11:51 pm

Is the Add property button at the bottom disabled?

If I click the Add button it wants to add a script not a property. If I click the Properties button everything is greyed out.
User avatar
Jon O
 
Posts: 3270
Joined: Wed Nov 28, 2007 9:48 pm

Post » Sat Nov 17, 2012 8:19 pm

Is there a TIF file in the script box to the right of the End Papyrus Fragment box in your Topic Info? Try right clicking on it and Edit Source. Then add Quest Property aaViconiaQuest Auto and save. It should add the property, but you might have to still fill it.
User avatar
Rachel Tyson
 
Posts: 3434
Joined: Sat Oct 07, 2006 4:42 pm

Post » Sat Nov 17, 2012 10:48 pm

If I click the Properties button everything is greyed out.

When you have clicked Compile to generate the TIF, click on OK. Then reopen the topic, select the TIF and choose Properties, and the Add property button should be enabled.

The CK is like that - you'll quite often find you need to click OK before options become available.
User avatar
Lillian Cawfield
 
Posts: 3387
Joined: Thu Nov 30, 2006 6:22 pm

Post » Sat Nov 17, 2012 6:19 pm

I did get this figured out but found a better way of advancing the stage after watching some tutorials on youtube. Many thanks!
User avatar
Bellismydesi
 
Posts: 3360
Joined: Sun Jun 18, 2006 7:25 am

Post » Sat Nov 17, 2012 5:28 pm

I'm trying to figure out the new scripting and not doing well. What I want to do is modify the DialogueFollower quest. I want to add a custom response to the topic where my companion decides to follow the player. The topic would be keyed GetIsId = MyCompanionsName so it shouldn't mess up any other mods. Only she would follow this path.

For that topic I want to add code to the End script fragment, so once she responds to the player and decides to follow me the script fragment needs to start the new quest and advance the quest stage to 10. I just need an example of the code to do this to start my way. Any help is appreciated.

actually if you do it this way, it will screw up follower mods such as UFO etc. 2 mods cannot modify the same quest. but then again, if your follower uses a custom voice type, it probably wont be compatible with UFO anyway.

in any case, if you plan on releasing this mod publicly, you may want to consider that whoever downloads this mod will have to decide if they want to use it over mods like UFO.

you can however, make a completely standalone follower mod (suggested for custom voice types) by creating an entirely new follower quest just for your follower. if you use this kind of system you should not use any of the vanilla follower quest assets. the downside to this is that, since your follower will not show up in any 3rd party mod, you will not be able to take advantage of any features added by those mods. you will have to define all the features for your follower yourself.
User avatar
CArla HOlbert
 
Posts: 3342
Joined: Wed Feb 21, 2007 11:35 pm


Return to V - Skyrim