Difference between revisions of "A beginner's guide, lesson 7 - Using Scripts in Quests"

Jump to navigation Jump to search
→‎Setting up Brown: adding another possible outcome
imported>Pyrocow2
(→‎Aleswell Phase: adding sections)
imported>Pyrocow2
(→‎Setting up Brown: adding another possible outcome)
Line 708: Line 708:


===Setting up Brown===
===Setting up Brown===
We can set up an optional reward for players who choose to free Brown from his cell. Open up Brown's form and make sure he doesn't have a high aggression level, just to make sure Brown won't attack the player on sight. Iit should at least be lower than whatever positive disposition you gave the prisoner faction towards the player, but it wouldn't hurt to just set it to 0.
We can set up an optional reward for players who choose to free Brown from his cell. Open up Brown's form and make sure he doesn't have a high aggression level, just to make sure Brown won't attack the player on sight. It should at least be lower than whatever positive disposition you gave the prisoner faction towards the player, but it wouldn't hurt to just set it to 0.


Then set up a greeting for Brown:
Then set up a greeting for Brown:
Line 735: Line 735:
|}
|}


The positive response, ''BGBrownChoice1'', will give a stage boost. The negative response, ''BGBrownChoice2'', will not.
Each response will advance the quest to a different stage, which will have appropriate journal entries and result scripts.


{| border="1" cellpadding="5"
{| border="1" cellpadding="5"
Line 758: Line 758:
|}
|}


We update the journal and run a bit of script as a result.
For stage 100, add the following journal entry:


  ''Brown gave me the code for the combination lock on the chest. I need to enter 1-4-7 to unlock it. Once I've done that, I will need to go see Vilanus Villa in  Imperial City. Vilanus will need to transfer ownership of my uncle's house to me.''
  ''Brown gave me the code for the combination lock on the chest. I need to enter 1-4-7 to unlock it. Once I've done that, I will need to go see Vilanus Villa in  Imperial City. Vilanus will need to transfer ownership of my uncle's house to me.''
The stage result script is used to remove the quest object status from a number of items which are no longer needed and which the PC can now dispose of.
<pre>
SetQuestObject BGHideoutCELLKey 0
SetQuestObject BGHideoutKey 0
SetQuestObject BGBrownLetter 0
SetQuestObject BGPartialLetter 0
</pre>


{| border="1" cellpadding="5"
{| border="1" cellpadding="5"
Line 789: Line 780:
|-
|-
!  RESULT SCRIPT
!  RESULT SCRIPT
''No result script''
<pre>SetStage BGM001 101</pre>
|}
|}
Add another entry for stage 101:
''I left Brown to rot in his cell. I need to go see Vilanus Villa in  Imperial City so he can transfer my uncle's property to me.''
The stage result script is used to remove the quest object status from a number of items which are no longer needed and which the PC can now dispose of. This should be applied to BOTH of the possible stages. (Use whichever IDs you chose when creating these items.)
<pre>
SetQuestObject BGHideoutCELLKey 0
SetQuestObject BGHideoutKey 0
SetQuestObject BGBrownLetter 0
SetQuestObject BGPartialLetter 0
</pre>


We will need to look at altering Brown's behavior for the final release. We will need to add some AI in the next lesson to get him to run away.
We will need to look at altering Brown's behavior for the final release. We will need to add some AI in the next lesson to get him to run away.
Anonymous user

Navigation menu